tinkerpop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From spmalle...@apache.org
Subject [01/48] tinkerpop git commit: Made a number of changes to logging dependencies.
Date Mon, 22 Aug 2016 20:39:46 GMT
Repository: tinkerpop
Updated Branches:
  refs/heads/TINKERPOP-1278 fb8c25c16 -> 67b4d1133


Made a number of changes to logging dependencies.

Log4j is now generally a test dependency except for gremlin-server and gremlin-console where
they need to be shipped as part of the binary distribution. In that case, they are optional
scope for those who for some reason depend on those libs.


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

Branch: refs/heads/TINKERPOP-1278
Commit: d0606ec25c632f15fc0dec57408d14eaf709c7e6
Parents: 19d2eee
Author: Stephen Mallette <spmva@genoprime.com>
Authored: Thu Aug 4 12:26:43 2016 -0400
Committer: Stephen Mallette <spmva@genoprime.com>
Committed: Mon Aug 8 07:59:01 2016 -0400

----------------------------------------------------------------------
 CHANGELOG.asciidoc                              |  1 +
 .../upgrade/release-3.2.x-incubating.asciidoc   | 40 +++++++++
 .../main/resources/archetype-resources/pom.xml  |  5 ++
 gremlin-console/pom.xml                         | 11 +++
 gremlin-core/pom.xml                            |  8 +-
 gremlin-driver/pom.xml                          |  6 ++
 gremlin-groovy/pom.xml                          |  7 ++
 gremlin-server/pom.xml                          | 11 +++
 .../gremlin/util/Log4jRecordingAppender.java    | 66 +++++++++++++++
 .../util/Log4jRecordingAppenderTest.java        | 86 ++++++++++++++++++++
 gremlin-test/pom.xml                            |  6 ++
 .../gremlin/util/Log4jRecordingAppender.java    | 66 ---------------
 .../util/Log4jRecordingAppenderTest.java        | 80 ------------------
 pom.xml                                         |  5 ++
 14 files changed, 251 insertions(+), 147 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/CHANGELOG.asciidoc
----------------------------------------------------------------------
diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc
index c5850ba..8f5d7dc 100644
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@ -26,6 +26,7 @@ image::https://raw.githubusercontent.com/apache/tinkerpop/master/docs/static/ima
 TinkerPop 3.2.2 (NOT OFFICIALLY RELEASED YET)
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
+* Changed scope of log4j dependencies so that they would only be used in tests and the binary
distributions of Gremlin Console and Server.
 * Added new recipe for "Traversal Induced Values".
 * Fixed a potential leak of a `ReferenceCounted` resource in Gremlin Server.
 * Added class registrations for `Map.Entry` implementations to `GryoMapper`.

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/docs/src/upgrade/release-3.2.x-incubating.asciidoc
----------------------------------------------------------------------
diff --git a/docs/src/upgrade/release-3.2.x-incubating.asciidoc b/docs/src/upgrade/release-3.2.x-incubating.asciidoc
index f85012c..60092dc 100644
--- a/docs/src/upgrade/release-3.2.x-incubating.asciidoc
+++ b/docs/src/upgrade/release-3.2.x-incubating.asciidoc
@@ -22,6 +22,46 @@ image::https://raw.githubusercontent.com/apache/tinkerpop/master/docs/static/ima
 
 *Nine Inch Gremlins*
 
