You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by sp...@apache.org on 2015/10/22 14:19:44 UTC
[04/15] incubator-tinkerpop git commit: add netty epoll dependency
and fix the initiation checker
add netty epoll dependency and fix the initiation checker
Project: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/commit/30b16887
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/tree/30b16887
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/diff/30b16887
Branch: refs/heads/master
Commit: 30b16887bfd2c100edd857f6f1ffd9f4e81f61a2
Parents: 6ab524f
Author: ashishn <as...@yahoo-inc.com>
Authored: Fri Oct 16 09:57:37 2015 -0700
Committer: ashishn <as...@yahoo-inc.com>
Committed: Fri Oct 16 09:57:37 2015 -0700
----------------------------------------------------------------------
gremlin-driver/pom.xml | 5 +++++
.../tinkerpop/gremlin/server/GremlinServer.java | 16 ++++------------
2 files changed, 9 insertions(+), 12 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/30b16887/gremlin-driver/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-driver/pom.xml b/gremlin-driver/pom.xml
index bdf2af6..e728cd4 100644
--- a/gremlin-driver/pom.xml
+++ b/gremlin-driver/pom.xml
@@ -40,6 +40,11 @@ limitations under the License.
<version>${netty.version}</version>
</dependency>
<dependency>
+ <groupId>io.netty</groupId>
+ <artifactId>netty-transport-native-epoll</artifactId>
+ <version>${netty.version}</version>
+ </dependency>
+ <dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${groovy.version}</version>
http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/30b16887/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/GremlinServer.java
----------------------------------------------------------------------
diff --git a/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/GremlinServer.java b/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/GremlinServer.java
index 8493cee..ac91c86 100644
--- a/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/GremlinServer.java
+++ b/gremlin-server/src/main/java/org/apache/tinkerpop/gremlin/server/GremlinServer.java
@@ -20,11 +20,7 @@ package org.apache.tinkerpop.gremlin.server;
import io.netty.bootstrap.ServerBootstrap;
import io.netty.buffer.PooledByteBufAllocator;
-import io.netty.channel.Channel;
-import io.netty.channel.ChannelFuture;
-import io.netty.channel.ChannelFutureListener;
-import io.netty.channel.ChannelOption;
-import io.netty.channel.EventLoopGroup;
+import io.netty.channel.*;
import io.netty.channel.epoll.EpollEventLoopGroup;
import io.netty.channel.epoll.EpollServerSocketChannel;
import io.netty.channel.nio.NioEventLoopGroup;
@@ -43,11 +39,7 @@ import org.slf4j.LoggerFactory;
import java.io.IOException;
import java.lang.reflect.UndeclaredThrowableException;
-import java.util.concurrent.CompletableFuture;
-import java.util.concurrent.CountDownLatch;
-import java.util.concurrent.ExecutorService;
-import java.util.concurrent.ThreadFactory;
-import java.util.concurrent.TimeUnit;
+import java.util.concurrent.*;
/**
* Start and stop Gremlin Server.
@@ -165,9 +157,9 @@ public class GremlinServer {
b.group(bossGroup, workerGroup)
.childHandler(channelizer);
if(isLinuxOS){
- b.channel(NioServerSocketChannel.class);
- } else{
b.channel(EpollServerSocketChannel.class);
+ } else{
+ b.channel(NioServerSocketChannel.class);
}
// bind to host/port and wait for channel to be ready