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

Rename propagation modules #1706

Merged
merged 2 commits into from
Nov 20, 2020
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
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.akkaconcurrent;
package io.opentelemetry.javaagent.instrumentation.akkaactor;

import static java.util.Arrays.asList;

Expand All @@ -18,9 +18,9 @@
import java.util.concurrent.Callable;

@AutoService(InstrumentationModule.class)
public class AkkaContextPropagationInstrumentationModule extends InstrumentationModule {
public AkkaContextPropagationInstrumentationModule() {
super("akka-context-propagation", "akka-context-propagation-2.5");
public class AkkaActorInstrumentationModule extends InstrumentationModule {
public AkkaActorInstrumentationModule() {
super("akka-actor", "akka-actor-2.5");
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.akkaconcurrent;
package io.opentelemetry.javaagent.instrumentation.akkaactor;

import static net.bytebuddy.matcher.ElementMatchers.nameMatches;
import static net.bytebuddy.matcher.ElementMatchers.named;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.akkaconcurrent;
package io.opentelemetry.javaagent.instrumentation.akkaactor;

import static io.opentelemetry.javaagent.tooling.ClassLoaderMatcher.hasClassesNamed;
import static io.opentelemetry.javaagent.tooling.bytebuddy.matcher.AgentElementMatchers.extendsClass;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import io.opentelemetry.instrumentation.test.AgentTestRunner

class AkkaActorTest extends AgentTestRunner {

// TODO this test doesn't really depend on otel.instrumentation.akka_context_propagation.enabled=true
// TODO this test doesn't really depend on otel.instrumentation.akka-actor.enabled=true
// but setting this property here is needed when running both this test
// and AkkaExecutorInstrumentationTest in the run, otherwise get
// "class redefinition failed: attempted to change superclass or interfaces"
Expand All @@ -16,7 +16,7 @@ class AkkaActorTest extends AgentTestRunner {
// instrumentation in this module, is it just to verify that the instrumentation doesn't break
// this scenario?)
static {
System.setProperty("otel.instrumentation.akka_context_propagation.enabled", "true")
System.setProperty("otel.instrumentation.akka-actor.enabled", "true")
}

def "akka #testMethod"() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import spock.lang.Shared
class AkkaExecutorInstrumentationTest extends AgentTestRunner {

static {
System.setProperty("otel.instrumentation.akka_context_propagation.enabled", "true")
System.setProperty("otel.instrumentation.akka-actor.enabled", "true")
}

@Shared
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.kotlincoroutines;
package io.opentelemetry.javaagent.instrumentation.kotlinxcoroutines;

import static java.util.Collections.singletonList;
import static net.bytebuddy.matcher.ElementMatchers.named;
Expand Down Expand Up @@ -53,7 +53,7 @@ object can be found (tied to the chain of Continutations in the Coroutine).
*/

public KotlinCoroutinesInstrumentationModule() {
super("kotlin-coroutines");
super("kotlinx-coroutines");
}

@Override
Expand Down Expand Up @@ -134,6 +134,7 @@ public CoroutineWrapper(Continuation<T> proxy) {
this.contextWrapper = new CoroutineContextWrapper(proxy.getContext());
}

@Override
public String toString() {
return proxy.toString();
}
Expand Down Expand Up @@ -188,6 +189,7 @@ public CoroutineContext plus(@NotNull CoroutineContext coroutineContext) {
return proxy.plus(coroutineContext);
}

@Override
public String toString() {
return proxy.toString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.scalaconcurrent;
package io.opentelemetry.javaagent.instrumentation.scalaexecutors;

import static io.opentelemetry.javaagent.instrumentation.scalaconcurrent.ScalaForkJoinTaskInstrumentation.TASK_CLASS_NAME;
import static io.opentelemetry.javaagent.instrumentation.scalaexecutors.ScalaForkJoinTaskInstrumentation.TASK_CLASS_NAME;
import static java.util.Arrays.asList;

import com.google.auto.service.AutoService;
Expand All @@ -21,7 +21,7 @@
@AutoService(InstrumentationModule.class)
public class ScalaConcurrentInstrumentationModule extends InstrumentationModule {
public ScalaConcurrentInstrumentationModule() {
super("scala-concurrent");
super("scala-executors");
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.scalaconcurrent;
package io.opentelemetry.javaagent.instrumentation.scalaexecutors;

import static net.bytebuddy.matcher.ElementMatchers.nameMatches;
import static net.bytebuddy.matcher.ElementMatchers.named;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.javaagent.instrumentation.scalaconcurrent;
package io.opentelemetry.javaagent.instrumentation.scalaexecutors;

import static io.opentelemetry.javaagent.tooling.ClassLoaderMatcher.hasClassesNamed;
import static io.opentelemetry.javaagent.tooling.bytebuddy.matcher.AgentElementMatchers.extendsClass;
Expand Down
6 changes: 3 additions & 3 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ include ':utils:test-utils'
// smoke tests
include ':smoke-tests'

include ':instrumentation:akka-context-propagation-2.5'
include ':instrumentation:akka-actor-2.5'
include ':instrumentation:akka-http-10.0'
include ':instrumentation:apache-camel-2.20'
include ':instrumentation:apache-httpasyncclient-4.0'
Expand Down Expand Up @@ -125,7 +125,7 @@ include ':instrumentation:jsp-2.3'
include ':instrumentation:kafka-clients-0.11'
include ':instrumentation:kafka-streams-0.11'
include ':instrumentation:khttp-0.1'
include ':instrumentation:kotlin-coroutines'
include ':instrumentation:kotlinx-coroutines'
include ':instrumentation:kubernetes-client-7.0'
include ':instrumentation:lettuce:lettuce-common'
include ':instrumentation:lettuce:lettuce-4.0'
Expand Down Expand Up @@ -169,7 +169,7 @@ include ':instrumentation:redisson-3.0'
include ':instrumentation:rmi'
include ':instrumentation:rxjava-1.0'
include ':instrumentation:rxjava-1.0'
include ':instrumentation:scala-concurrent'
include ':instrumentation:scala-executors'
include ':instrumentation:servlet:glassfish-testing'
include ':instrumentation:servlet:servlet-common'
include ':instrumentation:servlet:servlet-2.2'
Expand Down