Skip to content

Commit

Permalink
update semconv
Browse files Browse the repository at this point in the history
  • Loading branch information
breedx-splk committed Aug 12, 2024
1 parent eefb41e commit b0d4fa1
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

public class DemoWorker extends Worker {

private Context context;
private final Context context;
public static final String TAG = "SplunkRum";

public DemoWorker(@NonNull Context context, @NonNull WorkerParameters params) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@
import io.opentelemetry.sdk.testing.junit4.OpenTelemetryRule;
import io.opentelemetry.sdk.trace.data.SpanData;
import io.opentelemetry.semconv.ExceptionAttributes;
import io.opentelemetry.semconv.SemanticAttributes;
import io.opentelemetry.semconv.incubating.ExceptionIncubatingAttributes;

import java.util.List;
import java.util.concurrent.TimeUnit;
import org.junit.After;
Expand Down Expand Up @@ -84,7 +81,8 @@ public void spanDecoration_error() {
a ->
assertThat(a)
.containsEntry(
ExceptionAttributes.EXCEPTION_TYPE,
ExceptionAttributes
.EXCEPTION_TYPE,
"java.lang.RuntimeException")
.containsEntry(
ExceptionAttributes
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package com.splunk.rum;

import static io.opentelemetry.semconv.HttpAttributes.HTTP_RESPONSE_STATUS_CODE;
import static io.opentelemetry.semconv.SemanticAttributes.HTTP_RESPONSE_BODY_SIZE;
import static io.opentelemetry.semconv.incubating.HttpIncubatingAttributes.HTTP_RESPONSE_BODY_SIZE;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.assertThatThrownBy;
import static org.assertj.core.api.Fail.fail;
Expand All @@ -37,12 +37,8 @@
import io.opentelemetry.sdk.trace.data.SpanData;
import io.opentelemetry.sdk.trace.data.StatusData;
import io.opentelemetry.semconv.HttpAttributes;
import io.opentelemetry.semconv.NetworkAttributes;
import io.opentelemetry.semconv.SemanticAttributes;
import io.opentelemetry.semconv.ServerAttributes;
import io.opentelemetry.semconv.UrlAttributes;
import io.opentelemetry.semconv.incubating.HttpIncubatingAttributes;

import java.io.IOException;
import java.net.ServerSocket;
import java.net.URL;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

package com.splunk.rum;

import static io.opentelemetry.semconv.SemanticAttributes.HTTP_RESPONSE_BODY_SIZE;
import static io.opentelemetry.semconv.incubating.HttpIncubatingAttributes.HTTP_RESPONSE_BODY_SIZE;
import static org.assertj.core.api.Assertions.assertThat;
import static org.mockito.Mockito.mock;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
*/
class SplunkScreenNameExtractor implements ScreenNameExtractor {

static ScreenNameExtractor INSTANCE = new SplunkScreenNameExtractor();
static final ScreenNameExtractor INSTANCE = new SplunkScreenNameExtractor();

private SplunkScreenNameExtractor() {}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,9 @@
import io.opentelemetry.sdk.trace.data.EventData;
import io.opentelemetry.sdk.trace.data.SpanData;
import io.opentelemetry.sdk.trace.export.SpanExporter;
import io.opentelemetry.semconv.ResourceAttributes;
import io.opentelemetry.semconv.SemanticAttributes;
import io.opentelemetry.semconv.incubating.DeploymentIncubatingAttributes;
import io.opentelemetry.semconv.incubating.DeviceIncubatingAttributes;
import io.opentelemetry.semconv.incubating.OsIncubatingAttributes;

import java.util.ArrayList;
import java.util.Collection;
import java.util.HashSet;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public final class StandardAttributes {
*/
public static final AttributeKey<String> APP_VERSION = stringKey("app.version");

public final static String EXCEPTION_EVENT_NAME = "exception";
public static final String EXCEPTION_EVENT_NAME = "exception";

/**
* The build type of your app (typically one of debug or release). Useful for adding to global
Expand Down

0 comments on commit b0d4fa1

Please sign in to comment.