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

[Port v2int 3.0] Rename TelemetryContext::SetAll to SetMultiple #14873

Merged
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
2 changes: 1 addition & 1 deletion api-report/runtime-definitions.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ export interface ITelemetryContext {
get(prefix: string, property: string): TelemetryEventPropertyType;
serialize(): string;
set(prefix: string, property: string, value: TelemetryEventPropertyType): void;
setAll(prefix: string, property: string, values: Record<string, TelemetryEventPropertyType>): void;
setMultiple(prefix: string, property: string, values: Record<string, TelemetryEventPropertyType>): void;
}

// @public
Expand Down
2 changes: 1 addition & 1 deletion api-report/runtime-utils.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ export class TelemetryContext implements ITelemetryContext {
// (undocumented)
set(prefix: string, property: string, value: TelemetryEventPropertyType): void;
// (undocumented)
setAll(prefix: string, property: string, values: Record<string, TelemetryEventPropertyType>): void;
setMultiple(prefix: string, property: string, values: Record<string, TelemetryEventPropertyType>): void;
}

// @public (undocumented)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2198,7 +2198,7 @@ export class ContainerRuntime extends TypedEventEmitter<IContainerRuntimeEvents>

const telemetryContext = new TelemetryContext();
// Add the options that are used to generate this summary to the telemetry context.
telemetryContext.setAll("fluid_Summarize", "Options", {
telemetryContext.setMultiple("fluid_Summarize", "Options", {
fullTree,
trackState,
runGC,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -978,7 +978,7 @@ export class GarbageCollector implements IGarbageCollector {
}

// Add the options that are used to run GC to the telemetry context.
telemetryContext?.setAll("fluid_GC", "Options", { fullGC, runSweep: options.runSweep });
telemetryContext?.setMultiple("fluid_GC", "Options", { fullGC, runSweep: options.runSweep });

return PerformanceEvent.timedExecAsync(logger, { eventName: "GarbageCollection" }, async (event) => {
await this.runPreGCSteps();
Expand Down
2 changes: 1 addition & 1 deletion packages/runtime/runtime-definitions/src/summary.ts
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ export interface ITelemetryContext {
* @param property - property name of the telemetry data being tracked (ex: "Options")
* @param values - A set of values to attribute to this summary telemetry data.
*/
setAll(
setMultiple(
prefix: string,
property: string,
values: Record<string, TelemetryEventPropertyType>,
Expand Down
4 changes: 2 additions & 2 deletions packages/runtime/runtime-utils/src/summaryUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -349,9 +349,9 @@ export class TelemetryContext implements ITelemetryContext {
}

/**
* {@inheritDoc @fluidframework/runtime-definitions#ITelemetryContext.setAll}
* {@inheritDoc @fluidframework/runtime-definitions#ITelemetryContext.setMultiple}
*/
setAll(
setMultiple(
prefix: string,
property: string,
values: Record<string, TelemetryEventPropertyType>,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ describe("Summary Utils", () => {
telemetryContext.set("pre2_", "prop1", "10");
telemetryContext.set("pre2_", "prop2", true);
telemetryContext.set("pre1_", "prop2", undefined);
telemetryContext.setAll("pre3_", "obj1", { prop1: "1", prop2: 2, prop3: true });
telemetryContext.setMultiple("pre3_", "obj1", { prop1: "1", prop2: 2, prop3: true });

const serialized = telemetryContext.serialize();

Expand Down