Skip to content

Commit 6065079

Browse files
authored
Add new ktor preview instrumentation (#3243)
1 parent 965405b commit 6065079

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

agent/agent-tooling/src/main/java/com/microsoft/applicationinsights/agent/internal/configuration/Configuration.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -477,6 +477,8 @@ public static class PreviewInstrumentation {
477477

478478
public DisabledByDefaultInstrumentation apacheCamel = new DisabledByDefaultInstrumentation();
479479

480+
public DisabledByDefaultInstrumentation ktor = new DisabledByDefaultInstrumentation();
481+
480482
// this is just here to detect if using this old setting in order to give a helpful message
481483
@Deprecated
482484
public DisabledByDefaultInstrumentation azureSdk = new DisabledByDefaultInstrumentation();

agent/agent-tooling/src/main/java/com/microsoft/applicationinsights/agent/internal/init/AiConfigCustomizer.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,9 @@ private static void enableInstrumentations(
282282
if (config.preview.instrumentation.vertx.enabled) {
283283
properties.put("otel.instrumentation.vertx.enabled", "true");
284284
}
285+
if (config.preview.instrumentation.ktor.enabled) {
286+
properties.put("otel.instrumentation.ktor.enabled", "true");
287+
}
285288
if (config.preview.instrumentation.jaxrsAnnotations.enabled) {
286289
properties.put("otel.instrumentation.jaxrs-1.0.enabled", "true");
287290
properties.put("otel.instrumentation.jaxrs-annotations.enabled", "true");

0 commit comments

Comments
 (0)