From dba6dbd30fa2c90419af272cd8f403e30212b5cf Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Tue, 3 Dec 2019 11:16:25 -0800 Subject: [PATCH 01/11] Added connection monitor to networkWatcher swagger --- .../stable/2019-11-01/networkWatcher.json | 2444 ++++++++++++----- 1 file changed, 1741 insertions(+), 703 deletions(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json index 3f128c108a16..48e48d39d5be 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json @@ -1525,6 +1525,502 @@ "final-state-via": "location" } } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkWatchers/{networkWatcherName}/connectionMonitors/{connectionMonitorName}": { + "put": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_CreateOrUpdate", + "description": "Create or update a connection monitor.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the connection monitor." + }, + { + "name": "parameters", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/ConnectionMonitor" + }, + "description": "Parameters that define the operation to create a connection monitor." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Update successful. The operation returns the resulting network watcher resource.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorResult" + } + }, + "201": { + "description": "Create successful. The operation returns the resulting network watcher resource.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Create connection monitor": { + "$ref": "./examples/NetworkWatcherConnectionMonitorCreate.json" + } + }, + "x-ms-long-running-operation": true, + "x-ms-long-running-operation-options": { + "final-state-via": "azure-async-operation" + } + }, + "get": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_Get", + "description": "Gets a connection monitor by name.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the connection monitor." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Request successful. The operation returns a connection monitor.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Get connection monitor": { + "$ref": "./examples/NetworkWatcherConnectionMonitorGet.json" + } + } + }, + "delete": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_Delete", + "description": "Deletes the specified connection monitor.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the connection monitor." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "204": { + "description": "Delete successful." + }, + "202": { + "description": "Accepted. The operation will complete asynchronously." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Delete connection monitor": { + "$ref": "./examples/NetworkWatcherConnectionMonitorDelete.json" + } + }, + "x-ms-long-running-operation": true, + "x-ms-long-running-operation-options": { + "final-state-via": "location" + } + }, + "patch": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_UpdateTags", + "description": "Update tags of the specified connection monitor.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the network watcher." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the connection monitor." + }, + { + "name": "parameters", + "in": "body", + "required": true, + "schema": { + "$ref": "./network.json#/definitions/TagsObject" + }, + "description": "Parameters supplied to update connection monitor tags." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Request successful. The operation returns updated connection monitor.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Update connection monitor tags": { + "$ref": "./examples/NetworkWatcherConnectionMonitorUpdateTags.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkWatchers/{networkWatcherName}/connectionMonitors/{connectionMonitorName}/stop": { + "post": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_Stop", + "description": "Stops the specified connection monitor.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the connection monitor." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Request successful. The operation stops the connection monitor." + }, + "202": { + "description": "Accepted. The operation will complete asynchronously." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Stop connection monitor": { + "$ref": "./examples/NetworkWatcherConnectionMonitorStop.json" + } + }, + "x-ms-long-running-operation": true, + "x-ms-long-running-operation-options": { + "final-state-via": "location" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkWatchers/{networkWatcherName}/connectionMonitors/{connectionMonitorName}/start": { + "post": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_Start", + "description": "Starts the specified connection monitor.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the connection monitor." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Request successful. The operation starts the connection monitor." + }, + "202": { + "description": "Accepted. The operation will complete asynchronously." + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Start connection monitor": { + "$ref": "./examples/NetworkWatcherConnectionMonitorStart.json" + } + }, + "x-ms-long-running-operation": true, + "x-ms-long-running-operation-options": { + "final-state-via": "location" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkWatchers/{networkWatcherName}/connectionMonitors/{connectionMonitorName}/query": { + "post": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_Query", + "description": "Query a snapshot of the most recent connection states.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "name": "connectionMonitorName", + "in": "path", + "required": true, + "type": "string", + "description": "The name given to the connection monitor." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Successful query of connection states.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorQueryResult" + } + }, + "202": { + "description": "Accepted query of connection states.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorQueryResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-examples": { + "Query connection monitor": { + "$ref": "./examples/NetworkWatcherConnectionMonitorQuery.json" + } + }, + "x-ms-long-running-operation": true, + "x-ms-long-running-operation-options": { + "final-state-via": "location" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkWatchers/{networkWatcherName}/connectionMonitors": { + "get": { + "tags": [ + "ConnectionMonitors" + ], + "operationId": "ConnectionMonitors_List", + "description": "Lists all connection monitors for the specified Network Watcher.", + "parameters": [ + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the resource group containing Network Watcher." + }, + { + "name": "networkWatcherName", + "in": "path", + "required": true, + "type": "string", + "description": "The name of the Network Watcher resource." + }, + { + "$ref": "./network.json#/parameters/ApiVersionParameter" + }, + { + "$ref": "./network.json#/parameters/SubscriptionIdParameter" + } + ], + "responses": { + "200": { + "description": "Successful connection monitor enumeration request.", + "schema": { + "$ref": "#/definitions/ConnectionMonitorListResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "./networkWatcher.json#/definitions/ErrorResponse" + } + } + }, + "x-ms-pageable": { + "nextLinkName": null + }, + "x-ms-examples": { + "List connection monitors": { + "$ref": "./examples/NetworkWatcherConnectionMonitorList.json" + } + } + } } }, "definitions": { @@ -2036,1024 +2532,1566 @@ }, "description": "Information about packet capture session." }, - "PacketCaptureResultProperties": { + "PacketCaptureResultProperties": { + "properties": { + "provisioningState": { + "readOnly": true, + "$ref": "./network.json#/definitions/ProvisioningState", + "description": "The provisioning state of the packet capture session." + } + }, + "allOf": [ + { + "$ref": "#/definitions/PacketCaptureParameters" + } + ], + "description": "The properties of a packet capture session." + }, + "PacketCaptureQueryStatusResult": { + "properties": { + "name": { + "type": "string", + "description": "The name of the packet capture resource." + }, + "id": { + "type": "string", + "description": "The ID of the packet capture resource." + }, + "captureStartTime": { + "type": "string", + "format": "date-time", + "description": "The start time of the packet capture session." + }, + "packetCaptureStatus": { + "type": "string", + "enum": [ + "NotStarted", + "Running", + "Stopped", + "Error", + "Unknown" + ], + "x-ms-enum": { + "name": "PcStatus", + "modelAsString": true + }, + "description": "The status of the packet capture session." + }, + "stopReason": { + "type": "string", + "description": "The reason the current packet capture session was stopped." + }, + "packetCaptureError": { + "type": "array", + "description": "List of errors of packet capture session.", + "items": { + "type": "string", + "enum": [ + "InternalError", + "AgentStopped", + "CaptureFailed", + "LocalFileFailed", + "StorageFailed" + ], + "x-ms-enum": { + "name": "PcError", + "modelAsString": true + } + } + } + }, + "description": "Status of packet capture session." + }, + "TroubleshootingParameters": { + "description": "Parameters that define the resource to troubleshoot.", + "required": [ + "targetResourceId", + "properties" + ], + "properties": { + "targetResourceId": { + "description": "The target resource to troubleshoot.", + "type": "string" + }, + "properties": { + "x-ms-client-flatten": true, + "$ref": "#/definitions/TroubleshootingProperties", + "description": "Properties of the troubleshooting resource." + } + } + }, + "QueryTroubleshootingParameters": { + "description": "Parameters that define the resource to query the troubleshooting result.", + "required": [ + "targetResourceId" + ], + "properties": { + "targetResourceId": { + "description": "The target resource ID to query the troubleshooting result.", + "type": "string" + } + } + }, + "TroubleshootingProperties": { + "description": "Storage location provided for troubleshoot.", + "required": [ + "storageId", + "storagePath" + ], + "properties": { + "storageId": { + "description": "The ID for the storage account to save the troubleshoot result.", + "type": "string" + }, + "storagePath": { + "description": "The path to the blob to save the troubleshoot result in.", + "type": "string" + } + } + }, + "TroubleshootingResult": { + "description": "Troubleshooting information gained from specified resource.", + "properties": { + "startTime": { + "type": "string", + "format": "date-time", + "description": "The start time of the troubleshooting." + }, + "endTime": { + "type": "string", + "format": "date-time", + "description": "The end time of the troubleshooting." + }, + "code": { + "type": "string", + "description": "The result code of the troubleshooting." + }, + "results": { + "type": "array", + "description": "Information from troubleshooting.", + "items": { + "$ref": "#/definitions/TroubleshootingDetails" + } + } + } + }, + "TroubleshootingDetails": { + "description": "Information gained from troubleshooting of specified resource.", + "properties": { + "id": { + "type": "string", + "description": "The id of the get troubleshoot operation." + }, + "reasonType": { + "type": "string", + "description": "Reason type of failure." + }, + "summary": { + "type": "string", + "description": "A summary of troubleshooting." + }, + "detail": { + "type": "string", + "description": "Details on troubleshooting results." + }, + "recommendedActions": { + "type": "array", + "description": "List of recommended actions.", + "items": { + "$ref": "#/definitions/TroubleshootingRecommendedActions" + } + } + } + }, + "TroubleshootingRecommendedActions": { + "description": "Recommended actions based on discovered issues.", + "properties": { + "actionId": { + "description": "ID of the recommended action.", + "type": "string" + }, + "actionText": { + "description": "Description of recommended actions.", + "type": "string" + }, + "actionUri": { + "description": "The uri linking to a documentation for the recommended troubleshooting actions.", + "type": "string" + }, + "actionUriText": { + "description": "The information from the URI for the recommended troubleshooting actions.", + "type": "string" + } + } + }, + "FlowLogProperties": { + "description": "Parameters that define the configuration of flow log.", + "required": [ + "storageId", + "enabled" + ], + "properties": { + "storageId": { + "description": "ID of the storage account which is used to store the flow log.", + "type": "string" + }, + "enabled": { + "description": "Flag to enable/disable flow logging.", + "type": "boolean" + }, + "retentionPolicy": { + "$ref": "#/definitions/RetentionPolicyParameters", + "description": "Parameters that define the retention policy for flow log." + }, + "format": { + "$ref": "#/definitions/FlowLogFormatParameters", + "description": "Parameters that define the flow log format." + } + } + }, + "FlowLogStatusParameters": { + "description": "Parameters that define a resource to query flow log and traffic analytics (optional) status.", + "required": [ + "targetResourceId" + ], "properties": { - "provisioningState": { - "readOnly": true, - "$ref": "./network.json#/definitions/ProvisioningState", - "description": "The provisioning state of the packet capture session." - } - }, - "allOf": [ - { - "$ref": "#/definitions/PacketCaptureParameters" + "targetResourceId": { + "description": "The target resource where getting the flow log and traffic analytics (optional) status.", + "type": "string" } - ], - "description": "The properties of a packet capture session." + } }, - "PacketCaptureQueryStatusResult": { + "RetentionPolicyParameters": { + "description": "Parameters that define the retention policy for flow log.", "properties": { - "name": { - "type": "string", - "description": "The name of the packet capture resource." - }, - "id": { - "type": "string", - "description": "The ID of the packet capture resource." - }, - "captureStartTime": { - "type": "string", - "format": "date-time", - "description": "The start time of the packet capture session." + "days": { + "description": "Number of days to retain flow log records.", + "type": "integer", + "default": 0 }, - "packetCaptureStatus": { + "enabled": { + "description": "Flag to enable/disable retention.", + "type": "boolean", + "default": false + } + } + }, + "FlowLogFormatParameters": { + "description": "Parameters that define the flow log format.", + "properties": { + "type": { "type": "string", + "description": "The file type of flow log.", "enum": [ - "NotStarted", - "Running", - "Stopped", - "Error", - "Unknown" + "JSON" ], "x-ms-enum": { - "name": "PcStatus", + "name": "FlowLogFormatType", "modelAsString": true - }, - "description": "The status of the packet capture session." - }, - "stopReason": { - "type": "string", - "description": "The reason the current packet capture session was stopped." - }, - "packetCaptureError": { - "type": "array", - "description": "List of errors of packet capture session.", - "items": { - "type": "string", - "enum": [ - "InternalError", - "AgentStopped", - "CaptureFailed", - "LocalFileFailed", - "StorageFailed" - ], - "x-ms-enum": { - "name": "PcError", - "modelAsString": true - } } + }, + "version": { + "description": "The version (revision) of the flow log.", + "type": "integer", + "default": 0 } - }, - "description": "Status of packet capture session." + } }, - "TroubleshootingParameters": { - "description": "Parameters that define the resource to troubleshoot.", + "FlowLogInformation": { + "description": "Information on the configuration of flow log and traffic analytics (optional) .", "required": [ "targetResourceId", "properties" ], "properties": { "targetResourceId": { - "description": "The target resource to troubleshoot.", + "description": "The ID of the resource to configure for flow log and traffic analytics (optional) .", "type": "string" }, "properties": { "x-ms-client-flatten": true, - "$ref": "#/definitions/TroubleshootingProperties", - "description": "Properties of the troubleshooting resource." + "$ref": "#/definitions/FlowLogProperties", + "description": "Properties of the flow log." + }, + "flowAnalyticsConfiguration": { + "$ref": "#/definitions/TrafficAnalyticsProperties", + "description": "Parameters that define the configuration of traffic analytics." } } }, - "QueryTroubleshootingParameters": { - "description": "Parameters that define the resource to query the troubleshooting result.", + "TrafficAnalyticsProperties": { + "description": "Parameters that define the configuration of traffic analytics.", "required": [ - "targetResourceId" + "networkWatcherFlowAnalyticsConfiguration" ], "properties": { - "targetResourceId": { - "description": "The target resource ID to query the troubleshooting result.", - "type": "string" + "networkWatcherFlowAnalyticsConfiguration": { + "$ref": "#/definitions/TrafficAnalyticsConfigurationProperties", + "description": "Parameters that define the configuration of traffic analytics." } } }, - "TroubleshootingProperties": { - "description": "Storage location provided for troubleshoot.", + "TrafficAnalyticsConfigurationProperties": { + "description": "Parameters that define the configuration of traffic analytics.", "required": [ - "storageId", - "storagePath" + "enabled" ], "properties": { - "storageId": { - "description": "The ID for the storage account to save the troubleshoot result.", + "enabled": { + "description": "Flag to enable/disable traffic analytics.", + "type": "boolean" + }, + "workspaceId": { + "description": "The resource guid of the attached workspace.", "type": "string" }, - "storagePath": { - "description": "The path to the blob to save the troubleshoot result in.", + "workspaceRegion": { + "description": "The location of the attached workspace.", + "type": "string" + }, + "workspaceResourceId": { + "description": "Resource Id of the attached workspace.", "type": "string" + }, + "trafficAnalyticsInterval": { + "description": "The interval in minutes which would decide how frequently TA service should do flow analytics.", + "type": "integer" } } }, - "TroubleshootingResult": { - "description": "Troubleshooting information gained from specified resource.", + "ConnectivityParameters": { + "description": "Parameters that determine how the connectivity check will be performed.", + "required": [ + "source", + "destination" + ], "properties": { - "startTime": { - "type": "string", - "format": "date-time", - "description": "The start time of the troubleshooting." + "source": { + "$ref": "#/definitions/ConnectivitySource", + "description": "The source of the connection." }, - "endTime": { - "type": "string", - "format": "date-time", - "description": "The end time of the troubleshooting." + "destination": { + "$ref": "#/definitions/ConnectivityDestination", + "description": "The destination of connection." }, - "code": { + "protocol": { "type": "string", - "description": "The result code of the troubleshooting." - }, - "results": { - "type": "array", - "description": "Information from troubleshooting.", - "items": { - "$ref": "#/definitions/TroubleshootingDetails" + "description": "Network protocol.", + "enum": [ + "Tcp", + "Http", + "Https", + "Icmp" + ], + "x-ms-enum": { + "name": "Protocol", + "modelAsString": true } + }, + "protocolConfiguration": { + "$ref": "#/definitions/ProtocolConfiguration", + "description": "Configuration of the protocol." + }, + "preferredIPVersion": { + "$ref": "./network.json#/definitions/IPVersion", + "description": "Preferred IP version of the connection." } } }, - "TroubleshootingDetails": { - "description": "Information gained from troubleshooting of specified resource.", + "ConnectivitySource": { + "description": "Parameters that define the source of the connection.", + "required": [ + "resourceId" + ], "properties": { - "id": { + "resourceId": { + "description": "The ID of the resource from which a connectivity check will be initiated.", + "type": "string" + }, + "port": { + "description": "The source port from which a connectivity check will be performed.", + "type": "integer" + } + } + }, + "ConnectivityDestination": { + "description": "Parameters that define destination of connection.", + "properties": { + "resourceId": { + "description": "The ID of the resource to which a connection attempt will be made.", + "type": "string" + }, + "address": { + "description": "The IP address or URI the resource to which a connection attempt will be made.", + "type": "string" + }, + "port": { + "description": "Port on which check connectivity will be performed.", + "type": "integer" + } + } + }, + "ConnectivityInformation": { + "description": "Information on the connectivity status.", + "properties": { + "hops": { + "readOnly": true, + "type": "array", + "description": "List of hops between the source and the destination.", + "items": { + "$ref": "#/definitions/ConnectivityHop" + } + }, + "connectionStatus": { + "readOnly": true, "type": "string", - "description": "The id of the get troubleshoot operation." + "enum": [ + "Unknown", + "Connected", + "Disconnected", + "Degraded" + ], + "x-ms-enum": { + "name": "ConnectionStatus", + "modelAsString": true + }, + "description": "The connection status." + }, + "avgLatencyInMs": { + "description": "Average latency in milliseconds.", + "readOnly": true, + "type": "integer" }, - "reasonType": { - "type": "string", - "description": "Reason type of failure." + "minLatencyInMs": { + "description": "Minimum latency in milliseconds.", + "readOnly": true, + "type": "integer" }, - "summary": { - "type": "string", - "description": "A summary of troubleshooting." + "maxLatencyInMs": { + "description": "Maximum latency in milliseconds.", + "readOnly": true, + "type": "integer" }, - "detail": { - "type": "string", - "description": "Details on troubleshooting results." + "probesSent": { + "description": "Total number of probes sent.", + "readOnly": true, + "type": "integer" }, - "recommendedActions": { - "type": "array", - "description": "List of recommended actions.", - "items": { - "$ref": "#/definitions/TroubleshootingRecommendedActions" - } + "probesFailed": { + "description": "Number of failed probes.", + "readOnly": true, + "type": "integer" } } }, - "TroubleshootingRecommendedActions": { - "description": "Recommended actions based on discovered issues.", + "ConnectivityHop": { + "description": "Information about a hop between the source and the destination.", "properties": { - "actionId": { - "description": "ID of the recommended action.", + "type": { + "description": "The type of the hop.", + "readOnly": true, "type": "string" }, - "actionText": { - "description": "Description of recommended actions.", + "id": { + "description": "The ID of the hop.", + "readOnly": true, "type": "string" }, - "actionUri": { - "description": "The uri linking to a documentation for the recommended troubleshooting actions.", + "address": { + "description": "The IP address of the hop.", + "readOnly": true, "type": "string" }, - "actionUriText": { - "description": "The information from the URI for the recommended troubleshooting actions.", + "resourceId": { + "description": "The ID of the resource corresponding to this hop.", + "readOnly": true, "type": "string" + }, + "nextHopIds": { + "readOnly": true, + "type": "array", + "description": "List of next hop identifiers.", + "items": { + "type": "string" + } + }, + "issues": { + "readOnly": true, + "type": "array", + "description": "List of issues.", + "items": { + "$ref": "#/definitions/ConnectivityIssue" + } } } }, - "FlowLogProperties": { - "description": "Parameters that define the configuration of flow log.", - "required": [ - "storageId", - "enabled" - ], + "ConnectivityIssue": { + "description": "Information about an issue encountered in the process of checking for connectivity.", "properties": { - "storageId": { - "description": "ID of the storage account which is used to store the flow log.", - "type": "string" + "origin": { + "readOnly": true, + "type": "string", + "enum": [ + "Local", + "Inbound", + "Outbound" + ], + "x-ms-enum": { + "name": "Origin", + "modelAsString": true + }, + "description": "The origin of the issue." }, - "enabled": { - "description": "Flag to enable/disable flow logging.", - "type": "boolean" + "severity": { + "readOnly": true, + "type": "string", + "enum": [ + "Error", + "Warning" + ], + "x-ms-enum": { + "name": "Severity", + "modelAsString": true + }, + "description": "The severity of the issue." }, - "retentionPolicy": { - "$ref": "#/definitions/RetentionPolicyParameters", - "description": "Parameters that define the retention policy for flow log." + "type": { + "readOnly": true, + "type": "string", + "enum": [ + "Unknown", + "AgentStopped", + "GuestFirewall", + "DnsResolution", + "SocketBind", + "NetworkSecurityRule", + "UserDefinedRoute", + "PortThrottled", + "Platform" + ], + "x-ms-enum": { + "name": "IssueType", + "modelAsString": true + }, + "description": "The type of issue." }, - "format": { - "$ref": "#/definitions/FlowLogFormatParameters", - "description": "Parameters that define the flow log format." + "context": { + "readOnly": true, + "type": "array", + "description": "Provides additional context on the issue.", + "items": { + "$ref": "#/definitions/IssueContext" + } } } }, - "FlowLogStatusParameters": { - "description": "Parameters that define a resource to query flow log and traffic analytics (optional) status.", - "required": [ - "targetResourceId" - ], - "properties": { - "targetResourceId": { - "description": "The target resource where getting the flow log and traffic analytics (optional) status.", - "type": "string" - } + "IssueContext": { + "description": "A key-value pair that provides additional context on the issue.", + "type": "object", + "additionalProperties": { + "type": "string" } }, - "RetentionPolicyParameters": { - "description": "Parameters that define the retention policy for flow log.", + "ProtocolConfiguration": { + "description": "Configuration of the protocol.", "properties": { - "days": { - "description": "Number of days to retain flow log records.", - "type": "integer", - "default": 0 - }, - "enabled": { - "description": "Flag to enable/disable retention.", - "type": "boolean", - "default": false + "HTTPConfiguration": { + "$ref": "#/definitions/HTTPConfiguration", + "description": "HTTP configuration of the connectivity check." } } }, - "FlowLogFormatParameters": { - "description": "Parameters that define the flow log format.", + "HTTPConfiguration": { "properties": { - "type": { + "method": { "type": "string", - "description": "The file type of flow log.", + "description": "HTTP method.", "enum": [ - "JSON" + "Get" ], "x-ms-enum": { - "name": "FlowLogFormatType", + "name": "HTTPMethod", "modelAsString": true } }, - "version": { - "description": "The version (revision) of the flow log.", - "type": "integer", - "default": 0 + "headers": { + "type": "array", + "description": "List of HTTP headers.", + "items": { + "$ref": "#/definitions/HTTPHeader" + } + }, + "validStatusCodes": { + "type": "array", + "items": { + "type": "integer" + }, + "description": "Valid status codes." } - } + }, + "description": "HTTP configuration of the connectivity check." }, - "FlowLogInformation": { - "description": "Information on the configuration of flow log and traffic analytics (optional) .", - "required": [ - "targetResourceId", - "properties" + "HTTPHeader": { + "properties": { + "name": { + "type": "string", + "description": "The name in HTTP header." + }, + "value": { + "type": "string", + "description": "The value in HTTP header." + } + }, + "description": "The HTTP header." + }, + "AzureReachabilityReportParameters": { + "properties": { + "providerLocation": { + "$ref": "#/definitions/AzureReachabilityReportLocation", + "description": "Parameters that define a geographic location." + }, + "providers": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Internet service providers." + }, + "azureLocations": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Optional Azure regions to scope the query to." + }, + "startTime": { + "type": "string", + "format": "date-time", + "description": "The start time for the Azure reachability report." + }, + "endTime": { + "type": "string", + "format": "date-time", + "description": "The end time for the Azure reachability report." + } + }, + "required": [ + "providerLocation", + "startTime", + "endTime" ], + "description": "Geographic and time constraints for Azure reachability report." + }, + "AzureReachabilityReportLocation": { "properties": { - "targetResourceId": { - "description": "The ID of the resource to configure for flow log and traffic analytics (optional) .", - "type": "string" + "country": { + "type": "string", + "description": "The name of the country." }, - "properties": { - "x-ms-client-flatten": true, - "$ref": "#/definitions/FlowLogProperties", - "description": "Properties of the flow log." + "state": { + "type": "string", + "description": "The name of the state." }, - "flowAnalyticsConfiguration": { - "$ref": "#/definitions/TrafficAnalyticsProperties", - "description": "Parameters that define the configuration of traffic analytics." + "city": { + "type": "string", + "description": "The name of the city or town." } - } - }, - "TrafficAnalyticsProperties": { - "description": "Parameters that define the configuration of traffic analytics.", + }, "required": [ - "networkWatcherFlowAnalyticsConfiguration" + "country" ], + "description": "Parameters that define a geographic location." + }, + "AzureReachabilityReport": { "properties": { - "networkWatcherFlowAnalyticsConfiguration": { - "$ref": "#/definitions/TrafficAnalyticsConfigurationProperties", - "description": "Parameters that define the configuration of traffic analytics." + "aggregationLevel": { + "type": "string", + "description": "The aggregation level of Azure reachability report. Can be Country, State or City." + }, + "providerLocation": { + "$ref": "#/definitions/AzureReachabilityReportLocation", + "description": "Parameters that define a geographic location." + }, + "reachabilityReport": { + "type": "array", + "description": "List of Azure reachability report items.", + "items": { + "$ref": "#/definitions/AzureReachabilityReportItem" + } } - } - }, - "TrafficAnalyticsConfigurationProperties": { - "description": "Parameters that define the configuration of traffic analytics.", + }, "required": [ - "enabled" + "aggregationLevel", + "providerLocation", + "reachabilityReport" ], + "description": "Azure reachability report details." + }, + "AzureReachabilityReportItem": { "properties": { - "enabled": { - "description": "Flag to enable/disable traffic analytics.", - "type": "boolean" - }, - "workspaceId": { - "description": "The resource guid of the attached workspace.", - "type": "string" - }, - "workspaceRegion": { - "description": "The location of the attached workspace.", - "type": "string" + "provider": { + "type": "string", + "description": "The Internet service provider." }, - "workspaceResourceId": { - "description": "Resource Id of the attached workspace.", - "type": "string" + "azureLocation": { + "type": "string", + "description": "The Azure region." }, - "trafficAnalyticsInterval": { - "description": "The interval in minutes which would decide how frequently TA service should do flow analytics.", - "type": "integer" + "latencies": { + "type": "array", + "description": "List of latency details for each of the time series.", + "items": { + "$ref": "#/definitions/AzureReachabilityReportLatencyInfo" + } } - } + }, + "description": "Azure reachability report details for a given provider location." }, - "ConnectivityParameters": { - "description": "Parameters that determine how the connectivity check will be performed.", - "required": [ - "source", - "destination" - ], + "AzureReachabilityReportLatencyInfo": { "properties": { - "source": { - "$ref": "#/definitions/ConnectivitySource", - "description": "The source of the connection." + "timeStamp": { + "type": "string", + "format": "date-time", + "description": "The time stamp." }, - "destination": { - "$ref": "#/definitions/ConnectivityDestination", - "description": "The destination of connection." + "score": { + "type": "integer", + "description": "The relative latency score between 1 and 100, higher values indicating a faster connection.", + "minimum": 1, + "maximum": 100 + } + }, + "description": "Details on latency for a time series." + }, + "AvailableProvidersListParameters": { + "properties": { + "azureLocations": { + "type": "array", + "items": { + "type": "string" + }, + "description": "A list of Azure regions." }, - "protocol": { + "country": { "type": "string", - "description": "Network protocol.", - "enum": [ - "Tcp", - "Http", - "Https", - "Icmp" - ], - "x-ms-enum": { - "name": "Protocol", - "modelAsString": true - } + "description": "The country for available providers list." }, - "protocolConfiguration": { - "$ref": "#/definitions/ProtocolConfiguration", - "description": "Configuration of the protocol." + "state": { + "type": "string", + "description": "The state for available providers list." }, - "preferredIPVersion": { - "$ref": "./network.json#/definitions/IPVersion", - "description": "Preferred IP version of the connection." + "city": { + "type": "string", + "description": "The city or town for available providers list." } - } + }, + "description": "Constraints that determine the list of available Internet service providers." }, - "ConnectivitySource": { - "description": "Parameters that define the source of the connection.", + "AvailableProvidersList": { + "properties": { + "countries": { + "type": "array", + "description": "List of available countries.", + "items": { + "$ref": "#/definitions/AvailableProvidersListCountry" + } + } + }, "required": [ - "resourceId" + "countries" ], + "description": "List of available countries with details." + }, + "AvailableProvidersListCountry": { "properties": { - "resourceId": { - "description": "The ID of the resource from which a connectivity check will be initiated.", - "type": "string" + "countryName": { + "type": "string", + "description": "The country name." }, - "port": { - "description": "The source port from which a connectivity check will be performed.", - "type": "integer" + "providers": { + "type": "array", + "items": { + "type": "string" + }, + "description": "A list of Internet service providers." + }, + "states": { + "type": "array", + "description": "List of available states in the country.", + "items": { + "$ref": "#/definitions/AvailableProvidersListState" + } } - } + }, + "description": "Country details." }, - "ConnectivityDestination": { - "description": "Parameters that define destination of connection.", + "AvailableProvidersListState": { "properties": { - "resourceId": { - "description": "The ID of the resource to which a connection attempt will be made.", - "type": "string" + "stateName": { + "type": "string", + "description": "The state name." }, - "address": { - "description": "The IP address or URI the resource to which a connection attempt will be made.", - "type": "string" + "providers": { + "type": "array", + "items": { + "type": "string" + }, + "description": "A list of Internet service providers." }, - "port": { - "description": "Port on which check connectivity will be performed.", - "type": "integer" + "cities": { + "type": "array", + "description": "List of available cities or towns in the state.", + "items": { + "$ref": "#/definitions/AvailableProvidersListCity" + } } - } + }, + "description": "State details." }, - "ConnectivityInformation": { - "description": "Information on the connectivity status.", + "AvailableProvidersListCity": { "properties": { - "hops": { - "readOnly": true, + "cityName": { + "type": "string", + "description": "The city or town name." + }, + "providers": { "type": "array", - "description": "List of hops between the source and the destination.", "items": { - "$ref": "#/definitions/ConnectivityHop" - } + "type": "string" + }, + "description": "A list of Internet service providers." + } + }, + "description": "City or town details." + }, + "NetworkConfigurationDiagnosticParameters": { + "description": "Parameters to get network configuration diagnostic.", + "required": [ + "targetResourceId", + "profiles" + ], + "properties": { + "targetResourceId": { + "type": "string", + "description": "The ID of the target resource to perform network configuration diagnostic. Valid options are VM, NetworkInterface, VMSS/NetworkInterface and Application Gateway." }, - "connectionStatus": { - "readOnly": true, + "verbosityLevel": { "type": "string", "enum": [ - "Unknown", - "Connected", - "Disconnected", - "Degraded" + "Normal", + "Minimum", + "Full" ], "x-ms-enum": { - "name": "ConnectionStatus", + "name": "VerbosityLevel", "modelAsString": true }, - "description": "The connection status." - }, - "avgLatencyInMs": { - "description": "Average latency in milliseconds.", - "readOnly": true, - "type": "integer" - }, - "minLatencyInMs": { - "description": "Minimum latency in milliseconds.", - "readOnly": true, - "type": "integer" - }, - "maxLatencyInMs": { - "description": "Maximum latency in milliseconds.", - "readOnly": true, - "type": "integer" - }, - "probesSent": { - "description": "Total number of probes sent.", - "readOnly": true, - "type": "integer" + "description": "Verbosity level." }, - "probesFailed": { - "description": "Number of failed probes.", - "readOnly": true, - "type": "integer" + "profiles": { + "type": "array", + "description": "List of network configuration diagnostic profiles.", + "items": { + "$ref": "#/definitions/NetworkConfigurationDiagnosticProfile" + } } } }, - "ConnectivityHop": { - "description": "Information about a hop between the source and the destination.", + "NetworkConfigurationDiagnosticProfile": { + "description": "Parameters to compare with network configuration.", + "required": [ + "direction", + "protocol", + "source", + "destination", + "destinationPort" + ], "properties": { - "type": { - "description": "The type of the hop.", - "readOnly": true, - "type": "string" + "direction": { + "$ref": "#/definitions/Direction", + "description": "The direction of the traffic." }, - "id": { - "description": "The ID of the hop.", - "readOnly": true, - "type": "string" + "protocol": { + "type": "string", + "description": "Protocol to be verified on. Accepted values are '*', TCP, UDP." }, - "address": { - "description": "The IP address of the hop.", - "readOnly": true, - "type": "string" + "source": { + "type": "string", + "description": "Traffic source. Accepted values are '*', IP Address/CIDR, Service Tag." }, - "resourceId": { - "description": "The ID of the resource corresponding to this hop.", - "readOnly": true, - "type": "string" + "destination": { + "type": "string", + "description": "Traffic destination. Accepted values are: '*', IP Address/CIDR, Service Tag." }, - "nextHopIds": { + "destinationPort": { + "type": "string", + "description": "Traffic destination port. Accepted values are '*' and a single port in the range (0 - 65535)." + } + } + }, + "NetworkConfigurationDiagnosticResponse": { + "description": "Results of network configuration diagnostic on the target resource.", + "properties": { + "results": { "readOnly": true, "type": "array", - "description": "List of next hop identifiers.", + "description": "List of network configuration diagnostic results.", "items": { - "type": "string" + "$ref": "#/definitions/NetworkConfigurationDiagnosticResult" } + } + } + }, + "NetworkConfigurationDiagnosticResult": { + "description": "Network configuration diagnostic result corresponded to provided traffic query.", + "properties": { + "profile": { + "$ref": "#/definitions/NetworkConfigurationDiagnosticProfile", + "description": "Network configuration diagnostic profile." }, - "issues": { + "networkSecurityGroupResult": { + "$ref": "#/definitions/NetworkSecurityGroupResult", + "description": "Network security group result." + } + } + }, + "NetworkSecurityGroupResult": { + "description": "Network configuration diagnostic result corresponded provided traffic query.", + "properties": { + "securityRuleAccessResult": { + "$ref": "./networkSecurityGroup.json#/definitions/SecurityRuleAccess", + "description": "The network traffic is allowed or denied." + }, + "evaluatedNetworkSecurityGroups": { "readOnly": true, "type": "array", - "description": "List of issues.", + "description": "List of results network security groups diagnostic.", "items": { - "$ref": "#/definitions/ConnectivityIssue" + "$ref": "#/definitions/EvaluatedNetworkSecurityGroup" } } } }, - "ConnectivityIssue": { - "description": "Information about an issue encountered in the process of checking for connectivity.", + "EvaluatedNetworkSecurityGroup": { + "description": "Results of network security group evaluation.", "properties": { - "origin": { - "readOnly": true, + "networkSecurityGroupId": { "type": "string", - "enum": [ - "Local", - "Inbound", - "Outbound" - ], - "x-ms-enum": { - "name": "Origin", - "modelAsString": true - }, - "description": "The origin of the issue." + "description": "Network security group ID." }, - "severity": { - "readOnly": true, + "appliedTo": { "type": "string", - "enum": [ - "Error", - "Warning" - ], - "x-ms-enum": { - "name": "Severity", - "modelAsString": true - }, - "description": "The severity of the issue." + "description": "Resource ID of nic or subnet to which network security group is applied." }, - "type": { - "readOnly": true, - "type": "string", - "enum": [ - "Unknown", - "AgentStopped", - "GuestFirewall", - "DnsResolution", - "SocketBind", - "NetworkSecurityRule", - "UserDefinedRoute", - "PortThrottled", - "Platform" - ], - "x-ms-enum": { - "name": "IssueType", - "modelAsString": true - }, - "description": "The type of issue." + "matchedRule": { + "$ref": "#/definitions/MatchedRule", + "description": "Matched network security rule." }, - "context": { + "rulesEvaluationResult": { "readOnly": true, "type": "array", - "description": "Provides additional context on the issue.", + "description": "List of network security rules evaluation results.", "items": { - "$ref": "#/definitions/IssueContext" + "$ref": "#/definitions/NetworkSecurityRulesEvaluationResult" } } } }, - "IssueContext": { - "description": "A key-value pair that provides additional context on the issue.", - "type": "object", - "additionalProperties": { - "type": "string" - } - }, - "ProtocolConfiguration": { - "description": "Configuration of the protocol.", + "MatchedRule": { + "description": "Matched rule.", "properties": { - "HTTPConfiguration": { - "$ref": "#/definitions/HTTPConfiguration", - "description": "HTTP configuration of the connectivity check." + "ruleName": { + "type": "string", + "description": "Name of the matched network security rule." + }, + "action": { + "type": "string", + "description": "The network traffic is allowed or denied. Possible values are 'Allow' and 'Deny'." } } }, - "HTTPConfiguration": { + "NetworkSecurityRulesEvaluationResult": { + "description": "Network security rules evaluation result.", "properties": { - "method": { + "name": { "type": "string", - "description": "HTTP method.", - "enum": [ - "Get" - ], - "x-ms-enum": { - "name": "HTTPMethod", - "modelAsString": true - } + "description": "Name of the network security rule." }, - "headers": { - "type": "array", - "description": "List of HTTP headers.", - "items": { - "$ref": "#/definitions/HTTPHeader" - } + "protocolMatched": { + "type": "boolean", + "description": "Value indicating whether protocol is matched." }, - "validStatusCodes": { - "type": "array", - "items": { - "type": "integer" - }, - "description": "Valid status codes." + "sourceMatched": { + "type": "boolean", + "description": "Value indicating whether source is matched." + }, + "sourcePortMatched": { + "type": "boolean", + "description": "Value indicating whether source port is matched." + }, + "destinationMatched": { + "type": "boolean", + "description": "Value indicating whether destination is matched." + }, + "destinationPortMatched": { + "type": "boolean", + "description": "Value indicating whether destination port is matched." } - }, - "description": "HTTP configuration of the connectivity check." + } }, - "HTTPHeader": { + "Direction": { + "type": "string", + "description": "The direction of the traffic.", + "enum": [ + "Inbound", + "Outbound" + ], + "x-ms-enum": { + "name": "Direction", + "modelAsString": true + } + }, + "ConnectionMonitor": { "properties": { - "name": { + "location": { "type": "string", - "description": "The name in HTTP header." + "description": "Connection monitor location." }, - "value": { - "type": "string", - "description": "The value in HTTP header." + "tags": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "Connection monitor tags." + }, + "properties": { + "x-ms-client-flatten": true, + "$ref": "#/definitions/ConnectionMonitorParameters", + "description": "Properties of the connection monitor." } }, - "description": "The HTTP header." + "required": [ + "properties" + ], + "description": "Parameters that define the operation to create a connection monitor." }, - "AzureReachabilityReportParameters": { + "ConnectionMonitorParameters": { "properties": { - "providerLocation": { - "$ref": "#/definitions/AzureReachabilityReportLocation", - "description": "Parameters that define a geographic location." + "source": { + "$ref": "#/definitions/ConnectionMonitorSource", + "description": "Describes the source of connection monitor." }, - "providers": { + "destination": { + "$ref": "#/definitions/ConnectionMonitorDestination", + "description": "Describes the destination of connection monitor." + }, + "autoStart": { + "type": "boolean", + "default": true, + "description": "Determines if the connection monitor will start automatically once created." + }, + "monitoringIntervalInSeconds": { + "type": "integer", + "default": 60, + "description": "Monitoring interval in seconds." + }, + "endpoints": { "type": "array", + "description": "List of connection monitor endpoints.", "items": { - "type": "string" - }, - "description": "List of Internet service providers." + "$ref": "#/definitions/ConnectionMonitorEndpoint" + } }, - "azureLocations": { + "testConfigurations": { "type": "array", + "description": "List of connection monitor test configurations.", "items": { - "type": "string" - }, - "description": "Optional Azure regions to scope the query to." + "$ref": "#/definitions/ConnectionMonitorTestConfiguration" + } }, - "startTime": { - "type": "string", - "format": "date-time", - "description": "The start time for the Azure reachability report." + "testGroups": { + "type": "array", + "description": "List of connection monitor test groups.", + "items": { + "$ref": "#/definitions/ConnectionMonitorTestGroup" + } }, - "endTime": { + "outputs": { + "type": "array", + "description": "List of connection monitor outputs.", + "items": { + "$ref": "#/definitions/ConnectionMonitorOutput" + } + }, + "notes": { "type": "string", - "format": "date-time", - "description": "The end time for the Azure reachability report." + "description": "Optional notes to be associated with the connection monitor." } }, - "required": [ - "providerLocation", - "startTime", - "endTime" - ], - "description": "Geographic and time constraints for Azure reachability report." + "description": "Parameters that define the operation to create a connection monitor." }, - "AzureReachabilityReportLocation": { + "ConnectionMonitorSource": { "properties": { - "country": { - "type": "string", - "description": "The name of the country." - }, - "state": { + "resourceId": { "type": "string", - "description": "The name of the state." + "description": "The ID of the resource used as the source by connection monitor." }, - "city": { - "type": "string", - "description": "The name of the city or town." + "port": { + "type": "integer", + "description": "The source port used by connection monitor." } }, "required": [ - "country" + "resourceId" ], - "description": "Parameters that define a geographic location." + "description": "Describes the source of connection monitor." }, - "AzureReachabilityReport": { + "ConnectionMonitorDestination": { "properties": { - "aggregationLevel": { + "resourceId": { "type": "string", - "description": "The aggregation level of Azure reachability report. Can be Country, State or City." + "description": "The ID of the resource used as the destination by connection monitor." }, - "providerLocation": { - "$ref": "#/definitions/AzureReachabilityReportLocation", - "description": "Parameters that define a geographic location." + "address": { + "type": "string", + "description": "Address of the connection monitor destination (IP or domain name)." }, - "reachabilityReport": { - "type": "array", - "description": "List of Azure reachability report items.", - "items": { - "$ref": "#/definitions/AzureReachabilityReportItem" - } + "port": { + "type": "integer", + "description": "The destination port used by connection monitor." } }, - "required": [ - "aggregationLevel", - "providerLocation", - "reachabilityReport" - ], - "description": "Azure reachability report details." + "description": "Describes the destination of connection monitor." }, - "AzureReachabilityReportItem": { + "ConnectionMonitorEndpoint": { "properties": { - "provider": { + "name": { "type": "string", - "description": "The Internet service provider." + "description": "The name of the connection monitor endpoint." }, - "azureLocation": { + "resourceId": { "type": "string", - "description": "The Azure region." + "description": "Resource ID of the connection monitor endpoint." }, - "latencies": { + "address": { + "type": "string", + "description": "Address of the connection monitor endpoint (IP or domain name)." + }, + "filter": { + "$ref": "#/definitions/ConnectionMonitorEndpointFilter", + "description": "Filter for sub-items within the endpoint." + } + }, + "description": "Describes the connection monitor endpoint." + }, + "ConnectionMonitorEndpointFilter": { + "properties": { + "type": { + "type": "string", + "enum": [ + "Include" + ], + "x-ms-enum": { + "name": "ConnectionMonitorEndpointFilterType", + "modelAsString": true + }, + "description": "The behavior of the endpoint filter. Currently only 'Include' is supported." + }, + "items": { "type": "array", - "description": "List of latency details for each of the time series.", + "description": "List of items in the filter.", "items": { - "$ref": "#/definitions/AzureReachabilityReportLatencyInfo" + "$ref": "#/definitions/ConnectionMonitorEndpointFilterItem" } } }, - "description": "Azure reachability report details for a given provider location." + "description": "Describes the connection monitor endpoint filter." }, - "AzureReachabilityReportLatencyInfo": { + "ConnectionMonitorEndpointFilterItem": { "properties": { - "timeStamp": { + "type": { "type": "string", - "format": "date-time", - "description": "The time stamp." + "enum": [ + "AgentAddress" + ], + "x-ms-enum": { + "name": "ConnectionMonitorEndpointFilterItemType", + "modelAsString": true + }, + "description": "The type of item included in the filter. Currently only 'AgentAddress' is supported." }, - "score": { - "type": "integer", - "description": "The relative latency score between 1 and 100, higher values indicating a faster connection.", - "minimum": 1, - "maximum": 100 + "address": { + "type": "string", + "description": "The address of the filter item." } }, - "description": "Details on latency for a time series." + "description": "Describes the connection monitor endpoint filter item." }, - "AvailableProvidersListParameters": { + "ConnectionMonitorTestGroup": { "properties": { - "azureLocations": { + "name": { + "type": "string", + "description": "The name of the connection monitor test group." + }, + "disable": { + "type": "boolean", + "description": "Value indicating whether test group is disabled." + }, + "testConfigurations": { "type": "array", "items": { "type": "string" }, - "description": "A list of Azure regions." + "description": "List of test configuration names." }, - "country": { + "sources": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of source endpoint names." + }, + "destinations": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of destination endpoint names." + } + }, + "description": "Describes the connection monitor test group." + }, + "ConnectionMonitorTestConfiguration": { + "properties": { + "name": { "type": "string", - "description": "The country for available providers list." + "description": "The name of the connection monitor test configuration." }, - "state": { + "testFrequencySec": { + "type": "integer", + "description": "The frequency of test evaluation, in seconds." + }, + "protocol": { "type": "string", - "description": "The state for available providers list." + "enum": [ + "Tcp", + "Http", + "Icmp" + ], + "x-ms-enum": { + "name": "ConnectionMonitorTestConfigurationProtocol", + "modelAsString": true + }, + "description": "The protocol to use in test evaluation." }, - "city": { + "preferredIPVersion": { "type": "string", - "description": "The city or town for available providers list." + "enum": [ + "IPv4", + "IPv6" + ], + "x-ms-enum": { + "name": "PreferredIPVersion", + "modelAsString": true + }, + "description": "The preferred IP version to use in test evaluation. The connection monitor may choose to use a different version depending on other parameters." + }, + "httpConfiguration": { + "$ref": "#/definitions/ConnectionMonitorHttpConfiguration", + "description": "The parameters used to perform test evaluation over HTTP." + }, + "tcpConfiguration": { + "$ref": "#/definitions/ConnectionMonitorTcpConfiguration", + "description": "The parameters used to perform test evaluation over TCP." + }, + "icmpConfiguration": { + "$ref": "#/definitions/ConnectionMonitorIcmpConfiguration", + "description": "The parameters used to perform test evaluation over ICMP." + }, + "successThreshold": { + "$ref": "#/definitions/ConnectionMonitorSuccessThreshold", + "description": "The threshold for declaring a test successful." } }, - "description": "Constraints that determine the list of available Internet service providers." + "description": "Describes a connection monitor test configuration." }, - "AvailableProvidersList": { + "ConnectionMonitorHttpConfiguration": { "properties": { - "countries": { + "port": { + "type": "integer", + "description": "The port to connect to." + }, + "method": { + "type": "string", + "description": "The HTTP method to use.", + "enum": [ + "Get", + "Post" + ], + "x-ms-enum": { + "name": "HTTPConfigurationMethod", + "modelAsString": true + } + }, + "path": { + "type": "string", + "description": "The path component of the URI. For instance, \"/dir1/dir2\"" + }, + "requestHeaders": { "type": "array", - "description": "List of available countries.", + "description": "The HTTP headers to transmit with the request.", "items": { - "$ref": "#/definitions/AvailableProvidersListCountry" + "$ref": "#/definitions/HTTPHeader" } - } - }, - "required": [ - "countries" - ], - "description": "List of available countries with details." - }, - "AvailableProvidersListCountry": { - "properties": { - "countryName": { - "type": "string", - "description": "The country name." }, - "providers": { + "validStatusCodeRanges": { "type": "array", "items": { "type": "string" }, - "description": "A list of Internet service providers." + "description": "HTTP status codes to consider successful. For instance, \"2xx,301-304,418\"" }, - "states": { - "type": "array", - "description": "List of available states in the country.", - "items": { - "$ref": "#/definitions/AvailableProvidersListState" - } + "preferHTTPS": { + "type": "boolean", + "description": "Value indicating whether HTTPS is preferred over HTTP in cases where the choice is not explicit." + } + }, + "description": "Describes the HTTP configuration." + }, + "ConnectionMonitorTcpConfiguration": { + "properties": { + "port": { + "type": "integer", + "description": "The port to connect to." + }, + "disableTraceRoute": { + "type": "boolean", + "description": "Value indicating whether path evaluation with traceroute should be disabled." + } + }, + "description": "Describes the TCP configuration." + }, + "ConnectionMonitorIcmpConfiguration": { + "properties": { + "disableTraceRoute": { + "type": "boolean", + "description": "Value indicating whether path evaluation with traceroute should be disabled." } }, - "description": "Country details." + "description": "Describes the ICMP configuration." }, - "AvailableProvidersListState": { + "ConnectionMonitorSuccessThreshold": { "properties": { - "stateName": { - "type": "string", - "description": "The state name." - }, - "providers": { - "type": "array", - "items": { - "type": "string" - }, - "description": "A list of Internet service providers." + "checksFailedPercent": { + "type": "integer", + "description": "The maximum percentage of failed checks permitted for a test to evaluate as successful." }, - "cities": { - "type": "array", - "description": "List of available cities or towns in the state.", - "items": { - "$ref": "#/definitions/AvailableProvidersListCity" - } + "roundTripTimeMs": { + "type": "integer", + "description": "The maximum round-trip time in milliseconds permitted for a test to evaluate as successful." } }, - "description": "State details." + "description": "Describes the threshold for declaring a test successful." }, - "AvailableProvidersListCity": { + "ConnectionMonitorOutput": { "properties": { - "cityName": { + "type": { "type": "string", - "description": "The city or town name." + "description": "Connection monitor output destination type. Currently, only \"Workspace\" is supported.", + "enum": [ + "Workspace" + ], + "x-ms-enum": { + "name": "OutputType", + "modelAsString": true + } }, - "providers": { - "type": "array", - "items": { - "type": "string" - }, - "description": "A list of Internet service providers." + "workspaceSettings": { + "$ref": "#/definitions/ConnectionMonitorWorkspaceSettings", + "description": "Describes the settings for producing output into a log analytics workspace." } }, - "description": "City or town details." + "description": "Describes a connection monitor output destination." }, - "NetworkConfigurationDiagnosticParameters": { - "description": "Parameters to get network configuration diagnostic.", - "required": [ - "targetResourceId", - "profiles" - ], + "ConnectionMonitorWorkspaceSettings": { "properties": { - "targetResourceId": { + "workspaceResourceId": { "type": "string", - "description": "The ID of the target resource to perform network configuration diagnostic. Valid options are VM, NetworkInterface, VMSS/NetworkInterface and Application Gateway." - }, - "verbosityLevel": { + "description": "Log analytics workspace resource ID." + } + }, + "description": "Describes the settings for producing output into a log analytics workspace." + }, + "ConnectionStateSnapshot": { + "properties": { + "connectionState": { "type": "string", "enum": [ - "Normal", - "Minimum", - "Full" + "Reachable", + "Unreachable", + "Unknown" ], "x-ms-enum": { - "name": "VerbosityLevel", + "name": "ConnectionState", "modelAsString": true }, - "description": "Verbosity level." - }, - "profiles": { - "type": "array", - "description": "List of network configuration diagnostic profiles.", - "items": { - "$ref": "#/definitions/NetworkConfigurationDiagnosticProfile" - } - } - } - }, - "NetworkConfigurationDiagnosticProfile": { - "description": "Parameters to compare with network configuration.", - "required": [ - "direction", - "protocol", - "source", - "destination", - "destinationPort" - ], - "properties": { - "direction": { - "$ref": "#/definitions/Direction", - "description": "The direction of the traffic." + "description": "The connection state." }, - "protocol": { + "startTime": { "type": "string", - "description": "Protocol to be verified on. Accepted values are '*', TCP, UDP." + "format": "date-time", + "description": "The start time of the connection snapshot." }, - "source": { + "endTime": { "type": "string", - "description": "Traffic source. Accepted values are '*', IP Address/CIDR, Service Tag." + "format": "date-time", + "description": "The end time of the connection snapshot." }, - "destination": { + "evaluationState": { "type": "string", - "description": "Traffic destination. Accepted values are: '*', IP Address/CIDR, Service Tag." + "enum": [ + "NotStarted", + "InProgress", + "Completed" + ], + "x-ms-enum": { + "name": "EvaluationState", + "modelAsString": true + }, + "description": "Connectivity analysis evaluation state." }, - "destinationPort": { - "type": "string", - "description": "Traffic destination port. Accepted values are '*' and a single port in the range (0 - 65535)." - } - } - }, - "NetworkConfigurationDiagnosticResponse": { - "description": "Results of network configuration diagnostic on the target resource.", - "properties": { - "results": { + "avgLatencyInMs": { + "type": "integer", + "description": "Average latency in ms." + }, + "minLatencyInMs": { + "type": "integer", + "description": "Minimum latency in ms." + }, + "maxLatencyInMs": { + "type": "integer", + "description": "Maximum latency in ms." + }, + "probesSent": { + "type": "integer", + "description": "The number of sent probes." + }, + "probesFailed": { + "type": "integer", + "description": "The number of failed probes." + }, + "hops": { "readOnly": true, "type": "array", - "description": "List of network configuration diagnostic results.", + "description": "List of hops between the source and the destination.", "items": { - "$ref": "#/definitions/NetworkConfigurationDiagnosticResult" + "$ref": "./networkWatcher.json#/definitions/ConnectivityHop" } } - } - }, - "NetworkConfigurationDiagnosticResult": { - "description": "Network configuration diagnostic result corresponded to provided traffic query.", - "properties": { - "profile": { - "$ref": "#/definitions/NetworkConfigurationDiagnosticProfile", - "description": "Network configuration diagnostic profile." - }, - "networkSecurityGroupResult": { - "$ref": "#/definitions/NetworkSecurityGroupResult", - "description": "Network security group result." - } - } + }, + "description": "Connection state snapshot." }, - "NetworkSecurityGroupResult": { - "description": "Network configuration diagnostic result corresponded provided traffic query.", + "ConnectionMonitorListResult": { "properties": { - "securityRuleAccessResult": { - "$ref": "./networkSecurityGroup.json#/definitions/SecurityRuleAccess", - "description": "The network traffic is allowed or denied." - }, - "evaluatedNetworkSecurityGroups": { - "readOnly": true, + "value": { "type": "array", - "description": "List of results network security groups diagnostic.", "items": { - "$ref": "#/definitions/EvaluatedNetworkSecurityGroup" - } + "$ref": "#/definitions/ConnectionMonitorResult" + }, + "description": "Information about connection monitors." } - } + }, + "description": "List of connection monitors." }, - "EvaluatedNetworkSecurityGroup": { - "description": "Results of network security group evaluation.", + "ConnectionMonitorResult": { + "x-ms-azure-resource": true, "properties": { - "networkSecurityGroupId": { + "name": { + "readOnly": true, "type": "string", - "description": "Network security group ID." + "description": "Name of the connection monitor." }, - "appliedTo": { + "id": { + "readOnly": true, "type": "string", - "description": "Resource ID of nic or subnet to which network security group is applied." + "description": "ID of the connection monitor." }, - "matchedRule": { - "$ref": "#/definitions/MatchedRule", - "description": "Matched network security rule." + "etag": { + "type": "string", + "default": "A unique read-only string that changes whenever the resource is updated.", + "description": "A unique read-only string that changes whenever the resource is updated." }, - "rulesEvaluationResult": { + "type": { "readOnly": true, - "type": "array", - "description": "List of network security rules evaluation results.", - "items": { - "$ref": "#/definitions/NetworkSecurityRulesEvaluationResult" - } + "type": "string", + "description": "Connection monitor type." + }, + "location": { + "type": "string", + "description": "Connection monitor location." + }, + "tags": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "Connection monitor tags." + }, + "properties": { + "x-ms-client-flatten": true, + "$ref": "#/definitions/ConnectionMonitorResultProperties", + "description": "Properties of the connection monitor result." } - } + }, + "description": "Information about the connection monitor." }, - "MatchedRule": { - "description": "Matched rule.", + "ConnectionMonitorResultProperties": { "properties": { - "ruleName": { + "provisioningState": { + "$ref": "./network.json#/definitions/ProvisioningState", + "description": "The provisioning state of the connection monitor." + }, + "startTime": { "type": "string", - "description": "Name of the matched network security rule." + "format": "date-time", + "description": "The date and time when the connection monitor was started." }, - "action": { + "monitoringStatus": { "type": "string", - "description": "The network traffic is allowed or denied. Possible values are 'Allow' and 'Deny'." + "description": "The monitoring status of the connection monitor." } - } + }, + "allOf": [ + { + "$ref": "#/definitions/ConnectionMonitorParameters" + } + ], + "description": "Describes the properties of a connection monitor." }, - "NetworkSecurityRulesEvaluationResult": { - "description": "Network security rules evaluation result.", + "ConnectionMonitorQueryResult": { "properties": { - "name": { + "sourceStatus": { "type": "string", - "description": "Name of the network security rule." - }, - "protocolMatched": { - "type": "boolean", - "description": "Value indicating whether protocol is matched." - }, - "sourceMatched": { - "type": "boolean", - "description": "Value indicating whether source is matched." - }, - "sourcePortMatched": { - "type": "boolean", - "description": "Value indicating whether source port is matched." - }, - "destinationMatched": { - "type": "boolean", - "description": "Value indicating whether destination is matched." + "enum": [ + "Unknown", + "Active", + "Inactive" + ], + "x-ms-enum": { + "name": "ConnectionMonitorSourceStatus", + "modelAsString": true + }, + "description": "Status of connection monitor source." }, - "destinationPortMatched": { - "type": "boolean", - "description": "Value indicating whether destination port is matched." + "states": { + "type": "array", + "items": { + "$ref": "#/definitions/ConnectionStateSnapshot" + }, + "description": "Information about connection states." } - } - }, - "Direction": { - "type": "string", - "description": "The direction of the traffic.", - "enum": [ - "Inbound", - "Outbound" - ], - "x-ms-enum": { - "name": "Direction", - "modelAsString": true - } + }, + "description": "List of connection states snapshots." } } } From 7f8f58697b18a2cc49f087d228d25fdbab9da130 Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Tue, 3 Dec 2019 11:27:04 -0800 Subject: [PATCH 02/11] Added tests for connection monitor --- ...NetworkWatcherConnectionMonitorCreate.json | 70 +++++++++++++++++ ...NetworkWatcherConnectionMonitorDelete.json | 13 ++++ .../NetworkWatcherConnectionMonitorGet.json | 35 +++++++++ .../NetworkWatcherConnectionMonitorList.json | 60 +++++++++++++++ .../NetworkWatcherConnectionMonitorQuery.json | 77 +++++++++++++++++++ .../NetworkWatcherConnectionMonitorStart.json | 13 ++++ .../NetworkWatcherConnectionMonitorStop.json | 13 ++++ 7 files changed, 281 insertions(+) create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorCreate.json create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorDelete.json create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorGet.json create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorList.json create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorQuery.json create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStart.json create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStop.json diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorCreate.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorCreate.json new file mode 100644 index 000000000000..20bdc6f28c8b --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorCreate.json @@ -0,0 +1,70 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1", + "location": "centraluseuap", + "parameters": { + "properties": { + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1" + }, + "destination": { + "address": "bing.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 60 + } + } + }, + "responses": { + "200": { + "body": { + "name": "cm1", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"e7497f26-5f09-4559-900b-fe98f3dedb6f\"", + "properties": { + "provisioningState": "Updating", + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1", + "port": 0 + }, + "destination": { + "address": "bing.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 60, + "autoStart": true, + "monitoringStatus": "NotStarted" + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + } + }, + "201": { + "body": { + "name": "cm1", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"e7497f26-5f09-4559-900b-fe98f3dedb6f\"", + "properties": { + "provisioningState": "Updating", + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1", + "port": 0 + }, + "destination": { + "address": "bing.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 60, + "autoStart": true, + "monitoringStatus": "NotStarted" + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + } + } + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorDelete.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorDelete.json new file mode 100644 index 000000000000..5c687b34f04a --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorDelete.json @@ -0,0 +1,13 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1" + }, + "responses": { + "204": {}, + "202": {} + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorGet.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorGet.json new file mode 100644 index 000000000000..e1c884b33d58 --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorGet.json @@ -0,0 +1,35 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1" + }, + "responses": { + "200": { + "body": { + "name": "cm1", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"00000000-0000-0000-0000-000000000000\"", + "properties": { + "provisioningState": "Succeeded", + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1", + "port": 0 + }, + "destination": { + "address": "bing.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 60, + "autoStart": true, + "startTime": "2018-01-08T03:42:33.3387305Z", + "monitoringStatus": "Running" + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + } + } + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorList.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorList.json new file mode 100644 index 000000000000..677bf495d6b8 --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorList.json @@ -0,0 +1,60 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "name": "cm1", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"00000000-0000-0000-0000-000000000000\"", + "properties": { + "provisioningState": "Succeeded", + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1", + "port": 0 + }, + "destination": { + "address": "bing.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 60, + "autoStart": true, + "startTime": "2018-01-08T03:42:33.3387305Z", + "monitoringStatus": "Running" + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + }, + { + "name": "cm2", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm2", + "etag": "W/\"00000000-0000-0000-0000-000000000000\"", + "properties": { + "provisioningState": "Succeeded", + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm2", + "port": 0 + }, + "destination": { + "address": "google.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 30, + "autoStart": true, + "startTime": "2018-01-08T05:42:33.3387305Z", + "monitoringStatus": "Running" + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + } + ] + } + } + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorQuery.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorQuery.json new file mode 100644 index 000000000000..dcfeefdee1d3 --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorQuery.json @@ -0,0 +1,77 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1" + }, + "responses": { + "200": { + "body": { + "sourceStatus": "Active", + "states": [ + { + "connectionState": "Reachable", + "startTime": "2018-01-08T03:42:33.3387305Z", + "endTime": "2018-01-08T05:12:41.5265438Z", + "evaluationState": "Completed", + "hops": [ + { + "type": "Source", + "id": "7dbbe7aa-60ba-4650-831e-63d775d38e9e", + "address": "10.1.1.4", + "resourceId": "subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/nic0/ipConfigurations/ipconfig1", + "nextHopIds": [ + "75c8d819-b208-4584-a311-1aa45ce753f9" + ], + "issues": [] + }, + { + "type": "VirtualNetwork", + "id": "75c8d819-b208-4584-a311-1aa45ce753f9", + "address": "192.168.100.4", + "resourceId": "subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/nic1/ipConfigurations/ipconfig1", + "nextHopIds": [], + "issues": [] + } + ] + } + ] + } + }, + "202": { + "body": { + "sourceStatus": "Active", + "states": [ + { + "connectionState": "Reachable", + "startTime": "2018-01-08T03:42:33.3387305Z", + "endTime": "2018-01-08T05:12:41.5265438Z", + "evaluationState": "Completed", + "hops": [ + { + "type": "Source", + "id": "7dbbe7aa-60ba-4650-831e-63d775d38e9e", + "address": "10.1.1.4", + "resourceId": "subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/nic0/ipConfigurations/ipconfig1", + "nextHopIds": [ + "75c8d819-b208-4584-a311-1aa45ce753f9" + ], + "issues": [] + }, + { + "type": "VirtualNetwork", + "id": "75c8d819-b208-4584-a311-1aa45ce753f9", + "address": "192.168.100.4", + "resourceId": "subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/nic1/ipConfigurations/ipconfig1", + "nextHopIds": [], + "issues": [] + } + ] + } + ] + } + } + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStart.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStart.json new file mode 100644 index 000000000000..0453be3a1dff --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStart.json @@ -0,0 +1,13 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1" + }, + "responses": { + "200": {}, + "202": {} + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStop.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStop.json new file mode 100644 index 000000000000..0453be3a1dff --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorStop.json @@ -0,0 +1,13 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1" + }, + "responses": { + "200": {}, + "202": {} + } +} From b42c1c78c92361b7c22a61bd5fbaa638bd59d4ef Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Tue, 3 Dec 2019 13:06:53 -0800 Subject: [PATCH 03/11] Added NetworkWatcherConnectionMonitorUpdateTags test --- ...orkWatcherConnectionMonitorUpdateTags.json | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorUpdateTags.json diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorUpdateTags.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorUpdateTags.json new file mode 100644 index 000000000000..a129fa2f28f0 --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorUpdateTags.json @@ -0,0 +1,45 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1", + "parameters": { + "tags": { + "tag1": "value1", + "tag2": "value2" + } + } + }, + "responses": { + "200": { + "body": { + "name": "cm1", + "id": "/subscriptions/subid/`/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"00000000-0000-0000-0000-000000000000\"", + "properties": { + "provisioningState": "Succeeded", + "source": { + "resourceId": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1", + "port": 0 + }, + "destination": { + "address": "bing.com", + "port": 80 + }, + "monitoringIntervalInSeconds": 60, + "autoStart": true, + "startTime": "2019-09-04T02:48:10.6797393Z", + "monitoringStatus": "Running" + }, + "tags": { + "tag1": "value1", + "tag2": "value2" + }, + "type": "Microsoft.Network/networkWatchers/connectionMonitors", + "location": "westcentralus" + } + } + } +} From a2ba7b44b503a9d207ae1ba01c89fcf9f3951f46 Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Tue, 3 Dec 2019 13:40:07 -0800 Subject: [PATCH 04/11] Removed reference on connectionMOnitorV1 in readme.md --- specification/network/resource-manager/readme.md | 1 - 1 file changed, 1 deletion(-) diff --git a/specification/network/resource-manager/readme.md b/specification/network/resource-manager/readme.md index ce485a1738b8..8f37f1dcaf84 100644 --- a/specification/network/resource-manager/readme.md +++ b/specification/network/resource-manager/readme.md @@ -62,7 +62,6 @@ input-file: - Microsoft.Network/stable/2019-11-01/networkProfile.json - Microsoft.Network/stable/2019-11-01/networkSecurityGroup.json - Microsoft.Network/stable/2019-11-01/networkWatcher.json - - Microsoft.Network/stable/2019-06-01/networkWatcherConnectionMonitorV1.json - Microsoft.Network/stable/2019-11-01/operation.json - Microsoft.Network/stable/2019-11-01/privateEndpoint.json - Microsoft.Network/stable/2019-11-01/privateLinkService.json From 4862ab42b1200d797949f2dac3082dc92baee5bd Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Tue, 3 Dec 2019 14:51:33 -0800 Subject: [PATCH 05/11] Suppressed DefinitionsPropertiesNamesCamelCase error --- specification/network/resource-manager/readme.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/specification/network/resource-manager/readme.md b/specification/network/resource-manager/readme.md index 8f37f1dcaf84..0aab0a147ccb 100644 --- a/specification/network/resource-manager/readme.md +++ b/specification/network/resource-manager/readme.md @@ -1376,6 +1376,10 @@ directive: from: networkwatcher.json where: $.definitions.ProtocolConfiguration.properties.HTTPConfiguration reason: Accidentally shipped with wrong casing - however fixing the casing is introducing a breaking change which is worse than living with the naming violation + - suppress: DefinitionsPropertiesNamesCamelCase + from: networkwatcher.json + where: $.definitions.ConnectionMonitorHttpConfiguration.properties.preferHTTPS + reason: Accidentally shipped with wrong casing - however fixing the casing is introducing a breaking change which is worse than living with the naming violation ``` ## Go From 205e36cc202252cd4ae271f411a1db04db11a906 Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Wed, 4 Dec 2019 11:31:42 -0800 Subject: [PATCH 06/11] Fixed warnings and added example cor connectionMonitorV2 creation --- custom-words.txt | 1 + ...tworkWatcherConnectionMonitorV2Create.json | 206 ++++++++++++++++++ .../stable/2019-11-01/networkWatcher.json | 16 +- 3 files changed, 217 insertions(+), 6 deletions(-) create mode 100644 specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json diff --git a/custom-words.txt b/custom-words.txt index ed5773976128..c749c29e461a 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -1459,6 +1459,7 @@ tombstoned toolchain toolset tooltips +traceroute trafficmanager trafficmanageranalytics trafficmanagerprofiles diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json new file mode 100644 index 000000000000..18d01e50f4bf --- /dev/null +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json @@ -0,0 +1,206 @@ +{ + "parameters": { + "api-version": "2019-11-01", + "subscriptionId": "subid", + "resourceGroupName": "rg1", + "networkWatcherName": "nw1", + "connectionMonitorName": "cm1", + "location": "centraluseuap", + "parameters": { + "properties": { + "endpoints": [ + { + "name": "vm1", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" + }, + { + "name": "CanaryWorkspaceVamshi", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", + "filter": { + "type": "Include", + "items": [ + { + "type": "AgentAddress", + "address": "npmuser" + } + ] + } + }, + { + "name": "bing", + "address": "bing.com" + }, + { + "name": "google", + "address": "google.com" + } + ], + "testConfigurations": [ + { + "name": "testConfig1", + "testFrequencySec": 60, + "protocol": "Tcp", + "tcpConfiguration": { + "port": 80, + "disableTraceRoute": false + } + } + ], + "testGroups": [ + { + "name": "test1", + "disable": false, + "testConfigurations": [ + "testConfig1" + ], + "sources": [ + "vm1", + "CanaryWorkspaceVamshi" + ], + "destinations": [ + "bing", + "google" + ] + } + ], + "outputs": [] + } + } + }, + "responses": { + "200": { + "body": { + "name": "cm1", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"e7497f26-5f09-4559-900b-fe98f3dedb6f\"", + "properties": { + "endpoints": [ + { + "name": "vm1", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" + }, + { + "name": "CanaryWorkspaceVamshi", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", + "filter": { + "type": "Include", + "items": [ + { + "type": "AgentAddress", + "address": "npmuser" + } + ] + } + }, + { + "name": "bing", + "address": "bing.com" + }, + { + "name": "google", + "address": "google.com" + } + ], + "testConfigurations": [ + { + "name": "testConfig1", + "testFrequencySec": 60, + "protocol": "Tcp", + "tcpConfiguration": { + "port": 80, + "disableTraceRoute": false + } + } + ], + "testGroups": [ + { + "name": "test1", + "disable": false, + "testConfigurations": [ + "testConfig1" + ], + "sources": [ + "vm1", + "CanaryWorkspaceVamshi" + ], + "destinations": [ + "bing", + "google" + ] + } + ], + "outputs": [] + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + } + }, + "201": { + "body": { + "name": "cm1", + "id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkWatchers/nw1/connectionMonitors/cm1", + "etag": "W/\"e7497f26-5f09-4559-900b-fe98f3dedb6f\"", + "properties": { + "endpoints": [ + { + "name": "vm1", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" + }, + { + "name": "CanaryWorkspaceVamshi", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", + "filter": { + "type": "Include", + "items": [ + { + "type": "AgentAddress", + "address": "npmuser" + } + ] + } + }, + { + "name": "bing", + "address": "bing.com" + }, + { + "name": "google", + "address": "google.com" + } + ], + "testConfigurations": [ + { + "name": "testConfig1", + "testFrequencySec": 60, + "protocol": "Tcp", + "tcpConfiguration": { + "port": 80, + "disableTraceRoute": false + } + } + ], + "testGroups": [ + { + "name": "test1", + "disable": false, + "testConfigurations": [ + "testConfig1" + ], + "sources": [ + "vm1", + "CanaryWorkspaceVamshi" + ], + "destinations": [ + "bing", + "google" + ] + } + ], + "outputs": [] + }, + "location": "centraluseuap", + "type": "Microsoft.Network/networkWatchers/connectionMonitors" + } + } + } +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json index 48e48d39d5be..900eaddaf738 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json @@ -1592,8 +1592,11 @@ } }, "x-ms-examples": { - "Create connection monitor": { + "Create connection monitor V1": { "$ref": "./examples/NetworkWatcherConnectionMonitorCreate.json" + }, + "Create connection monitor V2": { + "$ref": "./examples/NetworkWatcherConnectionMonitorV2Create.json" } }, "x-ms-long-running-operation": true, @@ -3835,7 +3838,7 @@ }, "path": { "type": "string", - "description": "The path component of the URI. For instance, \"/dir1/dir2\"" + "description": "The path component of the URI. For instance, \"/dir1/dir2\"." }, "requestHeaders": { "type": "array", @@ -3849,7 +3852,7 @@ "items": { "type": "string" }, - "description": "HTTP status codes to consider successful. For instance, \"2xx,301-304,418\"" + "description": "HTTP status codes to consider successful. For instance, \"2xx,301-304,418\"." }, "preferHTTPS": { "type": "boolean", @@ -3866,7 +3869,7 @@ }, "disableTraceRoute": { "type": "boolean", - "description": "Value indicating whether path evaluation with traceroute should be disabled." + "description": "Value indicating whether path evaluation with trace route should be disabled." } }, "description": "Describes the TCP configuration." @@ -3875,7 +3878,7 @@ "properties": { "disableTraceRoute": { "type": "boolean", - "description": "Value indicating whether path evaluation with traceroute should be disabled." + "description": "Value indicating whether path evaluation with trace route should be disabled." } }, "description": "Describes the ICMP configuration." @@ -4017,8 +4020,8 @@ "description": "ID of the connection monitor." }, "etag": { + "readOnly": true, "type": "string", - "default": "A unique read-only string that changes whenever the resource is updated.", "description": "A unique read-only string that changes whenever the resource is updated." }, "type": { @@ -4048,6 +4051,7 @@ "ConnectionMonitorResultProperties": { "properties": { "provisioningState": { + "readOnly": true, "$ref": "./network.json#/definitions/ProvisioningState", "description": "The provisioning state of the connection monitor." }, From 517642c613df6654fdc851b6152290938e0f5767 Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Wed, 4 Dec 2019 14:02:27 -0800 Subject: [PATCH 07/11] Fixed formatting in NetworkWatcherConnectionMonitorV2Create test --- ...tworkWatcherConnectionMonitorV2Create.json | 240 +++++++++--------- 1 file changed, 120 insertions(+), 120 deletions(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json index 18d01e50f4bf..333915f92617 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json @@ -10,60 +10,60 @@ "properties": { "endpoints": [ { - "name": "vm1", - "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" + "name": "vm1", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" }, { - "name": "CanaryWorkspaceVamshi", - "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", - "filter": { - "type": "Include", - "items": [ - { - "type": "AgentAddress", - "address": "npmuser" - } - ] - } + "name": "CanaryWorkspaceVamshi", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", + "filter": { + "type": "Include", + "items": [ + { + "type": "AgentAddress", + "address": "npmuser" + } + ] + } }, { - "name": "bing", - "address": "bing.com" + "name": "bing", + "address": "bing.com" }, { - "name": "google", - "address": "google.com" + "name": "google", + "address": "google.com" } ], "testConfigurations": [ { - "name": "testConfig1", - "testFrequencySec": 60, - "protocol": "Tcp", - "tcpConfiguration": { - "port": 80, - "disableTraceRoute": false - } + "name": "testConfig1", + "testFrequencySec": 60, + "protocol": "Tcp", + "tcpConfiguration": { + "port": 80, + "disableTraceRoute": false + } } ], - "testGroups": [ + "testGroups": [ { - "name": "test1", - "disable": false, - "testConfigurations": [ - "testConfig1" - ], - "sources": [ - "vm1", - "CanaryWorkspaceVamshi" - ], - "destinations": [ - "bing", - "google" - ] + "name": "test1", + "disable": false, + "testConfigurations": [ + "testConfig1" + ], + "sources": [ + "vm1", + "CanaryWorkspaceVamshi" + ], + "destinations": [ + "bing", + "google" + ] } ], - "outputs": [] + "outputs": [ ] } } }, @@ -76,61 +76,61 @@ "properties": { "endpoints": [ { - "name": "vm1", - "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" + "name": "vm1", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" }, { - "name": "CanaryWorkspaceVamshi", - "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", - "filter": { - "type": "Include", - "items": [ - { - "type": "AgentAddress", - "address": "npmuser" - } - ] - } + "name": "CanaryWorkspaceVamshi", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", + "filter": { + "type": "Include", + "items": [ + { + "type": "AgentAddress", + "address": "npmuser" + } + ] + } }, { - "name": "bing", - "address": "bing.com" + "name": "bing", + "address": "bing.com" }, { - "name": "google", - "address": "google.com" + "name": "google", + "address": "google.com" } ], "testConfigurations": [ { - "name": "testConfig1", - "testFrequencySec": 60, - "protocol": "Tcp", - "tcpConfiguration": { - "port": 80, - "disableTraceRoute": false - } + "name": "testConfig1", + "testFrequencySec": 60, + "protocol": "Tcp", + "tcpConfiguration": { + "port": 80, + "disableTraceRoute": false + } } ], - "testGroups": [ + "testGroups": [ { - "name": "test1", - "disable": false, - "testConfigurations": [ - "testConfig1" - ], - "sources": [ - "vm1", - "CanaryWorkspaceVamshi" - ], - "destinations": [ - "bing", - "google" - ] + "name": "test1", + "disable": false, + "testConfigurations": [ + "testConfig1" + ], + "sources": [ + "vm1", + "CanaryWorkspaceVamshi" + ], + "destinations": [ + "bing", + "google" + ] } ], - "outputs": [] - }, + "outputs": [ ] + }, "location": "centraluseuap", "type": "Microsoft.Network/networkWatchers/connectionMonitors" } @@ -143,64 +143,64 @@ "properties": { "endpoints": [ { - "name": "vm1", - "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" + "name": "vm1", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/NwRgIrinaCentralUSEUAP/providers/Microsoft.Compute/virtualMachines/vm1" }, { - "name": "CanaryWorkspaceVamshi", - "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", - "filter": { - "type": "Include", - "items": [ - { - "type": "AgentAddress", - "address": "npmuser" - } - ] - } + "name": "CanaryWorkspaceVamshi", + "resourceId": "/subscriptions/96e68903-0a56-4819-9987-8d08ad6a1f99/resourceGroups/vasamudrRG/providers/Microsoft.OperationalInsights/workspaces/vasamudrWorkspace", + "filter": { + "type": "Include", + "items": [ + { + "type": "AgentAddress", + "address": "npmuser" + } + ] + } }, { - "name": "bing", - "address": "bing.com" + "name": "bing", + "address": "bing.com" }, { - "name": "google", - "address": "google.com" + "name": "google", + "address": "google.com" } ], "testConfigurations": [ { - "name": "testConfig1", - "testFrequencySec": 60, - "protocol": "Tcp", - "tcpConfiguration": { - "port": 80, - "disableTraceRoute": false - } + "name": "testConfig1", + "testFrequencySec": 60, + "protocol": "Tcp", + "tcpConfiguration": { + "port": 80, + "disableTraceRoute": false + } } ], - "testGroups": [ + "testGroups": [ { - "name": "test1", - "disable": false, - "testConfigurations": [ - "testConfig1" - ], - "sources": [ - "vm1", - "CanaryWorkspaceVamshi" - ], - "destinations": [ - "bing", - "google" - ] + "name": "test1", + "disable": false, + "testConfigurations": [ + "testConfig1" + ], + "sources": [ + "vm1", + "CanaryWorkspaceVamshi" + ], + "destinations": [ + "bing", + "google" + ] } ], - "outputs": [] - }, + "outputs": [ ] + }, "location": "centraluseuap", "type": "Microsoft.Network/networkWatchers/connectionMonitors" } } } -} +} \ No newline at end of file From b9cf4f536f1ba5cd1020c5cd56641393f551c6cd Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Sun, 15 Dec 2019 10:36:28 -0800 Subject: [PATCH 08/11] Added connectionMonitorType property to connectionMonitorResult --- .../stable/2019-11-01/networkWatcher.json | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json index 900eaddaf738..589b6c5e8b1c 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json @@ -4063,6 +4063,19 @@ "monitoringStatus": { "type": "string", "description": "The monitoring status of the connection monitor." + }, + "connectionMonitorType": { + "readOnly": true, + "type": "string", + "enum": [ + "MultiEndpoint", + "SingleSourceDestination" + ], + "x-ms-enum": { + "name": "ConnectionMonitorType", + "modelAsString": true + }, + "description": "Type of connection monitor." } }, "allOf": [ @@ -4098,4 +4111,4 @@ "description": "List of connection states snapshots." } } -} +} \ No newline at end of file From d6fdfd9d89dc452766f8280e8a333b304db4d7f3 Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Wed, 18 Dec 2019 14:25:10 -0800 Subject: [PATCH 09/11] Fixed networkWatcher swagger based on CR. Run prettier check --- ...tworkWatcherConnectionMonitorV2Create.json | 8 ++-- .../stable/2019-11-01/networkWatcher.json | 44 +++++++------------ 2 files changed, 21 insertions(+), 31 deletions(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json index 333915f92617..6965a0a1b871 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/examples/NetworkWatcherConnectionMonitorV2Create.json @@ -63,7 +63,7 @@ ] } ], - "outputs": [ ] + "outputs": [] } } }, @@ -129,7 +129,7 @@ ] } ], - "outputs": [ ] + "outputs": [] }, "location": "centraluseuap", "type": "Microsoft.Network/networkWatchers/connectionMonitors" @@ -196,11 +196,11 @@ ] } ], - "outputs": [ ] + "outputs": [] }, "location": "centraluseuap", "type": "Microsoft.Network/networkWatchers/connectionMonitors" } } } -} \ No newline at end of file +} diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json index 589b6c5e8b1c..572a55aef210 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json @@ -3685,6 +3685,9 @@ "description": "Filter for sub-items within the endpoint." } }, + "required": [ + "name" + ], "description": "Describes the connection monitor endpoint." }, "ConnectionMonitorEndpointFilter": { @@ -3762,6 +3765,12 @@ "description": "List of destination endpoint names." } }, + "required": [ + "name", + "testConfigurations", + "sources", + "destinations" + ], "description": "Describes the connection monitor test group." }, "ConnectionMonitorTestConfiguration": { @@ -4009,43 +4018,22 @@ "ConnectionMonitorResult": { "x-ms-azure-resource": true, "properties": { - "name": { - "readOnly": true, - "type": "string", - "description": "Name of the connection monitor." - }, - "id": { - "readOnly": true, - "type": "string", - "description": "ID of the connection monitor." - }, "etag": { "readOnly": true, "type": "string", "description": "A unique read-only string that changes whenever the resource is updated." }, - "type": { - "readOnly": true, - "type": "string", - "description": "Connection monitor type." - }, - "location": { - "type": "string", - "description": "Connection monitor location." - }, - "tags": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Connection monitor tags." - }, "properties": { "x-ms-client-flatten": true, "$ref": "#/definitions/ConnectionMonitorResultProperties", "description": "Properties of the connection monitor result." } }, + "allOf": [ + { + "$ref": "./network.json#/definitions/Resource" + } + ], "description": "Information about the connection monitor." }, "ConnectionMonitorResultProperties": { @@ -4056,11 +4044,13 @@ "description": "The provisioning state of the connection monitor." }, "startTime": { + "readOnly": true, "type": "string", "format": "date-time", "description": "The date and time when the connection monitor was started." }, "monitoringStatus": { + "readOnly": true, "type": "string", "description": "The monitoring status of the connection monitor." }, @@ -4111,4 +4101,4 @@ "description": "List of connection states snapshots." } } -} \ No newline at end of file +} From 1b6eb12686c7a672c47dca34c0407f312aacdc53 Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Thu, 19 Dec 2019 14:23:42 -0800 Subject: [PATCH 10/11] Minor changes --- .../stable/2019-11-01/networkWatcher.json | 37 ++++++++++++++++--- 1 file changed, 31 insertions(+), 6 deletions(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json index 572a55aef210..4009965a8a20 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json @@ -3825,6 +3825,10 @@ "description": "The threshold for declaring a test successful." } }, + "required": [ + "name", + "protocol" + ], "description": "Describes a connection monitor test configuration." }, "ConnectionMonitorHttpConfiguration": { @@ -4018,22 +4022,43 @@ "ConnectionMonitorResult": { "x-ms-azure-resource": true, "properties": { + "name": { + "readOnly": true, + "type": "string", + "description": "Name of the connection monitor." + }, + "id": { + "readOnly": true, + "type": "string", + "description": "ID of the connection monitor." + }, "etag": { "readOnly": true, "type": "string", "description": "A unique read-only string that changes whenever the resource is updated." }, + "type": { + "readOnly": true, + "type": "string", + "description": "Connection monitor type." + }, + "location": { + "type": "string", + "description": "Connection monitor location." + }, + "tags": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "Connection monitor tags." + }, "properties": { "x-ms-client-flatten": true, "$ref": "#/definitions/ConnectionMonitorResultProperties", "description": "Properties of the connection monitor result." } }, - "allOf": [ - { - "$ref": "./network.json#/definitions/Resource" - } - ], "description": "Information about the connection monitor." }, "ConnectionMonitorResultProperties": { @@ -4101,4 +4126,4 @@ "description": "List of connection states snapshots." } } -} +} \ No newline at end of file From d189f73b06019def49b5718103c1d57e6ed0078a Mon Sep 17 00:00:00 2001 From: Irina Rogozhkina Date: Thu, 19 Dec 2019 14:47:36 -0800 Subject: [PATCH 11/11] Run prettier check for networkWatcher --- .../Microsoft.Network/stable/2019-11-01/networkWatcher.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json index 4009965a8a20..26e4b80f1336 100644 --- a/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json +++ b/specification/network/resource-manager/Microsoft.Network/stable/2019-11-01/networkWatcher.json @@ -4126,4 +4126,4 @@ "description": "List of connection states snapshots." } } -} \ No newline at end of file +}