Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release databasewatcher microsoft.database watcher 2024 07 19 preview #29971

Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
fbdda13
Update watcher.tsp
Shubham-9999-bot Jul 25, 2024
b5c562f
First cut
Shubham-9999-bot Jul 25, 2024
00d1907
Merge branch 'main' into release-databasewatcher-Microsoft.DatabaseWa…
Shubham-9999-bot Jul 25, 2024
8a52923
Fixes
Shubham-9999-bot Jul 25, 2024
88c9d89
Fixes
Shubham-9999-bot Jul 25, 2024
eac218d
New property
Shubham-9999-bot Jul 25, 2024
e1ae1e3
Identity
Shubham-9999-bot Jul 25, 2024
414c0b2
Add examples
Shubham-9999-bot Jul 25, 2024
034ba72
Max/min set
Shubham-9999-bot Jul 25, 2024
d46f694
Compile fix
Shubham-9999-bot Jul 25, 2024
631f6a9
Merge branch 'main' into release-databasewatcher-Microsoft.DatabaseWa…
Shubham-9999-bot Jul 25, 2024
4b4bd95
Merge branch 'main' into release-databasewatcher-Microsoft.DatabaseWa…
Shubham-9999-bot Jul 26, 2024
fd5fea0
Added v5 types
Shubham-9999-bot Jul 26, 2024
a5cfbb8
Revert
Shubham-9999-bot Jul 26, 2024
21307f2
Examples for rules
Shubham-9999-bot Jul 26, 2024
21b2bb2
Examples
Shubham-9999-bot Jul 26, 2024
554f962
Merge branch 'main' into release-databasewatcher-Microsoft.DatabaseWa…
Shubham-9999-bot Jul 28, 2024
ff226d1
Added api
Shubham-9999-bot Jul 28, 2024
65bf9b0
Added
Shubham-9999-bot Jul 29, 2024
20a4ab2
Comment
Shubham-9999-bot Jul 29, 2024
679b3f8
Enum
Shubham-9999-bot Jul 29, 2024
8df8b8e
Examples
Shubham-9999-bot Jul 29, 2024
b3c9e82
Nmae change
Shubham-9999-bot Jul 29, 2024
e6c86d7
Examples
Shubham-9999-bot Jul 29, 2024
68f6b9f
Examples
Shubham-9999-bot Jul 29, 2024
4bbb0c4
Added required
Shubham-9999-bot Jul 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
import "@typespec/rest";
import "@azure-tools/typespec-azure-core";
import "@azure-tools/typespec-azure-resource-manager";

namespace Microsoft.DatabaseWatcher;

using Azure.ResourceManager;
using TypeSpec.Versioning;
using TypeSpec.Http;
using TypeSpec.Rest;

@armResourceOperations
interface AlertRuleResources {
get is ArmResourceRead<AlertRuleResource>;
createOrUpdate is ArmResourceCreateOrReplaceSync<AlertRuleResource>;
delete is ArmResourceDeleteSync<AlertRuleResource>;
listByParent is ArmResourceListByParent<AlertRuleResource>;
}

@parentResource(Watcher)
model AlertRuleResource is ProxyResource<AlertRuleResourceProperties> {
@doc("The alert rule proxy resource name.")
@key("alertRuleResourceName")
@pattern("^[a-zA-Z0-9]{1}[a-zA-Z0-9-_.]{0,62}[a-zA-Z0-9_]{1}$")
@segment("alertRuleResources")
@path
name: string;
}

