You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: dd-java-agent/instrumentation/spark/spark_2.12/src/main/java/datadog/trace/instrumentation/spark/Spark212Instrumentation.java
+24-7Lines changed: 24 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -110,21 +110,38 @@ public static void exit(
110
110
.toMap(Predef.$conforms());
111
111
try {
112
112
Constructor<?> targetCtor = null;
113
+
Object[] args = null;
113
114
for (Constructor<?> c : SparkPlanInfo.class.getConstructors()) {
114
115
if (c.getParameterCount() == 5) {
115
116
targetCtor = c;
117
+
args =
118
+
newObject[] {
119
+
planInfo.nodeName(),
120
+
planInfo.simpleString(),
121
+
planInfo.children(),
122
+
meta,
123
+
planInfo.metrics()
124
+
};
116
125
break;
117
-
}
118
-
}
119
-
if (targetCtor!= null) {
120
-
ObjectnewInst =
121
-
targetCtor.newInstance(
126
+
}elseif (c.getParameterCount() == 8) {
127
+
// Databricks fork of Spark has a different SparkPlanInfo constructor
Copy file name to clipboardExpand all lines: dd-java-agent/instrumentation/spark/spark_2.13/src/main/java/datadog/trace/instrumentation/spark/Spark213Instrumentation.java
0 commit comments