Skip to content

CosmosDiagnostics changes from v3.15 to v3.20.1 #2679

Closed

Description

In SDK version 3.15 we took advantage of the following properties in the CosmosDiagnostics property of the response to record the following key metrics in Telemetry:

"DiagnosticVersion": "2",
        "Summary": {
            "StartUtc": "2021-08-19T19:08:12.8789031Z",
            "RunningElapsedTimeInMs": 184894.7196,
            "UserAgent": "cosmos-netstandard-sdk/3.15.0|3.15.2|01|X64|Microsoft Windows 10.0.18363|.NET Core 3.1.10|",
            "TotalRequestCount": 1,
            "FailedRequestCount": 0
        }

In version 3.20.1 the format of the CosmosDiagnostics json has changed significantly and the TotalRequestCount and FailedRequestCount are no longer there.:

"name": "CreateItemAsync",
    "id": "4ac11b57-5103-4a83-8c30-d19e0acb921d",
    "caller info": {
        "member": "OperationHelperWithRootTraceAsync",
        "file": "ClientContextCore.cs",
        "line": 219
    },
    "start time": "07:17:13:399",
    "duration in milliseconds": 8423.9044000000013,
    "data": {
        "Client Configuration": {
            "Client Created Time Utc": "2021-08-19T19:09:18.3183366Z",
            "NumberOfClientsCreated": 1,
            "User Agent": "cosmos-netstandard-sdk/3.20.1|3.19.3|1|X64|Microsoft Windows 10.0.18363 |.NET Core 4.6.29321.03|S|",
            "ConnectionConfig": {
                "gw": "(cps:50, urto:10, p:False, httpf: False)",
                "rntbd": "(cto: 5, icto: -1, mrpc: 30, mcpe: 65535, erd: False, pr: ReuseUnicastPort)",
                "other": "(ed:False, be:False)"
            },
            "ConsistencyConfig": "(consistency: NotSet, prgns:[])"
        }
    }

I would really like for those two properties to be put back. If not, is there another way we can get this information? For example by aggregating the retry counts on one or more of the Request Handler child objects if it exists. That would allow us to derive the data to meet our requirements.

Thank you,
Steve

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    DiagnosticsIssues around diagnostics and troubleshootingfeature-requestNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions