Skip to content

Commit fd74efe

Browse files
committed
Properly handle objectClass attribute
1 parent d021da6 commit fd74efe

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

dd-java-agent/agent-profiling/profiling-otel/src/main/java/com/datadog/profiling/otel/JfrToOtlpConverter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ private void handleObjectSample(ObjectSample event, Control ctl) {
416416
int sampleTypeIndex = getSampleTypeAttributeIndex("alloc");
417417
String className = null;
418418
try {
419-
className = event.objectClass();
419+
className = event.objectClass().name();
420420
} catch (Exception ignored) {
421421
// objectClass field doesn't exist in this JFR event - skip it
422422
}

dd-java-agent/agent-profiling/profiling-otel/src/main/java/com/datadog/profiling/otel/jfr/ObjectSample.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ public interface ObjectSample {
2121
long allocationSize();
2222

2323
@JfrField("objectClass")
24-
String objectClass();
24+
JfrClass objectClass();
2525

2626
@JfrField("size")
2727
long size();

0 commit comments

Comments
 (0)