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

Where applicable, update Windows pools used to azsdk-pool-mms-win-2022-general and rename vmImage to the windows-20xx format #3152

Merged
merged 5 commits into from
Feb 21, 2023
Merged
Show file tree
Hide file tree
Changes from 2 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
2 changes: 1 addition & 1 deletion eng/pipelines/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ stages:
timeoutInMinutes: 120
pool:
name: azsdk-pool-mms-win-2022-general
vmImage: MMS2022Compliant
vmImage: windows-2022
steps:
- checkout: self
- checkout: azure-sdk-tools
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/check-code-generation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
- job: ${{ parameters.name }}
pool:
name: azsdk-pool-mms-win-2022-general
vmImage: MMS2022Compliant
vmImage: windows-2022
steps:
- task: NodeTool@0
displayName: "Install Node 18.13.0"
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/mgmt-mocktest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ stages:
timeoutInMinutes: 240
pool:
name: azsdk-pool-mms-win-2022-general
vmImage: MMS2022Compliant
vmImage: windows-2022
steps:
- checkout: self
- checkout: azure-sdk-tools
Expand Down
38 changes: 19 additions & 19 deletions src/assets/Azure.Core.Shared/DiagnosticScope.cs
Original file line number Diff line number Diff line change
Expand Up @@ -207,25 +207,6 @@ public ActivityAdapter(object? activitySource, DiagnosticSource diagnosticSource
_activityName = activityName;
_kind = kind;
_diagnosticSourceArgs = diagnosticSourceArgs;

switch (_kind)
{
case ActivityKind.Internal:
AddTag("kind", "internal");
break;
case ActivityKind.Server:
AddTag("kind", "server");
break;
case ActivityKind.Client:
AddTag("kind", "client");
break;
case ActivityKind.Producer:
AddTag("kind", "producer");
break;
case ActivityKind.Consumer:
AddTag("kind", "consumer");
break;
}
}

public void AddTag(string name, object value)
Expand Down Expand Up @@ -310,6 +291,25 @@ public void AddLink(string traceparent, string tracestate, IDictionary<string, s
return null;
}

switch (_kind)
{
case ActivityKind.Internal:
AddTag("kind", "internal");
break;
case ActivityKind.Server:
AddTag("kind", "server");
break;
case ActivityKind.Client:
AddTag("kind", "client");
break;
case ActivityKind.Producer:
AddTag("kind", "producer");
break;
case ActivityKind.Consumer:
AddTag("kind", "consumer");
break;
}
konrad-jamrozik marked this conversation as resolved.
Show resolved Hide resolved

_currentActivity = new DiagnosticActivity(_activityName)
{
Links = (IEnumerable<Activity>?)_links ?? Array.Empty<Activity>(),
Expand Down