From 136a68b6c2cd20ed8a8476e4e64c3907ede2bd48 Mon Sep 17 00:00:00 2001 From: Jason Plumb Date: Fri, 13 Oct 2023 10:41:36 -0700 Subject: [PATCH] spotless --- .../java/com/splunk/rum/SplunkSpanDataModifier.java | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/splunk-otel-android/src/main/java/com/splunk/rum/SplunkSpanDataModifier.java b/splunk-otel-android/src/main/java/com/splunk/rum/SplunkSpanDataModifier.java index 5f7ffb78..57184ddf 100644 --- a/splunk-otel-android/src/main/java/com/splunk/rum/SplunkSpanDataModifier.java +++ b/splunk-otel-android/src/main/java/com/splunk/rum/SplunkSpanDataModifier.java @@ -116,7 +116,8 @@ private SpanData modify(SpanData original) { } // Convert new net semconv to old - modifiedAttributes = downgradeNetworkAttrNames(original.getAttributes(), modifiedAttributes); + modifiedAttributes = + downgradeNetworkAttrNames(original.getAttributes(), modifiedAttributes); // zipkin eats the event attributes that are recorded by default, so we need to convert // the exception event to span attributes @@ -145,8 +146,8 @@ private SpanData modify(SpanData original) { } // At least until we can leverage the new names... - private AttributesBuilder downgradeNetworkAttrNames(Attributes originalAttributes, - AttributesBuilder attributes) { + private AttributesBuilder downgradeNetworkAttrNames( + Attributes originalAttributes, AttributesBuilder attributes) { return AttributeReplacer.with(originalAttributes, attributes) .update(NETWORK_CONNECTION_TYPE, NET_HOST_CONNECTION_TYPE) .update(NETWORK_CONNECTION_SUBTYPE, NET_HOST_CONNECTION_SUBTYPE) @@ -272,16 +273,16 @@ private AttributeReplacer(Attributes original, AttributesBuilder attributes) { this.attributes = attributes; } - AttributeReplacer update(AttributeKey currentName, AttributeKey replacementName){ + AttributeReplacer update(AttributeKey currentName, AttributeKey replacementName) { T value = original.get(currentName); - if(value != null){ + if (value != null) { attributes.remove(currentName); attributes.put(replacementName, value); } return this; } - AttributesBuilder finish(){ + AttributesBuilder finish() { return attributes; } }