Skip to content

Commit 1c2c74a

Browse files
Merge branch 'master' into sezen.leblay/apm-metrics-tag
2 parents feab335 + 2e10824 commit 1c2c74a

File tree

67 files changed

+230
-154
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+230
-154
lines changed

dd-java-agent/agent-bootstrap/src/main/resources/META-INF/native-image/com.datadoghq/dd-java-agent/reflect-config.json

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -181,11 +181,5 @@
181181
"fields": [
182182
{"name": "consumerIndex", "allowUnsafeAccess": true}
183183
]
184-
},
185-
{
186-
"name" : "datadog.jctools.maps.NonBlockingHashMap",
187-
"fields": [
188-
{"name": "_kvs", "allowUnsafeAccess": true}
189-
]
190184
}
191185
]

dd-java-agent/agent-profiling/profiling-controller-jfr/src/main/java/com/datadog/profiling/controller/jfr/parser/MetadataEvent.java

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import java.io.IOException;
44
import java.nio.charset.StandardCharsets;
5-
import org.jctools.maps.NonBlockingHashMapLong;
65

76
/**
87
* JFR Chunk metadata
@@ -17,10 +16,6 @@ public final class MetadataEvent {
1716
public final long duration;
1817
public final long metadataId;
1918

20-
private final NonBlockingHashMapLong<String> eventTypeNameMapBacking =
21-
new NonBlockingHashMapLong<>(256);
22-
private final LongMapping<String> eventTypeMap;
23-
2419
MetadataEvent(RecordingStream stream) throws IOException {
2520
size = (int) stream.readVarint();
2621
long typeId = stream.readVarint();
@@ -31,16 +26,6 @@ public final class MetadataEvent {
3126
duration = stream.readVarint();
3227
metadataId = stream.readVarint();
3328
readElements(stream, readStringTable(stream));
34-
eventTypeMap = eventTypeNameMapBacking::get;
35-
}
36-
37-
/**
38-
* Lazily compute and return the mappings of event type ids to event type names
39-
*
40-
* @return mappings of event type ids to event type names
41-
*/
42-
public LongMapping<String> getEventTypeNameMap() {
43-
return eventTypeMap;
4429
}
4530

