This repository was archived by the owner on Sep 4, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 349
Merged
Changes from 17 commits
Commits
Show all changes
32 commits
Select commit
Hold shift + click to select a range
c7b0df6
Using ARG query to list & get Sql data
ArthurMa1978 a6f267e
update
ArthurMa1978 6348e68
update
ArthurMa1978 762f37d
update doc
ArthurMa1978 d856d23
update
ArthurMa1978 d57e70d
update
ArthurMa1978 9e1d572
update
ArthurMa1978 5aa0562
update
ArthurMa1978 eca7dd4
update
ArthurMa1978 f6856c6
Merge branch 'main' into mgmt-sql
ArthurMa1978 57dd806
update
ArthurMa1978 a39d6bc
update
ArthurMa1978 e4e324a
update
ArthurMa1978 c6b4574
Merge branch 'main' into mgmt-sql
ArthurMa1978 fe8ed38
update
ArthurMa1978 e588fad
revert vscode/README.md
ArthurMa1978 228ffc0
udpate
ArthurMa1978 a7c3c06
update
ArthurMa1978 b7d3879
Merge branch 'main' into mgmt-sql
ArthurMa1978 0661eac
Merge branch 'main' into mgmt-sql
ArthurMa1978 e391dab
update changelog
ArthurMa1978 84acd0b
update changelog
ArthurMa1978 54986bf
update checklist
ArthurMa1978 04b5116
Update the identify unused properteis check
ArthurMa1978 caecb2e
update
ArthurMa1978 631c25e
fix typo
ArthurMa1978 7f1cc08
Merge branch 'main' into mgmt-sql
ArthurMa1978 9a5418e
Merge branch 'main' into mgmt-sql
ArthurMa1978 3bdb737
Merge branch 'main' into mgmt-sql
ArthurMa1978 4bd863c
Merge branch 'main' into mgmt-sql
ArthurMa1978 67818a9
Merge branch 'main' into mgmt-sql
ArthurMa1978 c985dbe
update changelog
ArthurMa1978 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
areas/sql/src/AzureMcp.Sql/Services/Models/DatabaseIdentity.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| // Copyright (c) Microsoft Corporation. All rights reserved. | ||
| // Licensed under the MIT License. | ||
|
|
||
| using System.Text.Json.Serialization; | ||
|
|
||
| namespace AzureMcp.Sql.Services.Models | ||
| { | ||
| /// <summary> Azure Active Directory identity configuration for a resource. </summary> | ||
| internal sealed class DatabaseIdentity | ||
| { | ||
| /// <summary> The identity type. </summary> | ||
| [JsonPropertyName("type")] | ||
| public string? IdentityType { get; set; } | ||
| /// <summary> The Azure Active Directory tenant id. </summary> | ||
| public Guid? TenantId { get; set; } | ||
| /// <summary> The resource ids of the user assigned identities to use. </summary> | ||
| public IDictionary<string, SqlUserAssignedIdentity>? UserAssignedIdentities { get; set; } | ||
| } | ||
| } |
46 changes: 46 additions & 0 deletions
46
areas/sql/src/AzureMcp.Sql/Services/Models/SqlDatabaseData.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| // Copyright (c) Microsoft Corporation. All rights reserved. | ||
| // Licensed under the MIT License. | ||
|
|
||
| using System.Text.Json; | ||
| using System.Text.Json.Serialization; | ||
| using AzureMcp.Sql.Commands; | ||
|
|
||
| namespace AzureMcp.Sql.Services.Models | ||
| { | ||
| /// <summary> | ||
| /// A class representing the SqlDatabase data model. | ||
| /// A database resource. | ||
| /// </summary> | ||
| internal sealed class SqlDatabaseData | ||
| { | ||
| /// <summary> The resource ID for the resource. </summary> | ||
| [JsonPropertyName("id")] | ||
| public string? ResourceId { get; set; } | ||
| /// <summary> The type of the resource. </summary> | ||
| [JsonPropertyName("type")] | ||
| public string? ResourceType { get; set; } | ||
| /// <summary> The name of the resource. </summary> | ||
| [JsonPropertyName("name")] | ||
| public string? ResourceName { get; set; } | ||
| /// <summary> The location of the resource. </summary> | ||
| public string? Location { get; set; } | ||
| /// <summary> The database SKU. </summary> | ||
| public SqlSku? Sku { get; set; } | ||
| /// <summary> Kind of database. This is metadata used for the Azure portal experience. </summary> | ||
| public string? Kind { get; set; } | ||
| /// <summary> Resource that manages the database. </summary> | ||
| public string? ManagedBy { get; set; } | ||
| /// <summary> The Azure Active Directory identity of the database. </summary> | ||
| public DatabaseIdentity? Identity { get; set; } | ||
| /// <summary> The tags of the resource. </summary> | ||
| public IDictionary<string, string>? Tags { get; set; } | ||
| /// <summary> Properties of the Sql database. </summary> | ||
| public SqlDatabaseProperties? Properties { get; set; } | ||
|
|
||
| // Read the JSON response content and create a model instance from it. | ||
| public static SqlDatabaseData? FromJson(JsonElement source) | ||
| { | ||
| return JsonSerializer.Deserialize<SqlDatabaseData>(source, SqlJsonContext.Default.SqlDatabaseData); | ||
| } | ||
| } | ||
| } |
24 changes: 24 additions & 0 deletions
24
areas/sql/src/AzureMcp.Sql/Services/Models/SqlDatabaseKey.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| // Copyright (c) Microsoft Corporation. All rights reserved. | ||
| // Licensed under the MIT License. | ||
|
|
||
| using System.Text.Json.Serialization; | ||
|
|
||
| namespace AzureMcp.Sql.Services.Models | ||
| { | ||
| /// <summary> Database level key used for encryption at rest. </summary> | ||
| internal sealed class SqlDatabaseKey | ||
| { | ||
| /// <summary> The database key type. Only supported value is 'AzureKeyVault'. </summary> | ||
| [JsonPropertyName("type")] | ||
| public string? KeyType { get; set; } | ||
| /// <summary> Thumbprint of the database key. </summary> | ||
| public string? Thumbprint { get; set; } | ||
| /// <summary> The database key creation date. </summary> | ||
| [JsonPropertyName("creationDate")] | ||
| public DateTimeOffset? CreatedOn { get; set; } | ||
| /// <summary> Subregion of the server key. </summary> | ||
| public string? Subregion { get; set; } | ||
| /// <summary> The database key's version. </summary> | ||
| public string? KeyVersion { get; set; } | ||
| } | ||
| } |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.