You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by ud...@apache.org on 2017/06/09 20:14:00 UTC
[26/27] geode git commit: GEODE-3023: spotless
GEODE-3023: spotless
Project: http://git-wip-us.apache.org/repos/asf/geode/repo
Commit: http://git-wip-us.apache.org/repos/asf/geode/commit/eee15376
Tree: http://git-wip-us.apache.org/repos/asf/geode/tree/eee15376
Diff: http://git-wip-us.apache.org/repos/asf/geode/diff/eee15376
Branch: refs/heads/feature/GEODE-3023
Commit: eee15376a0b6d7f300a57a9580196d054778eba8
Parents: 4de5b2a
Author: Udo Kohlmeyer <uk...@pivotal.io>
Authored: Tue Jun 6 11:01:32 2017 -0700
Committer: Udo Kohlmeyer <uk...@pivotal.io>
Committed: Fri Jun 9 13:12:59 2017 -0700
----------------------------------------------------------------------
.../internal/tcpserver/TcpServer.java | 12 ++++++----
.../tcpserver/TCPServerSSLJUnitTest.java | 14 +++++-------
.../internal/tcpserver/TcpServerJUnitTest.java | 24 +++++++-------------
.../geode/internal/net/DelaySocketCreator.java | 4 +++-
4 files changed, 24 insertions(+), 30 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/geode/blob/eee15376/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
----------------------------------------------------------------------
diff --git a/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java b/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
index 06d3c66..d03a4e3 100755
--- a/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
+++ b/geode-core/src/main/java/org/apache/geode/distributed/internal/tcpserver/TcpServer.java
@@ -68,6 +68,7 @@ import javax.net.ssl.SSLException;
* <p>
* This code was factored out of GossipServer.java to allow multiple handlers to share the same
* gossip server port.
+ *
* @since GemFire 5.7
*/
public class TcpServer {
@@ -141,8 +142,8 @@ public class TcpServer {
}
public TcpServer(int port, InetAddress bind_address, Properties sslConfig,
- DistributionConfigImpl cfg, TcpHandler handler, PoolStatHelper poolHelper,
- ThreadGroup threadGroup, String threadName) {
+ DistributionConfigImpl cfg, TcpHandler handler, PoolStatHelper poolHelper,
+ ThreadGroup threadGroup, String threadName) {
this.port = port;
this.bind_address = bind_address;
this.handler = handler;
@@ -173,7 +174,7 @@ public class TcpServer {
}
private static PooledExecutorWithDMStats createExecutor(PoolStatHelper poolHelper,
- final ThreadGroup threadGroup) {
+ final ThreadGroup threadGroup) {
ThreadFactory factory = new ThreadFactory() {
private final AtomicInteger threadNum = new AtomicInteger();
@@ -190,7 +191,7 @@ public class TcpServer {
}
public void restarting(InternalDistributedSystem ds, InternalCache cache,
- ClusterConfigurationService sharedConfig) throws IOException {
+ ClusterConfigurationService sharedConfig) throws IOException {
this.shuttingDown = false;
this.handler.restarting(ds, cache, sharedConfig);
startServerThread();
@@ -262,6 +263,7 @@ public class TcpServer {
/**
* Returns the value of the bound port. If the server was initialized with a port of 0 indicating
* that any ephemeral port should be used, this method will return the actual bound port.
+ *
* @return the locator's tcp/ip port. This will be zero if the locator hasn't been started.
*/
public int getPort() {
@@ -510,7 +512,7 @@ public class TcpServer {
/**
* Returns GossipVersion for older Gemfire versions.
- *
+ *
* @return gossip version
*/
public static int getGossipVersionForOrdinal(short ordinal) {
http://git-wip-us.apache.org/repos/asf/geode/blob/eee15376/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TCPServerSSLJUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TCPServerSSLJUnitTest.java b/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TCPServerSSLJUnitTest.java
index 138fc9d..fbec1bc 100644
--- a/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TCPServerSSLJUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TCPServerSSLJUnitTest.java
@@ -94,7 +94,7 @@ public class TCPServerSSLJUnitTest {
createTcpClientConnection();
- } catch (LocatorCancelException e){
+ } catch (LocatorCancelException e) {
// we catching the LocatorCancelException. Expected to have the exception thrown
caughtLocatorException = true;
}
@@ -110,8 +110,8 @@ public class TCPServerSSLJUnitTest {
private Properties getSSLConfigurationProperties() {
Properties sslProperties = new Properties();
- sslProperties
- .setProperty(SSL_ENABLED_COMPONENTS, SecurableCommunicationChannel.LOCATOR.getConstant());
+ sslProperties.setProperty(SSL_ENABLED_COMPONENTS,
+ SecurableCommunicationChannel.LOCATOR.getConstant());
sslProperties.setProperty(SSL_KEYSTORE,
TestUtil.getResourcePath(getClass(), "/org/apache/geode/internal/net/multiKey.jks"));
sslProperties.setProperty(SSL_TRUSTSTORE,
@@ -139,9 +139,8 @@ public class TCPServerSSLJUnitTest {
private List<Integer> recordedSocketsTimeouts = new ArrayList<>();
public DummyTcpServer(int port, InetAddress bind_address, Properties sslConfig,
- DistributionConfigImpl cfg,
- TcpHandler handler,
- PoolStatHelper poolHelper, ThreadGroup threadGroup, String threadName) {
+ DistributionConfigImpl cfg, TcpHandler handler, PoolStatHelper poolHelper,
+ ThreadGroup threadGroup, String threadName) {
super(port, bind_address, sslConfig, cfg, handler, poolHelper, threadGroup, threadName);
if (cfg == null) {
cfg = new DistributionConfigImpl(sslConfig);
@@ -153,8 +152,7 @@ public class TCPServerSSLJUnitTest {
protected SocketCreator getSocketCreator() {
if (this.socketCreator == null) {
SSLConfigurationFactory.setDistributionConfig(distributionConfig);
- SSLConfig
- sslConfig =
+ SSLConfig sslConfig =
SSLConfigurationFactory.getSSLConfigForComponent(SecurableCommunicationChannel.LOCATOR);
this.socketCreator = new DummySocketCreator(sslConfig, recordedSocketsTimeouts);
}
http://git-wip-us.apache.org/repos/asf/geode/blob/eee15376/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java b/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
index 05fc302..eda0641 100644
--- a/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
+++ b/geode-core/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
@@ -181,14 +181,11 @@ public class TcpServerJUnitTest {
}
public void restarting(DistributedSystem ds, GemFireCache cache,
- ClusterConfigurationService sharedConfig) {
- }
+ ClusterConfigurationService sharedConfig) {}
- public void endRequest(Object request, long startTime) {
- }
+ public void endRequest(Object request, long startTime) {}
- public void endResponse(Object request, long startTime) {
- }
+ public void endResponse(Object request, long startTime) {}
}
@@ -200,8 +197,7 @@ public class TcpServerJUnitTest {
this.latch = latch;
}
- public void init(TcpServer tcpServer) {
- }
+ public void init(TcpServer tcpServer) {}
public Object processRequest(Object request) throws IOException {
Boolean delay = (Boolean) request;
@@ -215,18 +211,14 @@ public class TcpServerJUnitTest {
return delay;
}
- public void shutDown() {
- }
+ public void shutDown() {}
public void restarting(DistributedSystem ds, GemFireCache cache,
- ClusterConfigurationService sharedConfig) {
- }
+ ClusterConfigurationService sharedConfig) {}
- public void endRequest(Object request, long startTime) {
- }
+ public void endRequest(Object request, long startTime) {}
- public void endResponse(Object request, long startTime) {
- }
+ public void endResponse(Object request, long startTime) {}
}
private/* GemStoneAddition */ static class SimpleStats implements PoolStatHelper {
http://git-wip-us.apache.org/repos/asf/geode/blob/eee15376/geode-core/src/test/java/org/apache/geode/internal/net/DelaySocketCreator.java
----------------------------------------------------------------------
diff --git a/geode-core/src/test/java/org/apache/geode/internal/net/DelaySocketCreator.java b/geode-core/src/test/java/org/apache/geode/internal/net/DelaySocketCreator.java
index 7daebbb..bfff90b 100644
--- a/geode-core/src/test/java/org/apache/geode/internal/net/DelaySocketCreator.java
+++ b/geode-core/src/test/java/org/apache/geode/internal/net/DelaySocketCreator.java
@@ -39,5 +39,7 @@ public class DelaySocketCreator extends SocketCreator {
throw new SSLException("This is a test SSLException");
}
- public List<Integer> getSocketSoTimeouts() { return socketSoTimeouts; }
+ public List<Integer> getSocketSoTimeouts() {
+ return socketSoTimeouts;
+ }
}