4631
private String[] readStringTable(RecordingStream stream) throws IOException {
@@ -76,10 +61,6 @@ private void readElements(RecordingStream stream, String[] stringConstants) thro
7661
}
7762
}
7863
}
79-
// only event types are currently collected
80-
if (name != null && id != null && "jdk.jfr.Event".equals(superType)) {
81-
eventTypeNameMapBacking.put(Long.parseLong(id), name);
82-
}
8364
// now inspect all the enclosed elements
8465
int elemCount = (int) stream.readVarint();
8566
for (int i = 0; i < elemCount; i++) {

dd-java-agent/instrumentation/akka/akka-actor-2.5/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,6 @@ configurations.matching({ it.name.startsWith('akka23') }).each({
6868

6969

7070
// Run 2.3 tests along with the rest of unit tests
71-
tasks.named("test") {
71+
tasks.named("test", Test) {
7272
dependsOn "akka23Test"
7373
}

dd-java-agent/instrumentation/akka/akka-http/akka-http-10.0/build.gradle

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ addTestSuiteForDir 'version101IastTest', 'iastTest'
2222
addTestSuiteForDir 'version102IastTest', 'iastTest'
2323
addTestSuiteForDir 'latestDepIastTest', 'iastTest'
2424

25-
compileLagomTestJava {
25+
tasks.named("compileLagomTestJava", JavaCompile) {
2626
sourceCompatibility = JavaVersion.VERSION_1_8
2727
targetCompatibility = JavaVersion.VERSION_1_8
2828
}
2929

30-
compileLagomTestGroovy {
30+
tasks.named("compileLagomTestGroovy", GroovyCompile) {
3131
sourceCompatibility = JavaVersion.VERSION_1_8
3232
targetCompatibility = JavaVersion.VERSION_1_8
3333
}
@@ -170,32 +170,32 @@ dependencies {
170170
lagomTestImplementation group: 'com.lightbend.lagom', name: 'lagom-javadsl-testkit_2.11', version: '1.4.0'
171171
}
172172

173-
compileBaseTestGroovy {
173+
tasks.named("compileBaseTestGroovy", GroovyCompile) {
174174
classpath = classpath.plus(files(compileBaseTestScala.destinationDirectory))
175175
dependsOn "compileBaseTestScala"
176176
}
177177

178-
compileBaseForkedTestGroovy {
178+
tasks.named("compileBaseForkedTestGroovy", GroovyCompile) {
179179
classpath = classpath.plus(files(compileBaseTestScala.destinationDirectory))
180180
dependsOn "compileBaseTestScala"
181181
}
182182

183-
compileVersion101TestGroovy {
183+
tasks.named("compileVersion101TestGroovy", GroovyCompile) {
184184
classpath = classpath.plus(files(compileVersion101TestScala.destinationDirectory))
185185
dependsOn "compileVersion101TestScala"
186186
}
187187

188-
compileVersion101ForkedTestGroovy {
188+
tasks.named("compileVersion101ForkedTestGroovy", GroovyCompile) {
189189
classpath = classpath.plus(files(compileVersion101TestScala.destinationDirectory))
190190
dependsOn "compileVersion101TestScala"
191191
}
192192

193-
compileVersion102Scala213TestGroovy {
193+
tasks.named("compileVersion102Scala213TestGroovy", GroovyCompile) {
194194
classpath = classpath.plus(files(compileVersion102Scala213TestScala.destinationDirectory))
195195
dependsOn "compileVersion102Scala213TestScala"
196196
}
197197

198-
compileLatestDepTestGroovy {
198+
tasks.named("compileLatestDepTestGroovy", GroovyCompile) {
199199
classpath = classpath.plus(files(compileLatestDepTestScala.destinationDirectory))
200200
dependsOn "compileLatestDepTestScala"
201201
}

dd-java-agent/instrumentation/armeria/armeria-grpc-0.84/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ addTestSuiteExtendingForDir('latestDepForkedTest', 'latestDepTest', 'test')
4242

4343
apply from: "$rootDir/gradle/configure_tests.gradle"
4444

45-
latestDepTest {
45+
tasks.named("latestDepTest", Test) {
4646
finalizedBy 'latestDepForkedTest'
4747
}
4848

dd-java-agent/instrumentation/armeria/armeria-jetty-1.24/build.gradle

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,4 @@ dependencies {
9292
testRuntimeOnly project(':dd-java-agent:instrumentation:jetty:jetty-appsec:jetty-appsec-9.3')
9393
testRuntimeOnly project(':dd-java-agent:instrumentation:servlet:jakarta-servlet-5.0')
9494
testRuntimeOnly project(':dd-java-agent:instrumentation:servlet:javax-servlet:javax-servlet-3.0')
95-
96-
9795
}

dd-java-agent/instrumentation/aws-java/aws-java-lambda-handler-1.2/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ apply from: "$rootDir/gradle/java.gradle"
1010

1111
addTestSuiteForDir('latestDepTest', 'test')
1212

13-
test {
13+
tasks.named("test", Test) {
1414
environment "_HANDLER", "Handler"
1515
}
1616

17-
forkedTest {
17+
tasks.named("forkedTest", Test) {
1818
environment "_HANDLER", "Handler"
1919
}
2020

21-
latestDepTest {
21+
tasks.named("latestDepTest", Test) {
2222
environment "_HANDLER", "Handler"
2323
}
2424

dd-java-agent/instrumentation/aws-java/aws-java-sdk-1.11/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,10 +103,10 @@ dependencies {
103103
latestDepTestImplementation group: 'com.amazonaws', name: 'aws-java-sdk-dynamodb', version: '+'
104104
}
105105

106-
tasks.named("test") {
106+
tasks.named("test", Test) {
107107
dependsOn "test_before_1_11_106"
108108
}
109109

110-
tasks.named("forkedTest") {
110+
tasks.named("forkedTest", Test) {
111111
dependsOn "test_before_1_11_106ForkedTest"
112112
}

dd-java-agent/instrumentation/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ plugins {
3131
apply from: "$rootDir/gradle/java.gradle"
3232

3333

34-
tasks.register("latestDepTest")
34+
tasks.register("latestDepTest", Test)
3535

3636
Project parent_project = project
3737
subprojects { Project subProj ->
@@ -129,7 +129,7 @@ if (project.gradle.startParameter.taskNames.any { it.endsWith("generateMuzzleRep
129129
}
130130

131131

132-
tasks.named('shadowJar') {
132+
tasks.named('shadowJar', ShadowJar) {
133133
duplicatesStrategy = DuplicatesStrategy.FAIL
134134
dependencies {
135135
// the tracer is now in a separate shadow jar

dd-java-agent/instrumentation/enable-wallclock-profiling/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ dependencies {
3131
latestDepTestImplementation group: 'io.netty', name: 'netty-transport', version: '+'
3232
}
3333

34-
tasks.named("latestDepTest") {
34+
tasks.named("latestDepTest", Test) {
3535
dependsOn "latestDep4Test"
3636
}
3737

0 commit comments

Comments
 (0)