Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
@@ -1,4 +1,4 @@
{

Check notice on line 1 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/CommonDefinitions.json

View workflow job for this annotation

GitHub Actions / TypeSpec Requirement

Your service description will soon be required to convert from OpenAPI to TypeSpec. See https://aka.ms/azsdk/typespec.
"swagger": "2.0",
"info": {
"version": "2026-01-01",
Expand Down Expand Up @@ -1639,6 +1639,13 @@
"name": "DataConnectorProvisioningState",
"modelAsString": true
}
},
"extendedProperties": {
Copy link
Contributor

@gary-x-li gary-x-li Nov 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a collection of key value pairs without concrete schema. Also, it lacks enough description and examples. What are these key value pairs? Can you define proper schema for them?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gary-x-li, actually we need a property who is a Dictionary<string, object>. but addtionalProperties is not recommended by swagger. Is there any other way to define such a dictionary in swagger?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More explanation:

  1. extendedproperties in Data connector represent various additional option highly dependent on the specific data connector being used. It's common industrial practice to make the data connector protocol extensible, like JDBC, ODBC...
  2. all the elements to be treated as an atomic unit, non-ordered.
  3. the property set represents a simplistic array with a very small number of elements that are not expected to grow drastically over time and would never have paging requirements.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please do/answer the followings?

  1. Add or modify example files to show what extended properties look like for at least two different data connectors. That will make it clearer to the reviewers and the customers.
  2. How would customers know what the valid set of extended properties for each data connector are? Are they widely known as industrial practice? Consider expanding the description to give customers better idea.
  3. We do allow additionalProperties if the properties are simply passing through your service and you don't control nor validate them. (e.g. tags for Azure resources or labels for Kubernetes). If that's your case, please do use additionalProperties and suppress the validation error. We will approve the suppression if it's justified.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have updated the example files and this is a pass-through property. our RP doesn't do any validation on this property. So, I just changed it to dictionary for better understanding.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3rd point is not yet addressed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In addition, I also don't see 1st point (adding example files) and 2nd point (change description to indicate where to get the valid set of properties).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry, I pushed the latest change to another branch. Now it has the latest change. but the validation shows "the type is invalid. expected object, but found string, array". Actually, we cannot specify the value type, the value could be string or array. That's why we used object. @gary-x-li , do you know how to solve such issue?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@LaylaLiu-gmail I'm not sure. You can post your question in this channel; or search similar examples in the repo.

"type": "object",
"description": "Additional properties for the data connector which can be used to store custom key-value pairs.",
"additionalProperties": {
"type": "object"
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,20 @@
"agentSpaceName": "testAgentSpace",
"dataConnectorName": "new-shared-cosmosdb-connector",
"api-version": "2026-01-01",
"agentSpaceDataConnectorEnvelope": {

Check failure on line 8 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type array

Check failure on line 8 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"properties": {
"dataConnectorType": "CosmosDB",
"dataSource": "https://newsharedcosmos.documents.azure.com:443/",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/new-shared-cosmos-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sharedCosmosIdentity"
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sharedCosmosIdentity",
"extendedProperties": {
"environment": "production",
"owner": "alice",
"additionalEndpoints": [
"https://foo.kusto.windows.net/databasename",
"https://bar.kusto.windows.net/databasename"
]
}
}
}
},
Expand All @@ -23,7 +31,15 @@
"properties": {
"dataConnectorType": "CosmosDB",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/new-shared-cosmos-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sharedCosmosIdentity"
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sharedCosmosIdentity",
"extendedProperties": {
"environment": "production",

Check failure on line 36 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"owner": "alice",

Check failure on line 37 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"additionalEndpoints": [

Check failure on line 38 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type array
"https://foo.kusto.windows.net/databasename",
"https://bar.kusto.windows.net/databasename"
]
}
}
}
},
Expand All @@ -38,7 +54,15 @@
"properties": {
"dataConnectorType": "CosmosDB",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/new-shared-cosmos-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sharedCosmosIdentity"
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sharedCosmosIdentity",
"extendedProperties": {
"environment": "production",

Check failure on line 59 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"owner": "alice",

Check failure on line 60 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"additionalEndpoints": [

Check failure on line 61 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentSpacesConnectors_CreateOrUpdate.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type array
"https://foo.kusto.windows.net/databasename",
"https://bar.kusto.windows.net/databasename"
]
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,14 @@
"dataConnectorType": "SqlServer",
"dataSource": "Server=newserver.database.windows.net;Database=NewDB;",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/new-sql-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sqlIdentity"
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sqlIdentity",
"extendedProperties": {
"AuthType": "Custom",
"CustomHeader": {
"DD_API_KEY": "value 1",
"DD_APPLICATION_KEY": "value 2"
}
}
}
}
},
Expand All @@ -24,7 +31,14 @@
"dataConnectorType": "SqlServer",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/new-sql-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sqlIdentity",
"source": "Agent"
"source": "Agent",
"extendedProperties": {
"AuthType": "Custom",
"CustomHeader": {
"DD_API_KEY": "value 1",
"DD_APPLICATION_KEY": "value 2"
}
}
}
}
},
Expand All @@ -41,6 +55,13 @@
"keyVaultUri": "https://testkv.vault.azure.net/secrets/new-sql-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sqlIdentity",
"source": "Agent",
"extendedProperties": {
"AuthType": "Custom",
"CustomHeader": {
"DD_API_KEY": "value 1",
"DD_APPLICATION_KEY": "value 2"
}
},
"provisioningState": "InProgress"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,14 @@
"dataConnectorType": "SqlServer",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/sql-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sqlIdentity",
"source": "Agent"
"source": "Agent",
"extendedProperties": {
"AuthType": "Custom",
"CustomHeader": {
"DD_API_KEY": "value 1",
"DD_APPLICATION_KEY": "value 2"
}
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,14 @@
"dataConnectorType": "SqlServer",
"keyVaultUri": "https://testkv.vault.azure.net/secrets/sql-connection-string",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/sqlIdentity",
"source": "Agent"
"source": "Agent",
"extendedProperties": {
"AuthType": "Custom",

Check failure on line 22 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentsConnectors_ListByAgent.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"CustomHeader": {
"DD_API_KEY": "value 1",
"DD_APPLICATION_KEY": "value 2"
}
}
}
},
{
Expand All @@ -27,7 +34,15 @@
"properties": {
"dataConnectorType": "AzureStorage",
"identity": "/subscriptions/8efdecc5-919e-44eb-b179-915dca89ebf9/resourceGroups/examplerg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/storageIdentity",
"source": "AgentSpace"
"source": "AgentSpace",
"extendedProperties": {
"environment": "production",

Check failure on line 39 in specification/app/resource-manager/Microsoft.App/ContainerApps/stable/2026-01-01/examples/AgentsConnectors_ListByAgent.json

View workflow job for this annotation

GitHub Actions / Swagger ModelValidation - Analyze Code

INVALID_TYPE: Expected type object but found type string
"owner": "alice",
"additionalEndpoints": [
"https://foo.kusto.windows.net/databasename",
"https://bar.kusto.windows.net/databasename"
]
}
}
},
{
Expand Down
Loading