+TinkerPop 3.2.2
+---------------
+
+*Release Date: NOT OFFICIALLY RELEASED YET*
+
+Please see the link:https://github.com/apache/tinkerpop/blob/3.2.2/CHANGELOG.asciidoc#release-3-2-2[changelog]
for a complete list of all the modifications that are part of this release.
+
+Upgrading for Users
+~~~~~~~~~~~~~~~~~~~
+
+Log4j Dependencies
+^^^^^^^^^^^^^^^^^^
+
+There were a number of changes to the Log4j dependencies in the various modules. Log4j was
formerly included as part
+of the `slf4j-log4j12` in `gremlin-core`, however that "forced" use of Log4j as a logger
implementation when that
+really wasn't necessary or desired. If a project depended on `gremlin-core` or other TinkerPop
project to get its
+Log4j implementation then those applications will need to now include the dependency themselves
directly.
+
+Note that Gremlin Server and Gremlin Console explicitly package Log4j in their respective
binary distributions.
+
+See: link:https://issues.apache.org/jira/browse/TINKERPOP-1151[TINKERPOP-1151]
+
+Upgrading for Providers
+~~~~~~~~~~~~~~~~~~~~~~~
+
+Graph System Providers
+^^^^^^^^^^^^^^^^^^^^^^
+
+Log4j Dependencies
+++++++++++++++++++
+
+There were a number of changes to the Log4j dependencies in the various modules. Log4j was
formerly included as part
+of the `slf4j-log4j12` in `gremlin-core`, however that "forced" use of log4j as a logger
implementation when that
+really wasn't necessary or desired. The `slf4j-log4j12` dependency is now in "test" scope
for most of the modules. The
+exception to that rule is `gremlin-test` which prescribes it as "optional". That change means
that developers
+dependending on `gremlin-test` (or `gremlin-groovy-test`) will need to explicitly specify
it as a dependency in their
+`pom.xml` (or a different slf4j implementation if that better suits them).
+
+See: link:https://issues.apache.org/jira/browse/TINKERPOP-1151[TINKERPOP-1151]
+
 TinkerPop 3.2.1
 ---------------
 

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-archetype/gremlin-archetype-tinkergraph/src/main/resources/archetype-resources/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-archetype/gremlin-archetype-tinkergraph/src/main/resources/archetype-resources/pom.xml
b/gremlin-archetype/gremlin-archetype-tinkergraph/src/main/resources/archetype-resources/pom.xml
index 271f9dd..0727319 100644
--- a/gremlin-archetype/gremlin-archetype-tinkergraph/src/main/resources/archetype-resources/pom.xml
+++ b/gremlin-archetype/gremlin-archetype-tinkergraph/src/main/resources/archetype-resources/pom.xml
@@ -35,6 +35,11 @@ limitations under the License.
             <version>${project.version}</version>
         </dependency>
         <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+        </dependency>
+        <dependency>
             <groupId>junit</groupId>
             <artifactId>junit</artifactId>
             <version>4.12</version>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-console/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-console/pom.xml b/gremlin-console/pom.xml
index cbbab3e..b1c5b56 100644
--- a/gremlin-console/pom.xml
+++ b/gremlin-console/pom.xml
@@ -61,6 +61,17 @@ limitations under the License.
             <artifactId>gprof</artifactId>
             <version>0.3.1-groovy-2.4</version>
         </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>optional</scope>
+        </dependency>
+        <dependency>
+            <groupId>log4j</groupId>
+            <artifactId>log4j</artifactId>
+            <scope>optional</scope>
+        </dependency>
         <!-- TESTING -->
         <dependency>
             <groupId>junit</groupId>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-core/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-core/pom.xml b/gremlin-core/pom.xml
index 5f246f2..4accd63 100644
--- a/gremlin-core/pom.xml
+++ b/gremlin-core/pom.xml
@@ -64,7 +64,7 @@ limitations under the License.
         <!-- LOGGING -->
         <dependency>
             <groupId>org.slf4j</groupId>
-            <artifactId>slf4j-log4j12</artifactId>
+            <artifactId>slf4j-api</artifactId>
             <version>${slf4j.version}</version>
         </dependency>
         <dependency>
@@ -80,6 +80,12 @@ limitations under the License.
             <scope>test</scope>
         </dependency>
         <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
             <groupId>org.mockito</groupId>
             <artifactId>mockito-all</artifactId>
             <version>1.9.5</version>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-driver/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-driver/pom.xml b/gremlin-driver/pom.xml
index 2d5aa93..beeddf7 100644
--- a/gremlin-driver/pom.xml
+++ b/gremlin-driver/pom.xml
@@ -69,6 +69,12 @@ limitations under the License.
             <scope>test</scope>
         </dependency>
         <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
             <groupId>org.apache.tinkerpop</groupId>
             <artifactId>tinkergraph-gremlin</artifactId>
             <version>${project.version}</version>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-groovy/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-groovy/pom.xml b/gremlin-groovy/pom.xml
index 3e37e17..8a12f10 100644
--- a/gremlin-groovy/pom.xml
+++ b/gremlin-groovy/pom.xml
@@ -70,6 +70,13 @@ limitations under the License.
             <artifactId>jBCrypt</artifactId>
             <version>jbcrypt-0.4</version>
         </dependency>
+        <!-- TEST -->
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>test</scope>
+        </dependency>
         <dependency>
             <groupId>org.apache.tinkerpop</groupId>
             <artifactId>gremlin-test</artifactId>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-server/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-server/pom.xml b/gremlin-server/pom.xml
