tinkerpop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From spmalle...@apache.org
Subject [1/2] incubator-tinkerpop git commit: Moved metrics init to Gremlin Server constructor.
Date Mon, 06 Jun 2016 20:18:40 GMT
Repository: incubator-tinkerpop
Updated Branches:
  refs/heads/master 55eb1e642 -> 406956db5


Moved metrics init to Gremlin Server constructor.

By moving it to the constructor, the metric init does not get bypassed if programmatically
starting Gremlin Server. CTR


Project: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/commit/f7e7df09
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/tree/f7e7df09
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/diff/f7e7df09

Branch: refs/heads/master
Commit: f7e7df093af7a488e52dd96440c25d08c29dfe73
Parents: 6e17d66
Author: Stephen Mallette <spmva@genoprime.com>
Authored: Mon Jun 6 16:16:39 2016 -0400
Committer: Stephen Mallette <spmva@genoprime.com>
Committed: Mon Jun 6 16:16:39 2016 -0400

----------------------------------------------------------------------
 .../java/org/apache/tinkerpop/gremlin/server/GremlinServer.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/f7e7df09/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 49b2375..49ce3bc 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
@@ -80,6 +80,7 @@ public class GremlinServer {
      * Construct a Gremlin Server instance from {@link Settings}.
      */
     public GremlinServer(final Settings settings) {
+        settings.optionalMetrics().ifPresent(GremlinServer::configureMetrics);
         this.settings = settings;
         this.isEpollEnabled = settings.useEpollEventLoop && SystemUtils.IS_OS_LINUX;
         if(settings.useEpollEventLoop && !SystemUtils.IS_OS_LINUX){
@@ -341,7 +342,6 @@ public class GremlinServer {
         }
 
         logger.info("Configuring Gremlin Server from {}", file);
-        settings.optionalMetrics().ifPresent(GremlinServer::configureMetrics);
         final GremlinServer server = new GremlinServer(settings);
         server.start().exceptionally(t -> {
             logger.error("Gremlin Server was unable to start and will now begin shutdown:
{}", t.getMessage());


Mime
View raw message