Skip to content

Commit 0e07360

Browse files
committed
reformat
1 parent 3759efe commit 0e07360

File tree

3 files changed

+8
-10
lines changed

3 files changed

+8
-10
lines changed

jmx-scraper/src/integrationTest/java/io/opentelemetry/contrib/jmxscraper/JmxConnectionTest.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,15 @@ private static void testServerSsl(Path tempDir, boolean sslRmiRegistry) {
102102
addTrustedCertificate(clientKeystore, clientPassword, serverCertificate);
103103

104104
connectionTest(
105-
app -> (sslRmiRegistry ? app.withSslRmiRegistry(4242) : app)
106-
.withJmxPort(JMX_PORT)
107-
.withJmxSsl()
108-
.withKeyStore(serverKeystore, serverPassword),
105+
app ->
106+
(sslRmiRegistry ? app.withSslRmiRegistry(4242) : app)
107+
.withJmxPort(JMX_PORT)
108+
.withJmxSsl()
109+
.withKeyStore(serverKeystore, serverPassword),
109110
scraper ->
110111
(sslRmiRegistry ? scraper.withSslRmiRegistry() : scraper)
111112
.withRmiServiceUrl(APP_HOST, JMX_PORT)
112-
.withTrustStore(clientKeystore, clientPassword)
113-
);
113+
.withTrustStore(clientKeystore, clientPassword));
114114
}
115115

116116
private static void connectionTest(

jmx-scraper/src/integrationTest/java/io/opentelemetry/contrib/jmxscraper/TestAppContainer.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,6 @@ public void start() {
111111
}
112112
}
113113

114-
115114
if (pwd == null) {
116115
properties.put("com.sun.management.jmxremote.authenticate", "false");
117116
} else {

jmx-scraper/src/main/java/io/opentelemetry/contrib/jmxscraper/JmxConnectorBuilder.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,8 +165,8 @@ public JMXConnector doConnectSslRegistry(JMXServiceURL url, Map<String, Object>
165165
int port;
166166

167167
if (url.getURLPath().startsWith("/jndi/")) {
168-
String[] components = url.getURLPath().split("/", 3);
169-
URI uri = URI.create(components[2]);
168+
String[] components = url.getURLPath().split("/", 3);
169+
URI uri = URI.create(components[2]);
170170
hostName = uri.getHost();
171171
port = uri.getPort();
172172
} else {
@@ -181,7 +181,6 @@ public JMXConnector doConnectSslRegistry(JMXServiceURL url, Map<String, Object>
181181
} catch (IOException e) {
182182
throw new IllegalStateException("Unable to connect to " + url, e);
183183
}
184-
185184
}
186185

187186
private static JMXServiceURL buildUrl(String host, int port) {

0 commit comments

Comments
 (0)