@doc("The generic properties of the alert rule proxy resource.")
model AlertRuleResourceProperties {
@doc("The resource ID of the alert rule resource.")
alertRuleResourceId: Azure.Core.armResourceIdentifier<[
{
type: "Microsoft.Insights/scheduledQueryRules";
}
]>;

@doc("Whether the alert rule was created with an action group.")
createdWithActionGroup: boolean;
Shubham-9999-bot marked this conversation as resolved.
Show resolved Hide resolved

@doc("The creation time of the alert rule resource.")
creationTime: utcDateTime;

@visibility("read")
@doc("The provisioning state of the alert rule resource.")
provisioningState?: ResourceProvisioningState;

@doc("The template ID associated with alert rule resource.")
alertRuleTemplateId: string;
Shubham-9999-bot marked this conversation as resolved.
Show resolved Hide resolved

@doc("The alert rule template version.")
alertRuleTemplateVersion: string;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
{
"title": "AlertRuleResources_CreateOrUpdate - generated by [MaximumSet] rule",
"operationId": "AlertRuleResources_CreateOrUpdate",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "rgWatcher",
"watcherName": "testWatcher",
"alertRuleResourceName": "testAlert",
"resource": {
"properties": {
"alertRuleResourceId": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.insights/scheduledqueryrules/alerts-demo",
"createdWithActionGroup": true,
"creationTime": "2024-07-25T15:38:47.798Z",
"alertRuleTemplateVersion": "1.0",
"alertRuleTemplateId": "someTemplateId"
}
}
},
"responses": {
"200": {
"body": {
"properties": {
"alertRuleResourceId": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.insights/scheduledqueryrules/alerts-demo",
"createdWithActionGroup": true,
"creationTime": "2024-07-25T15:38:47.798Z",
"alertRuleTemplateVersion": "1.0",
"provisioningState": "Succeeded",
"alertRuleTemplateId": "someTemplateId"
},
"id": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.databasewatcher/watchers/alertRuleResources/testAlert",
"name": "testAlert",
"type": "microsoft.databasewatcher/watchers/alertRuleResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
},
"201": {
"body": {
"properties": {
"alertRuleResourceId": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.insights/scheduledqueryrules/alerts-demo",
"createdWithActionGroup": true,
"creationTime": "2024-07-25T15:38:47.798Z",
"alertRuleTemplateVersion": "1.0",
"provisioningState": "Succeeded",
"alertRuleTemplateId": "someTemplateId"
},
"id": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.databasewatcher/watchers/alertRuleResources/testAlert",
"name": "testAlert",
"type": "microsoft.databasewatcher/watchers/alertRuleResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"title": "AlertRuleResources_Delete - generated by [MaximumSet] rule",
"operationId": "AlertRuleResources_Delete",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "rgWatcher",
"watcherName": "testWatcher",
"alertRuleResourceName": "testAlert"
},
"responses": {
"200": {},
"204": {}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"title": "AlertRuleResources_Get - generated by [MaximumSet] rule",
"operationId": "AlertRuleResources_Get",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "rgWatcher",
"watcherName": "testWatcher",
"alertRuleResourceName": "testAlert"
},
"responses": {
"200": {
"body": {
"properties": {
"alertRuleResourceId": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.insights/scheduledqueryrules/alerts-demo",
"createdWithActionGroup": true,
"creationTime": "2024-07-25T15:38:47.798Z",
"alertRuleTemplateVersion": "1.0",
"provisioningState": "Succeeded",
"alertRuleTemplateId": "someTemplateId"
},
"id": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.databasewatcher/watchers/alertRuleResources/testAlert",
"name": "testAlert",
"type": "microsoft.databasewatcher/watchers/alertRuleResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"title": "AlertRuleResources_ListByParent",
"operationId": "AlertRuleResources_ListByParent",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "rgWatcher",
"watcherName": "testWatcher"
},
"responses": {
"200": {
"body": {
"value": [
{
"properties": {
"alertRuleResourceId": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.insights/scheduledqueryrules/alerts-demo",
"createdWithActionGroup": true,
"creationTime": "2024-07-25T15:38:47.798Z",
"alertRuleTemplateVersion": "1.0",
"provisioningState": "Succeeded",
"alertRuleTemplateId": "someTemplateId"
},
"id": "/subscriptions/469DD77C-C8DB-47B7-B9E1-72D29F8C878Be/resourceGroups/rgWatcher/providers/microsoft.databasewatcher/watchers/alertRuleResources/testAlert",
"name": "testAlert",
"type": "microsoft.databasewatcher/watchers/alertRuleResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
],
"nextLink": "https://microsoft.com/a"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"title": "Operations_List - generated by [MaximumSet] rule",
"operationId": "Operations_List",
"parameters": {
"api-version": "2024-07-19-preview"
},
"responses": {
"200": {
"body": {
"value": [
{
"name": "snzrdvltunnrz",
"isDataAction": true,
"display": {
"provider": "dtfrqzamclscchmghtxn",
"resource": "lvlhnsfnquorjuuutjxex",
"operation": "vbgvamoxqwthpbdghxzaw",
"description": "nvbtuwwjfehylzmoatd"
},
"origin": "user",
"actionType": "Internal"
}
],
"nextLink": "sh"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"title": "Operations_List - generated by [MinimumSet] rule",
"operationId": "Operations_List",
"parameters": {
"api-version": "2024-07-19-preview"
},
"responses": {
"200": {
"body": {}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
{
"title": "SharedPrivateLinkResources_Create - generated by [MaximumSet] rule",
"operationId": "SharedPrivateLinkResources_Create",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "apiTest-ddat4p",
"watcherName": "databasemo3ej9ih",
"sharedPrivateLinkResourceName": "monitoringh22eed",
"resource": {
"properties": {
"privateLinkResourceId": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.KeyVault/vaults/kvmo3ej9ih",
"groupId": "vault",
"requestMessage": "request message",
"dnsZone": "ec3ae9d410ba",
"status": "Pending"
}
}
},
"responses": {
"200": {
"body": {
"properties": {
"privateLinkResourceId": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.KeyVault/vaults/kvmo3ej9ih",
"groupId": "vault",
"requestMessage": "request message",
"dnsZone": "ec3ae9d410ba",
"status": "Pending",
"provisioningState": "Completed"
},
"id": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.DatabaseWatcher/watchers/databasemo3ej9ih/sharedPrivateLinkResources/monitoringh22eed",
"name": "monitoringh22eed",
"type": "microsoft.databasewatcher/watchers/sharedPrivateLinkResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
},
"201": {
"headers": {
"Azure-AsyncOperation": "https://contoso.com/operationstatus"
},
"body": {
"properties": {
"privateLinkResourceId": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.KeyVault/vaults/kvmo3ej9ih",
"groupId": "vault",
"requestMessage": "request message",
"dnsZone": "ec3ae9d410ba",
"status": "Pending",
"provisioningState": "Completed"
},
"id": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.DatabaseWatcher/watchers/databasemo3ej9ih/sharedPrivateLinkResources/monitoringh22eed",
"name": "monitoringh22eed",
"type": "microsoft.databasewatcher/watchers/sharedPrivateLinkResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"title": "SharedPrivateLinkResources_Delete - generated by [MaximumSet] rule",
"operationId": "SharedPrivateLinkResources_Delete",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "apiTest-ddat4p",
"watcherName": "databasemo3ej9ih",
"sharedPrivateLinkResourceName": "monitoringh22eed"
},
"responses": {
"202": {
"headers": {
"location": "https://contoso.com/operationstatus"
}
},
"204": {}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"title": "SharedPrivateLinkResources_Get - generated by [MaximumSet] rule",
"operationId": "SharedPrivateLinkResources_Get",
"parameters": {
"api-version": "2024-07-19-preview",
"subscriptionId": "6f53185c-ea09-4fc3-9075-318dec805303",
"resourceGroupName": "apiTest-ddat4p",
"watcherName": "databasemo3ej9ih",
"sharedPrivateLinkResourceName": "monitoringh22eed"
},
"responses": {
"200": {
"body": {
"properties": {
"privateLinkResourceId": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.KeyVault/vaults/kvmo3ej9ih",
"groupId": "vault",
"requestMessage": "request message",
"dnsZone": "ec3ae9d410ba",
"status": "Pending",
"provisioningState": "Completed"
},
"id": "/subscriptions/6f53185c-ea09-4fc3-9075-318dec805303/resourceGroups/apiTest-ddat4p/providers/Microsoft.DatabaseWatcher/watchers/databasemo3ej9ih/sharedPrivateLinkResources/monitoringh22eed",
"name": "monitoringh22eed",
"type": "microsoft.databasewatcher/watchers/sharedPrivateLinkResources",
"systemData": {
"createdBy": "enbpvlpqbwd",
"createdByType": "User",
"createdAt": "2024-07-25T15:38:47.092Z",
"lastModifiedBy": "mxp",
"lastModifiedByType": "User",
"lastModifiedAt": "2024-07-25T15:38:47.092Z"
}
}
}
}
}
Loading
Loading