-
Notifications
You must be signed in to change notification settings - Fork 339
Add application identity to USERAGENT payload (V2) #4632
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
base: main
Are you sure you want to change the base?
Changes from all commits
60037bc
c9f0cec
171d890
1d296c9
0c2bfcc
a1ae554
9c7f4b0
2f82e5e
1510d6f
d849cf4
095d84e
e8a5509
4c29388
9bfbc07
f087c29
597e75a
a301c0b
05516e0
474fdc4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,147 @@ | ||
| <docs> | ||
| <members name="RegisteredApplication"> | ||
| <RegisteredApplication> | ||
| <summary> | ||
| Specifies the known application identifiers that Microsoft.Data.SqlClient reports for user agent telemetry. | ||
| </summary> | ||
| <remarks> | ||
| <para> | ||
| Production applications that meet the bar are welcome to reserve an identifier here. | ||
| </para> | ||
| <para> | ||
| Identifier reservations are as follows: | ||
| </para> | ||
| <list type="bullet"> | ||
| <item> | ||
| <description>0x0001-0x7FFF: Microsoft-defined large-scale applications.</description> | ||
| </item> | ||
| <item> | ||
| <description>0x8000-0xBFFF: Reserved for small-scale use.</description> | ||
| </item> | ||
| <item> | ||
| <description>0xC000-0xFFFF: Public and developer use.</description> | ||
| </item> | ||
| </list> | ||
| <para> | ||
| An unregistered identifier may still be reported by casting a value to this type. | ||
| </para> | ||
| </remarks> | ||
| </RegisteredApplication> | ||
| <Unknown> | ||
| <summary> | ||
| No application identity is reported. This is the default. | ||
| </summary> | ||
| <value> | ||
| 0 | ||
| </value> | ||
| </Unknown> | ||
| <EntityFrameworkCore> | ||
| <summary> | ||
| The Microsoft Entity Framework Core SQL Server provider. | ||
| </summary> | ||
| <value> | ||
| 1 | ||
| </value> | ||
| </EntityFrameworkCore> | ||
| <SemanticKernel> | ||
| <summary> | ||
| Microsoft Semantic Kernel. | ||
| </summary> | ||
| <value> | ||
| 2 | ||
| </value> | ||
| </SemanticKernel> | ||
| <ManagementStudio> | ||
| <summary> | ||
| Microsoft SQL Server Management Studio. | ||
| </summary> | ||
| <value> | ||
| 3 | ||
| </value> | ||
| </ManagementStudio> | ||
| <SqlManagementObjects> | ||
| <summary> | ||
| Microsoft SQL Server Management Objects. | ||
| </summary> | ||
| <value> | ||
| 4 | ||
| </value> | ||
| </SqlManagementObjects> | ||
| <DataTierApplicationFramework> | ||
| <summary> | ||
| Microsoft SQL Server Data-Tier Application Framework. | ||
| </summary> | ||
| <value> | ||
| 5 | ||
| </value> | ||
| </DataTierApplicationFramework> | ||
| <SqlToolsService> | ||
| <summary> | ||
| Microsoft SQL Tools Service. | ||
| </summary> | ||
| <value> | ||
| 6 | ||
| </value> | ||
| </SqlToolsService> | ||
| <AspNetCoreDistributedSqlServerCache> | ||
| <summary> | ||
| Microsoft ASP.NET Core distributed SQL Server cache. | ||
| </summary> | ||
| <value> | ||
| 7 | ||
| </value> | ||
| </AspNetCoreDistributedSqlServerCache> | ||
| <EntityFramework> | ||
| <summary> | ||
| Microsoft Entity Framework 6 SQL Server provider. | ||
| </summary> | ||
| <value> | ||
| 8 | ||
| </value> | ||
| </EntityFramework> | ||
| <AzureFunctionsSqlExtension> | ||
| <summary> | ||
| Microsoft Azure Functions SQL extension. | ||
| </summary> | ||
| <value> | ||
| 9 | ||
| </value> | ||
| </AzureFunctionsSqlExtension> | ||
| <OrleansAdoNet> | ||
| <summary> | ||
| Microsoft Orleans ADO.NET providers. | ||
| </summary> | ||
| <value> | ||
| 10 | ||
| </value> | ||
| </OrleansAdoNet> | ||
| <DurableTaskSqlServer> | ||
| <summary> | ||
| Microsoft Durable Task SQL Server provider. | ||
| </summary> | ||
| <value> | ||
| 11 | ||
| </value> | ||
| </DurableTaskSqlServer> | ||
| <SqlPackage> | ||
| <summary> | ||
| The <c>sqlpackage</c> command-line tool. | ||
| </summary> | ||
| <value> | ||
| 12 | ||
| </value> | ||
| <remarks> | ||
| <c>sqlpackage</c> is built on the Data-Tier Application Framework, but reports its own identifier so that | ||
| command-line use can be told apart from other callers of that framework. | ||
| </remarks> | ||
| </SqlPackage> | ||
| <DataApiBuilder> | ||
| <summary> | ||
| Microsoft Data API builder. | ||
| </summary> | ||
| <value> | ||
| 13 | ||
| </value> | ||
| </DataApiBuilder> | ||
| </members> | ||
| </docs> |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -592,6 +592,40 @@ public void LogError(string type, string method, string message) { } | |
| public void LogInfo(string type, string method, string message) { } | ||
| } | ||
|
|
||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/RegisteredApplication/*' /> | ||
| [System.CLSCompliantAttribute(false)] | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since this type is opt-in telemetry for existing apps, I don't think the lack of CLS compliance is a problem. Any existing apps relying on CLS compliance will need to take explicit steps to use this enum and the new
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agreed. The enum and property remain explicitly non-CLS-compliant. |
||
| public enum RegisteredApplication : ushort | ||
| { | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/Unknown/*' /> | ||
| Unknown = 0, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/EntityFrameworkCore/*' /> | ||
| EntityFrameworkCore = 1, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SemanticKernel/*' /> | ||
| SemanticKernel = 2, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/ManagementStudio/*' /> | ||
| ManagementStudio = 3, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SqlManagementObjects/*' /> | ||
| SqlManagementObjects = 4, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/DataTierApplicationFramework/*' /> | ||
| DataTierApplicationFramework = 5, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SqlToolsService/*' /> | ||
| SqlToolsService = 6, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/AspNetCoreDistributedSqlServerCache/*' /> | ||
| AspNetCoreDistributedSqlServerCache = 7, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/EntityFramework/*' /> | ||
| EntityFramework = 8, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/AzureFunctionsSqlExtension/*' /> | ||
| AzureFunctionsSqlExtension = 9, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/OrleansAdoNet/*' /> | ||
| OrleansAdoNet = 10, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/DurableTaskSqlServer/*' /> | ||
| DurableTaskSqlServer = 11, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SqlPackage/*' /> | ||
| SqlPackage = 12, | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/DataApiBuilder/*' /> | ||
| DataApiBuilder = 13 | ||
| } | ||
|
|
||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/SqlClientMetaDataCollectionNames.xml' path='docs/members[@name="SqlClientMetaDataCollectionNames"]/SqlClientMetaDataCollectionNames/*'/> | ||
| public static class SqlClientMetaDataCollectionNames | ||
| { | ||
|
|
@@ -1010,6 +1044,9 @@ public SqlConnection() { } | |
| public SqlConnection(string connectionString) { } | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/SqlConnection.xml' path='docs/members[@name="SqlConnection"]/ctorConnectionStringCredential/*'/> | ||
| public SqlConnection(string connectionString, Microsoft.Data.SqlClient.SqlCredential credential) { } | ||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/SqlConnection.xml' path='docs/members[@name="SqlConnection"]/RegisteredApplication/*' /> | ||
| [System.CLSCompliantAttribute(false)] | ||
| public Microsoft.Data.SqlClient.RegisteredApplication RegisteredApplication { get { throw null; } set { } } | ||
|
|
||
| /// <include file='../../../doc/snippets/Microsoft.Data.SqlClient/SqlConnection.xml' path='docs/members[@name="SqlConnection"]/AccessToken/*'/> | ||
| [System.ComponentModel.BrowsableAttribute(false)] | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| // Licensed to the .NET Foundation under one or more agreements. | ||
| // The .NET Foundation licenses this file to you under the MIT license. | ||
| // See the LICENSE file in the project root for more information. | ||
|
|
||
| #nullable enable | ||
|
|
||
| namespace Microsoft.Data.SqlClient; | ||
|
|
||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/RegisteredApplication/*' /> | ||
| [System.CLSCompliant(false)] | ||
| public enum RegisteredApplication : ushort | ||
| { | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/Unknown/*' /> | ||
| Unknown = 0, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/EntityFrameworkCore/*' /> | ||
| EntityFrameworkCore = 1, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SemanticKernel/*' /> | ||
| SemanticKernel = 2, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/ManagementStudio/*' /> | ||
| ManagementStudio = 3, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SqlManagementObjects/*' /> | ||
| SqlManagementObjects = 4, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/DataTierApplicationFramework/*' /> | ||
| DataTierApplicationFramework = 5, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SqlToolsService/*' /> | ||
| SqlToolsService = 6, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/AspNetCoreDistributedSqlServerCache/*' /> | ||
| AspNetCoreDistributedSqlServerCache = 7, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/EntityFramework/*' /> | ||
| EntityFramework = 8, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/AzureFunctionsSqlExtension/*' /> | ||
| AzureFunctionsSqlExtension = 9, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/OrleansAdoNet/*' /> | ||
| OrleansAdoNet = 10, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/DurableTaskSqlServer/*' /> | ||
| DurableTaskSqlServer = 11, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/SqlPackage/*' /> | ||
| SqlPackage = 12, | ||
| /// <include file='../../../../../../doc/snippets/Microsoft.Data.SqlClient/RegisteredApplication.xml' path='docs/members[@name="RegisteredApplication"]/DataApiBuilder/*' /> | ||
| DataApiBuilder = 13 | ||
| } |
Uh oh!
There was an error while loading. Please reload this page.