index 2e7fc35..9a9c077 100644
--- a/gremlin-server/pom.xml
+++ b/gremlin-server/pom.xml
@@ -45,6 +45,17 @@ limitations under the License.
             <groupId>commons-collections</groupId>
             <artifactId>commons-collections</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>optional</scope>
+        </dependency>
+        <dependency>
+            <groupId>log4j</groupId>
+            <artifactId>log4j</artifactId>
+            <scope>optional</scope>
+        </dependency>
         <!-- METRICS -->
         <dependency>
             <groupId>com.codahale.metrics</groupId>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
----------------------------------------------------------------------
diff --git a/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
new file mode 100644
index 0000000..e44f72f
--- /dev/null
+++ b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tinkerpop.gremlin.util;
+
+import org.apache.log4j.AppenderSkeleton;
+import org.apache.log4j.PatternLayout;
+import org.apache.log4j.spi.LoggingEvent;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Provides a way to gather logging events for purpose of testing log output.
+ *
+ * @author Stephen Mallette (http://stephen.genoprime.com)
+ */
+public class Log4jRecordingAppender extends AppenderSkeleton {
+    private final List<String> messages = new ArrayList<>();
+
+    public Log4jRecordingAppender() {
+        super();
+        setLayout(new PatternLayout("%p - %m%n"));
+    }
+
+    @Override
+    protected void append(final LoggingEvent event) {
+        messages.add(layout.format(event));
+    }
+
+    @Override
+    public void close() {
+    }
+
+    @Override
+    public boolean requiresLayout() {
+        return true;
+    }
+
+    public List<String> getMessages() {
+        return messages;
+    }
+
+    public void clear() {
+        messages.clear();
+    }
+
+    public boolean logContainsAny(final String fragment) {
+        return messages.stream().anyMatch(m -> m.contains(fragment));
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
----------------------------------------------------------------------
diff --git a/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
new file mode 100644
index 0000000..dd1ea63
--- /dev/null
+++ b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
@@ -0,0 +1,86 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tinkerpop.gremlin.util;
+
+import org.apache.log4j.Level;
+import org.apache.log4j.Logger;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.slf4j.LoggerFactory;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+
+/**
+ * @author Stephen Mallette (http://stephen.genoprime.com)
+ */
+public class Log4jRecordingAppenderTest {
+    private static final org.slf4j.Logger logger = LoggerFactory.getLogger(Log4jRecordingAppenderTest.class);
+    private Log4jRecordingAppender recordingAppender = null;
+    private static final String lineSeparator = System.getProperty("line.separator");
+
+    private Level originalConfiguredLevel = null;
+
+    @Before
+    public void setupForEachTest() {
+        recordingAppender = new Log4jRecordingAppender();
+        final Logger rootLogger = Logger.getRootLogger();
+        if (null == originalConfiguredLevel) originalConfiguredLevel = rootLogger.getLevel();
+        rootLogger.addAppender(recordingAppender);
+        rootLogger.setLevel(Level.ALL);
+
+        logger.error("ERROR");
+        logger.warn("WARN");
+        logger.info("INFO");
+    }
+
+    @After
+    public void teardownForEachTest() {
+        final Logger rootLogger = Logger.getRootLogger();
+        rootLogger.removeAppender(recordingAppender);
+        rootLogger.setLevel(originalConfiguredLevel);
+    }
+
+    @Test
+    public void shouldRecordMessages() {
+        assertEquals(3, recordingAppender.getMessages().size());
+        assertEquals("ERROR - ERROR" + lineSeparator, recordingAppender.getMessages().get(0));
+        assertEquals("WARN - WARN"  + lineSeparator, recordingAppender.getMessages().get(1));
+        assertEquals("INFO - INFO" + lineSeparator, recordingAppender.getMessages().get(2));
+    }
+
+    @Test
+    public void shouldMatchAnyMessages() {
+        assertTrue(recordingAppender.logContainsAny("ERROR"));
+    }
+
+    @Test
+    public void shouldMatchNoMessages() {
+        assertFalse(recordingAppender.logContainsAny("this is not here"));
+    }
+
+    @Test
+    public void shouldClearMessages() {
+        assertEquals(3, recordingAppender.getMessages().size());
+        recordingAppender.clear();
+        assertEquals(0, recordingAppender.getMessages().size());
+    }
+}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-test/pom.xml
----------------------------------------------------------------------
diff --git a/gremlin-test/pom.xml b/gremlin-test/pom.xml
index 09f3a3f..28df2e8 100644
--- a/gremlin-test/pom.xml
+++ b/gremlin-test/pom.xml
@@ -74,6 +74,12 @@ limitations under the License.
             <artifactId>hamcrest-all</artifactId>
             <version>1.3</version>
         </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-log4j12</artifactId>
+            <version>${slf4j.version}</version>
+            <scope>optional</scope>
+        </dependency>
     </dependencies>
     <build>
         <directory>${basedir}/target</directory>

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
deleted file mode 100644
index e44f72f..0000000
--- a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppender.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.tinkerpop.gremlin.util;
-
-import org.apache.log4j.AppenderSkeleton;
-import org.apache.log4j.PatternLayout;
-import org.apache.log4j.spi.LoggingEvent;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Provides a way to gather logging events for purpose of testing log output.
- *
- * @author Stephen Mallette (http://stephen.genoprime.com)
- */
-public class Log4jRecordingAppender extends AppenderSkeleton {
-    private final List<String> messages = new ArrayList<>();
-
-    public Log4jRecordingAppender() {
-        super();
-        setLayout(new PatternLayout("%p - %m%n"));
-    }
-
-    @Override
-    protected void append(final LoggingEvent event) {
-        messages.add(layout.format(event));
-    }
-
-    @Override
-    public void close() {
-    }
-
-    @Override
-    public boolean requiresLayout() {
-        return true;
-    }
-
-    public List<String> getMessages() {
-        return messages;
-    }
-
-    public void clear() {
-        messages.clear();
-    }
-
-    public boolean logContainsAny(final String fragment) {
-        return messages.stream().anyMatch(m -> m.contains(fragment));
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/gremlin-test/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
----------------------------------------------------------------------
diff --git a/gremlin-test/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
b/gremlin-test/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
deleted file mode 100644
index 92eb38b..0000000
--- a/gremlin-test/src/test/java/org/apache/tinkerpop/gremlin/util/Log4jRecordingAppenderTest.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.tinkerpop.gremlin.util;
-
-import org.apache.log4j.Logger;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.slf4j.LoggerFactory;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
-
-/**
- * @author Stephen Mallette (http://stephen.genoprime.com)
- */
-public class Log4jRecordingAppenderTest {
-    private static final org.slf4j.Logger logger = LoggerFactory.getLogger(Log4jRecordingAppenderTest.class);
-    private Log4jRecordingAppender recordingAppender = null;
-    private static final String lineSeparator = System.getProperty("line.separator");
-
-    @Before
-    public void setupForEachTest() {
-        recordingAppender = new Log4jRecordingAppender();
-        final Logger rootLogger = Logger.getRootLogger();
-        rootLogger.addAppender(recordingAppender);
-
-        logger.error("ERROR");
-        logger.warn("WARN");
-        logger.info("INFO");
-    }
-
-    @After
-    public void teardownForEachTest() {
-        final Logger rootLogger = Logger.getRootLogger();
-        rootLogger.removeAppender(recordingAppender);
-    }
-
-    @Test
-    public void shouldRecordMessages() {
-        assertEquals(3, recordingAppender.getMessages().size());
-        assertEquals("ERROR - ERROR" + lineSeparator, recordingAppender.getMessages().get(0));
-        assertEquals("WARN - WARN"  + lineSeparator, recordingAppender.getMessages().get(1));
-        assertEquals("INFO - INFO" + lineSeparator, recordingAppender.getMessages().get(2));
-    }
-
-    @Test
-    public void shouldMatchAnyMessages() {
-        assertTrue(recordingAppender.logContainsAny("ERROR"));
-    }
-
-    @Test
-    public void shouldMatchNoMessages() {
-        assertFalse(recordingAppender.logContainsAny("this is not here"));
-    }
-
-    @Test
-    public void shouldClearMessages() {
-        assertEquals(3, recordingAppender.getMessages().size());
-        recordingAppender.clear();
-        assertEquals(0, recordingAppender.getMessages().size());
-    }
-}

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0606ec2/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 749c8f0..90ed55f 100644
--- a/pom.xml
+++ b/pom.xml
@@ -591,6 +591,11 @@ limitations under the License.
                     </exclusion>
                 </exclusions>
             </dependency>
+            <dependency>
+                <groupId>log4j</groupId>
+                <artifactId>log4j</artifactId>
+                <version>1.2.17</version>
+            </dependency>
         </dependencies>
     </dependencyManagement>
 


Mime
View raw message