Skip to content

Commit

Permalink
spotless apply template
Browse files Browse the repository at this point in the history
  • Loading branch information
tonzhan2 committed Jan 23, 2025
1 parent fc1eb6e commit 8b78e99
Show file tree
Hide file tree
Showing 5 changed files with 70 additions and 79 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,32 +26,36 @@
public final class VolleyTracing {

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link VolleyTracing} configured with the given {@link SplunkRum}. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link VolleyTracing} configured with the given {@link SplunkRum}.
*/
@Deprecated
public static VolleyTracing create(SplunkRum splunkRum) {
return create(splunkRum.getOpenTelemetry());
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link VolleyTracing} configured with the given {@link OpenTelemetry}. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link VolleyTracing} configured with the given {@link OpenTelemetry}.
*/
@Deprecated
public static VolleyTracing create(OpenTelemetry openTelemetry) {
return builder(openTelemetry).build();
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link VolleyTracingBuilder} configured with the given {@link SplunkRum}. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link VolleyTracingBuilder} configured with the given {@link SplunkRum}.
*/
@Deprecated
public static VolleyTracingBuilder builder(SplunkRum splunkRum) {
return new VolleyTracingBuilder(splunkRum.getOpenTelemetry());
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link VolleyTracingBuilder} configured with the given {@link OpenTelemetry}. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link VolleyTracingBuilder} configured with the given {@link OpenTelemetry}.
*/
@Deprecated
public static VolleyTracingBuilder builder(OpenTelemetry openTelemetry) {
return new VolleyTracingBuilder(openTelemetry);
Expand All @@ -60,33 +64,37 @@ public static VolleyTracingBuilder builder(OpenTelemetry openTelemetry) {
private final Instrumenter<RequestWrapper, HttpResponse> instrumenter;

/**
* @deprecated This method is deprecated and will be removed in a future release. */
* @deprecated This method is deprecated and will be removed in a future release.
*/
@Deprecated
VolleyTracing(Instrumenter<RequestWrapper, HttpResponse> instrumenter) {
this.instrumenter = instrumenter;
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link HurlStack} capable of tracing requests. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link HurlStack} capable of tracing requests.
*/
@Deprecated
public HurlStack newHurlStack() {
return new TracingHurlStack(instrumenter);
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link HurlStack} capable of tracing requests configured with given {@link
* HurlStack.UrlRewriter}. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link HurlStack} capable of tracing requests configured with given {@link
* HurlStack.UrlRewriter}.
*/
@Deprecated
public HurlStack newHurlStack(HurlStack.UrlRewriter urlRewriter) {
return new TracingHurlStack(instrumenter, urlRewriter);
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Returns a new {@link HurlStack} capable of tracing requests configured with given {@link
* HurlStack.UrlRewriter} and {@link SSLSocketFactory}. */
* @deprecated This method is deprecated and will be removed in a future release. Returns a new
* {@link HurlStack} capable of tracing requests configured with given {@link
* HurlStack.UrlRewriter} and {@link SSLSocketFactory}.
*/
@Deprecated
public HurlStack newHurlStack(
HurlStack.UrlRewriter urlRewriter, SSLSocketFactory sslSocketFactory) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,8 @@ public final class VolleyTracingBuilder {
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Adds an additional {@link AttributesExtractor} to invoke to set attributes to instrumented
* items.
* @deprecated This method is deprecated and will be removed in a future release Adds an
* additional {@link AttributesExtractor} to invoke to set attributes to instrumented items.
*/
@Deprecated
public VolleyTracingBuilder addAttributesExtractor(
Expand All @@ -60,9 +59,8 @@ public VolleyTracingBuilder addAttributesExtractor(
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Configures the HTTP request headers that will be captured as span attributes.
*
* @deprecated This method is deprecated and will be removed in a future release Configures the
* HTTP request headers that will be captured as span attributes.
* @param requestHeaders A list of HTTP header names.
*/
@Deprecated
Expand All @@ -72,9 +70,8 @@ public VolleyTracingBuilder setCapturedRequestHeaders(List<String> requestHeader
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Configures the HTTP response headers that will be captured as span attributes.
*
* @deprecated This method is deprecated and will be removed in a future release Configures the
* HTTP response headers that will be captured as span attributes.
* @param responseHeaders A list of HTTP header names.
*/
@Deprecated
Expand All @@ -84,8 +81,8 @@ public VolleyTracingBuilder setCapturedResponseHeaders(List<String> responseHead
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Returns a new {@link VolleyTracing} with the settings of this {@link VolleyTracingBuilder}.
* @deprecated This method is deprecated and will be removed in a future release Returns a new
* {@link VolleyTracing} with the settings of this {@link VolleyTracingBuilder}.
*/
@Deprecated
public VolleyTracing build() {
Expand Down
30 changes: 12 additions & 18 deletions splunk-otel-android/src/main/java/com/splunk/rum/SplunkRum.java
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,8 @@ static SplunkRum initialize(SplunkRumBuilder builder, Application application) {
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Starts a UI navigation span and remembers the last screen name.
*
* @deprecated This method is deprecated and will be removed in a future release Starts a UI
* navigation span and remembers the last screen name.
* @param screenName Name of the new screen or null when exiting explicit UI navigation mode.
* @param spanType "Created", "Restarted", or "Resumed"
*/
Expand All @@ -139,9 +138,8 @@ public void experimentalSetScreenName(String screenName, String spanType) {
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Starts a "Created" UI navigation span and remembers the last screen name.
*
* @deprecated This method is deprecated and will be removed in a future release Starts a
* "Created" UI navigation span and remembers the last screen name.
* @param screenName Name of the new screen or null when exiting explicit UI navigation mode.
*/
@Deprecated
Expand Down Expand Up @@ -175,11 +173,10 @@ public static SplunkRum noop() {
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Wrap the provided {@link OkHttpClient} with OpenTelemetry and RUM instrumentation. Since
* {@link Call.Factory} is the primary useful interface implemented by the OkHttpClient, this
* should be a drop-in replacement for any usages of OkHttpClient.
*
* @deprecated This method is deprecated and will be removed in a future release. Wrap the
* provided {@link OkHttpClient} with OpenTelemetry and RUM instrumentation. Since {@link
* Call.Factory} is the primary useful interface implemented by the OkHttpClient, this
* should be a drop-in replacement for any usages of OkHttpClient.
* @param client The {@link OkHttpClient} to wrap with OpenTelemetry and RUM instrumentation.
* @return A {@link okhttp3.Call.Factory} implementation.
*/
Expand Down Expand Up @@ -338,13 +335,10 @@ public void integrateWithBrowserRum(WebView webView) {
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* Updates the current location. The latitude and longitude will be appended to every span and
* event.
*
* <p>Note: this operation performs an atomic update. You can safely call it from your {@code
* LocationListener} or {@code LocationCallback}.
*
* @deprecated This method is deprecated and will be removed in a future release Updates the
* current location. The latitude and longitude will be appended to every span and event.
* <p>Note: this operation performs an atomic update. You can safely call it from your
* {@code LocationListener} or {@code LocationCallback}.
* @param location the current location. Passing {@code null} removes the location data.
*/
@Deprecated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,12 @@ public SplunkRumBuilder setBeaconEndpoint(String beaconEndpoint) {
}

/**
* @deprecated This method is deprecated and will be removed in a future release
* This method can be used to provide a customizer that will have access to the
* OkHttpSender.Builder before the sender is created. Typical use cases for this are to provide
* custom headers or to modify compression settings. This is a pretty large hammer and should be
* used with caution.
*
* <p>This API is considered incubating and is subject to change.
*
* @deprecated This method is deprecated and will be removed in a future release This method can
* be used to provide a customizer that will have access to the OkHttpSender.Builder before
* the sender is created. Typical use cases for this are to provide custom headers or to
* modify compression settings. This is a pretty large hammer and should be used with
* caution.
* <p>This API is considered incubating and is subject to change.
* @param customizer that can make changes to the OkHttpSender.Builder
* @return {@code this}
* @since 1.4.0
Expand Down Expand Up @@ -170,11 +168,9 @@ public SplunkRumBuilder enableDiskBuffering() {
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Enables support for the React Native instrumentation.
*
* <p>This feature is disabled by default. You can enable it by calling this method.
*
* @deprecated This method is deprecated and will be removed in a future release. Enables
* support for the React Native instrumentation.
* <p>This feature is disabled by default. You can enable it by calling this method.
* @return {@code this}
*/
@Deprecated
Expand Down Expand Up @@ -331,19 +327,17 @@ public SplunkRumBuilder enableSessionBasedSampling(double ratio) {
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Creates a new instance of {@link SplunkRum} with the settings of this {@link
* SplunkRumBuilder}.
*
* <p>You must configure at least the {@linkplain #setApplicationName(String) application name},
* the {@linkplain #setRealm(String) realm} or the {@linkplain #setBeaconEndpoint(String) beacon
* endpoint}, and the {@linkplain #setRumAccessToken(String) access token} before calling this
* method. Trying to build a {@link SplunkRum} instance without any of these will result in an
* exception being thrown.
*
* <p>The returned {@link SplunkRum} is set as the global instance {@link
* SplunkRum#getInstance()}. If there was a global {@link SplunkRum} instance configured before,
* this method does not initialize a new one and simply returns the existing instance.
* @deprecated This method is deprecated and will be removed in a future release. Creates a new
* instance of {@link SplunkRum} with the settings of this {@link SplunkRumBuilder}.
* <p>You must configure at least the {@linkplain #setApplicationName(String) application
* name}, the {@linkplain #setRealm(String) realm} or the {@linkplain
* #setBeaconEndpoint(String) beacon endpoint}, and the {@linkplain
* #setRumAccessToken(String) access token} before calling this method. Trying to build a
* {@link SplunkRum} instance without any of these will result in an exception being thrown.
* <p>The returned {@link SplunkRum} is set as the global instance {@link
* SplunkRum#getInstance()}. If there was a global {@link SplunkRum} instance configured
* before, this method does not initialize a new one and simply returns the existing
* instance.
*/
@Deprecated
public SplunkRum build(Application application) {
Expand Down Expand Up @@ -382,9 +376,8 @@ public SplunkRumBuilder enableBackgroundInstrumentationDeferredUntilForeground()
}

/**
* @deprecated This method is deprecated and will be removed in a future release.
* Enables experimental support for exporting via OTLP instead of Zipkin.
*
* @deprecated This method is deprecated and will be removed in a future release. Enables
* experimental support for exporting via OTLP instead of Zipkin.
* @return {@code this}
*/
@Deprecated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,9 @@
import zipkin2.reporter.okhttp3.OkHttpSender;

/**
* @deprecated This method is deprecated and will be removed in a future release
* This interface can be used to customize the exporter used to send telemetry to Splunk. It is not
* yet stable and its APIs are subject to change at any time.
*
* @deprecated This method is deprecated and will be removed in a future release This interface can
* be used to customize the exporter used to send telemetry to Splunk. It is not yet stable and
* its APIs are subject to change at any time.
* @since 1.4.0
*/
public interface HttpSenderCustomizer {
Expand Down

0 comments on commit 8b78e99

Please sign in to comment.