From 3e44176d37f54e6700f03ef9e0e16dd70bff98b1 Mon Sep 17 00:00:00 2001 From: Libba Lawrence Date: Thu, 26 Sep 2024 14:52:42 -0700 Subject: [PATCH 1/2] sb --- .../Microsoft.ServiceBus/ServiceBus.tsp | 15 ++-- .../2018-01-01/GeneratedSystemEvents.json | 76 +++++++++++++++---- .../2024-01-01/GeneratedSystemEvents.json | 76 +++++++++++++++---- 3 files changed, 129 insertions(+), 38 deletions(-) diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp index 0167548c82fe..a746b7e342cb 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp @@ -22,21 +22,24 @@ namespace Microsoft.EventGrid.SystemEvents { alias ServiceBusBaseEventData = { /** The namespace name of the Microsoft.ServiceBus resource. */ - namespaceName?: string; + namespaceName: string; /** The endpoint of the Microsoft.ServiceBus resource. */ - requestUri?: string; + requestUri: string; /** The entity type of the Microsoft.ServiceBus resource. Could be one of 'queue' or 'subscriber'. */ - entityType?: string; + entityType: string; + #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" /** The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null. */ - queueName?: string; + queueName: string | null; + #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" /** The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null. */ - topicName?: string; + topicName: string | null; + #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" /** The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null. */ - subscriptionName?: string; + subscriptionName: string | null; }; } diff --git a/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2018-01-01/GeneratedSystemEvents.json b/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2018-01-01/GeneratedSystemEvents.json index 48945635b761..1502b92e05fd 100644 --- a/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2018-01-01/GeneratedSystemEvents.json +++ b/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2018-01-01/GeneratedSystemEvents.json @@ -7844,17 +7844,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "ServiceBusActiveMessagesAvailableWithNoListenersEventData": { "type": "object", @@ -7874,17 +7885,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "ServiceBusDeadletterMessagesAvailablePeriodicNotificationsEventData": { "type": "object", @@ -7904,17 +7926,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "ServiceBusDeadletterMessagesAvailableWithNoListenersEventData": { "type": "object", @@ -7934,17 +7967,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "SignalRServiceClientConnectionConnectedEventData": { "type": "object", diff --git a/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/GeneratedSystemEvents.json b/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/GeneratedSystemEvents.json index 36bd7e604627..9c8e3c96edd7 100644 --- a/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/GeneratedSystemEvents.json +++ b/specification/eventgrid/data-plane/Microsoft.EventGrid/stable/2024-01-01/GeneratedSystemEvents.json @@ -7979,17 +7979,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "ServiceBusActiveMessagesAvailableWithNoListenersEventData": { "type": "object", @@ -8009,17 +8020,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "ServiceBusDeadletterMessagesAvailablePeriodicNotificationsEventData": { "type": "object", @@ -8039,17 +8061,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "ServiceBusDeadletterMessagesAvailableWithNoListenersEventData": { "type": "object", @@ -8069,17 +8102,28 @@ }, "queueName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null." + "description": "The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null.", + "x-nullable": true }, "topicName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true }, "subscriptionName": { "type": "string", - "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null." + "description": "The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null.", + "x-nullable": true } - } + }, + "required": [ + "namespaceName", + "requestUri", + "entityType", + "queueName", + "topicName", + "subscriptionName" + ] }, "SignalRServiceClientConnectionConnectedEventData": { "type": "object", From fa5a87b2c89011a23afead80bf4c40aca52dd68e Mon Sep 17 00:00:00 2001 From: Libba Lawrence Date: Tue, 3 Dec 2024 10:55:16 -0800 Subject: [PATCH 2/2] format --- .../Microsoft.ServiceBus/ServiceBus.tsp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp index a746b7e342cb..d88bd7e74682 100644 --- a/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp +++ b/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.ServiceBus/ServiceBus.tsp @@ -30,16 +30,16 @@ namespace Microsoft.EventGrid.SystemEvents { /** The entity type of the Microsoft.ServiceBus resource. Could be one of 'queue' or 'subscriber'. */ entityType: string; - #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" /** The name of the Microsoft.ServiceBus queue. If the entity type is of type 'subscriber', then this value will be null. */ + #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" queueName: string | null; - #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" /** The name of the Microsoft.ServiceBus topic. If the entity type is of type 'queue', then this value will be null. */ + #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" topicName: string | null; - #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" /** The name of the Microsoft.ServiceBus topic's subscription. If the entity type is of type 'queue', then this value will be null. */ + #suppress "@azure-tools/typespec-azure-core/no-nullable" "Nullable backcompat with existing models" subscriptionName: string | null; }; }