You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by sn...@apache.org on 2014/12/11 19:53:06 UTC
[03/12] incubator-usergrid git commit: Finished first pass in core
Finished first pass in core
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/bc93f693
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/bc93f693
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/bc93f693
Branch: refs/heads/two-dot-o
Commit: bc93f693a7a85c89dc59304fba825209e385ebfc
Parents: 43ed846
Author: Todd Nine <tn...@apigee.com>
Authored: Wed Dec 10 11:40:45 2014 -0700
Committer: Todd Nine <tn...@apigee.com>
Committed: Wed Dec 10 11:40:45 2014 -0700
----------------------------------------------------------------------
stack/core/pom.xml | 15 +---
.../org/apache/usergrid/AbstractCoreIT.java | 12 ++-
.../apache/usergrid/ConcurrentCoreITSuite.java | 51 ------------
.../usergrid/ConcurrentCoreIteratorITSuite.java | 83 --------------------
.../usergrid/ConcurrentCoreTestSuite.java | 46 -----------
.../java/org/apache/usergrid/CoreITSuite.java | 58 --------------
.../java/org/apache/usergrid/CoreTestSuite.java | 45 -----------
.../apache/usergrid/batch/SchedulerITSuite.java | 50 ------------
.../usergrid/batch/SchedulerTestSuite.java | 34 --------
.../batch/job/AbstractSchedulerRuntimeIT.java | 18 +++--
.../apache/usergrid/persistence/CounterIT.java | 6 +-
.../apache/usergrid/persistence/IndexIT.java | 21 ++---
.../cassandra/EntityManagerFactoryImplIT.java | 21 +++--
.../query/AbstractIteratingQueryIT.java | 15 +++-
.../system/UsergridSystemMonitorIT.java | 14 +++-
15 files changed, 76 insertions(+), 413 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/pom.xml
----------------------------------------------------------------------
diff --git a/stack/core/pom.xml b/stack/core/pom.xml
index 61ce099..e5cdae5 100644
--- a/stack/core/pom.xml
+++ b/stack/core/pom.xml
@@ -183,19 +183,10 @@
<argLine>-Xmx${ug.heapmax} -Xms${ug.heapmin} -Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8 -javaagent:${settings.localRepository}/com/github/stephenc/jamm/0.2.5/jamm-0.2.5.jar ${ug.argline}</argLine>
<includes>
- <include>**/*ConcurrentCoreITSuite.java</include>
- <include>**/SchedulerTestSuite.java</include>
- <include>**/SchedulerRuntime*IT.java</include>
+ <include>**/*IT.java</include>
+ <include>**/*Test.java</include>
</includes>
- <excludes>
- <exclude>**/*IT.java</exclude>
- <exclude>**/*Test.java</exclude>
- <exclude>**/CoreITSuite.java</exclude>
- <exclude>**/CoreTestSuite.java</exclude>
- <exclude>**/ConcurrentSchedulerITSuite.java</exclude>
- <exclude>**/ConcurrentSchedulerTestSuite.java</exclude>
- <exclude>**/*Test.java</exclude>
- </excludes>
+
</configuration>
<version>2.15</version>
</plugin>
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/AbstractCoreIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/AbstractCoreIT.java b/stack/core/src/test/java/org/apache/usergrid/AbstractCoreIT.java
index f58e426..da80714 100644
--- a/stack/core/src/test/java/org/apache/usergrid/AbstractCoreIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/AbstractCoreIT.java
@@ -21,6 +21,9 @@ import org.junit.ClassRule;
import org.junit.Rule;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+
+import org.apache.usergrid.cassandra.CassandraResource;
+import org.apache.usergrid.persistence.index.impl.ElasticSearchResource;
import org.apache.usergrid.utils.JsonUtils;
@@ -29,7 +32,14 @@ public abstract class AbstractCoreIT {
private static final Logger LOG = LoggerFactory.getLogger( AbstractCoreIT.class );
@ClassRule
- public static CoreITSetup setup = new CoreITSetupImpl( CoreITSuite.cassandraResource, CoreITSuite.elasticSearchResource );
+ public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts();
+
+ @ClassRule
+ public static ElasticSearchResource elasticSearchResource = new ElasticSearchResource();
+
+
+ @ClassRule
+ public static CoreITSetup setup = new CoreITSetupImpl( cassandraResource, elasticSearchResource );
@Rule
public CoreApplication app = new CoreApplication( setup );
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreITSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreITSuite.java b/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreITSuite.java
deleted file mode 100644
index d981ee9..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreITSuite.java
+++ /dev/null
@@ -1,51 +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.usergrid;
-
-
-import org.junit.ClassRule;
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.cassandra.CassandraResource;
-import org.apache.usergrid.cassandra.Concurrent;
-import org.apache.usergrid.cassandra.ConcurrentSuite;
-import org.apache.usergrid.mq.MessagesIT;
-import org.apache.usergrid.persistence.CollectionIT;
-import org.apache.usergrid.persistence.CounterIT;
-import org.apache.usergrid.persistence.EntityConnectionsIT;
-import org.apache.usergrid.persistence.EntityDictionaryIT;
-import org.apache.usergrid.persistence.EntityManagerIT;
-import org.apache.usergrid.persistence.GeoIT;
-import org.apache.usergrid.persistence.IndexIT;
-import org.apache.usergrid.persistence.PathQueryIT;
-import org.apache.usergrid.persistence.PermissionsIT;
-import org.apache.usergrid.persistence.cassandra.EntityManagerFactoryImplIT;
-import org.apache.usergrid.system.UsergridSystemMonitorIT;
-
-
-@RunWith(ConcurrentSuite.class)
-@Suite.SuiteClasses({
- // HectorLockManagerIT.class,
- UsergridSystemMonitorIT.class, CollectionIT.class, CounterIT.class, EntityConnectionsIT.class,
- EntityDictionaryIT.class, EntityManagerIT.class, GeoIT.class, IndexIT.class, MessagesIT.class,
- PermissionsIT.class, PathQueryIT.class, EntityManagerFactoryImplIT.class
-})
-@Concurrent()
-public class ConcurrentCoreITSuite {
- @ClassRule
- public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts( );
-}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreIteratorITSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreIteratorITSuite.java b/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreIteratorITSuite.java
deleted file mode 100644
index 1312950..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreIteratorITSuite.java
+++ /dev/null
@@ -1,83 +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.usergrid;
-
-
-import org.junit.ClassRule;
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.cassandra.CassandraResource;
-import org.apache.usergrid.cassandra.Concurrent;
-import org.apache.usergrid.cassandra.ConcurrentSuite;
-import org.apache.usergrid.persistence.index.impl.ElasticSearchResource;
-import org.apache.usergrid.persistence.query.AllInCollectionIT;
-import org.apache.usergrid.persistence.query.AllInConnectionIT;
-import org.apache.usergrid.persistence.query.AllInConnectionNoTypeIT;
-import org.apache.usergrid.persistence.query.MultiOrderByCollectionIT;
-import org.apache.usergrid.persistence.query.MultiOrderByComplexUnionCollectionIT;
-import org.apache.usergrid.persistence.query.MultiOrderByComplexUnionConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByBoundRangeScanAscCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByBoundRangeScanAscConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByBoundRangeScanDescCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByBoundRangeScanDescConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByComplexIntersectionCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByComplexIntersectionConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByComplexUnionCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByComplexUnionConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByLessThanLimitCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByLessThanLimitConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByMaxLimitCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByMaxLimitConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByNoIntersectionCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByNoIntersectionConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByNotCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderByNotConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanGreaterCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanGreaterConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanGreaterThanEqualCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanLessCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanLessConnectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanLessThanEqualCollectionIT;
-import org.apache.usergrid.persistence.query.SingleOrderBySameRangeScanLessThanEqualConnectionIT;
-
-
-@RunWith(ConcurrentSuite.class)
-@Suite.SuiteClasses({
- AllInCollectionIT.class, AllInConnectionIT.class, AllInConnectionNoTypeIT.class, MultiOrderByCollectionIT.class,
- MultiOrderByComplexUnionCollectionIT.class, MultiOrderByComplexUnionConnectionIT.class,
- SingleOrderByBoundRangeScanAscCollectionIT.class, SingleOrderByBoundRangeScanAscConnectionIT.class,
- SingleOrderByBoundRangeScanDescCollectionIT.class, SingleOrderByBoundRangeScanDescConnectionIT.class,
- SingleOrderByComplexIntersectionCollectionIT.class, SingleOrderByComplexIntersectionConnectionIT.class,
- SingleOrderByComplexUnionCollectionIT.class, SingleOrderByComplexUnionConnectionIT.class,
- SingleOrderByLessThanLimitCollectionIT.class, SingleOrderByLessThanLimitConnectionIT.class,
- SingleOrderByMaxLimitCollectionIT.class, SingleOrderByMaxLimitConnectionIT.class,
- SingleOrderByNoIntersectionCollectionIT.class, SingleOrderByNoIntersectionConnectionIT.class,
- SingleOrderByNotCollectionIT.class, SingleOrderByNotConnectionIT.class,
- SingleOrderBySameRangeScanGreaterCollectionIT.class, SingleOrderBySameRangeScanGreaterConnectionIT.class,
- SingleOrderBySameRangeScanGreaterThanEqualCollectionIT.class, SingleOrderBySameRangeScanLessCollectionIT.class,
- SingleOrderBySameRangeScanLessConnectionIT.class, SingleOrderBySameRangeScanLessThanEqualCollectionIT.class,
- SingleOrderBySameRangeScanLessThanEqualConnectionIT.class
-})
-@Concurrent(threads = 1)
-public class ConcurrentCoreIteratorITSuite {
-
- @ClassRule
- public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts( );
-
- @ClassRule
- public static ElasticSearchResource elasticSearchResource = new ElasticSearchResource();
-}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreTestSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreTestSuite.java b/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreTestSuite.java
deleted file mode 100644
index 56c7871..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/ConcurrentCoreTestSuite.java
+++ /dev/null
@@ -1,46 +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.usergrid;
-
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.cassandra.Concurrent;
-import org.apache.usergrid.cassandra.ConcurrentSuite;
-import org.apache.usergrid.locking.zookeeper.ZookeeperLockManagerTest;
-import org.apache.usergrid.mq.QueuePathsTest;
-import org.apache.usergrid.persistence.EntityTest;
-import org.apache.usergrid.persistence.QueryTest;
-import org.apache.usergrid.persistence.QueryUtilsTest;
-import org.apache.usergrid.persistence.SchemaTest;
-import org.apache.usergrid.persistence.UtilsTest;
-import org.apache.usergrid.persistence.cassandra.QueryProcessorTest;
-import org.apache.usergrid.persistence.cassandra.SimpleIndexShardLocatorImplTest;
-import org.apache.usergrid.persistence.query.ir.result.IntersectionIteratorTest;
-import org.apache.usergrid.persistence.query.ir.result.SubtractionIteratorTest;
-import org.apache.usergrid.persistence.query.ir.result.UnionIteratorTest;
-
-
-@RunWith(ConcurrentSuite.class)
-@Suite.SuiteClasses({
- ZookeeperLockManagerTest.class, QueuePathsTest.class, QueryProcessorTest.class,
- SimpleIndexShardLocatorImplTest.class, EntityTest.class, QueryTest.class, QueryUtilsTest.class,
- SchemaTest.class, UtilsTest.class, IntersectionIteratorTest.class, SubtractionIteratorTest.class,
- UnionIteratorTest.class
-})
-@Concurrent()
-public class ConcurrentCoreTestSuite {}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/CoreITSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/CoreITSuite.java b/stack/core/src/test/java/org/apache/usergrid/CoreITSuite.java
deleted file mode 100644
index ff06a80..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/CoreITSuite.java
+++ /dev/null
@@ -1,58 +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.usergrid;
-
-
-import org.junit.ClassRule;
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.cassandra.CassandraResource;
-import org.apache.usergrid.cassandra.Concurrent;
-import org.apache.usergrid.locking.cassandra.HectorLockManagerIT;
-import org.apache.usergrid.mq.MessagesIT;
-import org.apache.usergrid.persistence.CollectionIT;
-import org.apache.usergrid.persistence.CounterIT;
-import org.apache.usergrid.persistence.EntityConnectionsIT;
-import org.apache.usergrid.persistence.EntityDictionaryIT;
-import org.apache.usergrid.persistence.EntityManagerIT;
-import org.apache.usergrid.persistence.GeoIT;
-import org.apache.usergrid.persistence.IndexIT;
-import org.apache.usergrid.persistence.PathQueryIT;
-import org.apache.usergrid.persistence.PermissionsIT;
-import org.apache.usergrid.persistence.cassandra.EntityManagerFactoryImplIT;
-import org.apache.usergrid.persistence.index.impl.ElasticSearchResource;
-import org.apache.usergrid.system.UsergridSystemMonitorIT;
-
-
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
- HectorLockManagerIT.class, UsergridSystemMonitorIT.class, CollectionIT.class, CounterIT.class,
- EntityConnectionsIT.class, EntityDictionaryIT.class, EntityManagerIT.class, GeoIT.class, IndexIT.class,
- MessagesIT.class, PermissionsIT.class, PathQueryIT.class, EntityManagerFactoryImplIT.class
-})
-@Concurrent()
-public class CoreITSuite {
-
- @ClassRule
- public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts( );
-
- @ClassRule
- public static ElasticSearchResource elasticSearchResource = new ElasticSearchResource();
-
-
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/CoreTestSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/CoreTestSuite.java b/stack/core/src/test/java/org/apache/usergrid/CoreTestSuite.java
deleted file mode 100644
index 314b4e5..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/CoreTestSuite.java
+++ /dev/null
@@ -1,45 +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.usergrid;
-
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.cassandra.Concurrent;
-import org.apache.usergrid.locking.zookeeper.ZookeeperLockManagerTest;
-import org.apache.usergrid.mq.QueuePathsTest;
-import org.apache.usergrid.persistence.EntityTest;
-import org.apache.usergrid.persistence.QueryTest;
-import org.apache.usergrid.persistence.QueryUtilsTest;
-import org.apache.usergrid.persistence.SchemaTest;
-import org.apache.usergrid.persistence.UtilsTest;
-import org.apache.usergrid.persistence.cassandra.QueryProcessorTest;
-import org.apache.usergrid.persistence.cassandra.SimpleIndexShardLocatorImplTest;
-import org.apache.usergrid.persistence.query.ir.result.IntersectionIteratorTest;
-import org.apache.usergrid.persistence.query.ir.result.SubtractionIteratorTest;
-import org.apache.usergrid.persistence.query.ir.result.UnionIteratorTest;
-
-
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
- ZookeeperLockManagerTest.class, QueuePathsTest.class, QueryProcessorTest.class,
- SimpleIndexShardLocatorImplTest.class, EntityTest.class, QueryTest.class, QueryUtilsTest.class,
- SchemaTest.class, UtilsTest.class, IntersectionIteratorTest.class, SubtractionIteratorTest.class,
- UnionIteratorTest.class
-})
-@Concurrent()
-public class CoreTestSuite {}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerITSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerITSuite.java b/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerITSuite.java
deleted file mode 100644
index f8c9f87..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerITSuite.java
+++ /dev/null
@@ -1,50 +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.usergrid.batch;
-
-
-import org.junit.ClassRule;
-import org.junit.Ignore;
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.batch.job.SchedulerRuntime1IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime2IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime3IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime4IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime5IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime6IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime7IT;
-import org.apache.usergrid.batch.job.SchedulerRuntime8IT;
-import org.apache.usergrid.cassandra.CassandraResource;
-import org.apache.usergrid.cassandra.Concurrent;
-
-
-@RunWith(Suite.class)
-@Suite.SuiteClasses(
- {
- SchedulerRuntime1IT.class, SchedulerRuntime2IT.class, SchedulerRuntime3IT.class,
- SchedulerRuntime4IT.class, SchedulerRuntime5IT.class, SchedulerRuntime6IT.class,
- SchedulerRuntime7IT.class, SchedulerRuntime8IT.class
- })
-@Concurrent()
-@Ignore("TODO: Todd fix. Does not reliably pass on our build server.")
-// TODO - this suite actually runs correctly now so we can
-// remove this ignore if Todd is OK with it.
-public class SchedulerITSuite {
- @ClassRule
- public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts();
-}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerTestSuite.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerTestSuite.java b/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerTestSuite.java
deleted file mode 100644
index 7e62dd5..0000000
--- a/stack/core/src/test/java/org/apache/usergrid/batch/SchedulerTestSuite.java
+++ /dev/null
@@ -1,34 +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.usergrid.batch;
-
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-import org.apache.usergrid.batch.AppArgsTest;
-import org.apache.usergrid.batch.BulkJobExecutionUnitTest;
-import org.apache.usergrid.batch.UsergridJobFactoryTest;
-import org.apache.usergrid.cassandra.Concurrent;
-
-
-@RunWith(Suite.class)
-@Suite.SuiteClasses(
- {
- AppArgsTest.class, UsergridJobFactoryTest.class, BulkJobExecutionUnitTest.class,
- })
-@Concurrent()
-public class SchedulerTestSuite {}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/batch/job/AbstractSchedulerRuntimeIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/batch/job/AbstractSchedulerRuntimeIT.java b/stack/core/src/test/java/org/apache/usergrid/batch/job/AbstractSchedulerRuntimeIT.java
index f939d0d..1d87b73 100644
--- a/stack/core/src/test/java/org/apache/usergrid/batch/job/AbstractSchedulerRuntimeIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/batch/job/AbstractSchedulerRuntimeIT.java
@@ -17,20 +17,20 @@
package org.apache.usergrid.batch.job;
-import com.google.common.util.concurrent.Service.State;
import java.util.Properties;
-import org.apache.usergrid.batch.SchedulerITSuite;
+
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.ClassRule;
+
import org.apache.usergrid.batch.service.JobSchedulerService;
import org.apache.usergrid.batch.service.SchedulerService;
import org.apache.usergrid.cassandra.CassandraResource;
import org.apache.usergrid.cassandra.SchemaManager;
import org.apache.usergrid.persistence.index.impl.ElasticSearchResource;
-import org.junit.AfterClass;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.ClassRule;
-import org.junit.Ignore;
+import com.google.common.util.concurrent.Service.State;
/**
@@ -44,8 +44,10 @@ public class AbstractSchedulerRuntimeIT {
protected static final String RUNLOOP_PROP = "usergrid.scheduler.job.interval";
protected static final String FAIL_PROP = "usergrid.scheduler.job.maxfail";
+
@ClassRule
- public static CassandraResource cassandraResource = SchedulerITSuite.cassandraResource;
+ public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts();
+
@ClassRule
public static ElasticSearchResource elasticSearchResource = new ElasticSearchResource();
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/persistence/CounterIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/persistence/CounterIT.java b/stack/core/src/test/java/org/apache/usergrid/persistence/CounterIT.java
index e360244..8a596a5 100644
--- a/stack/core/src/test/java/org/apache/usergrid/persistence/CounterIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/persistence/CounterIT.java
@@ -22,15 +22,15 @@ import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.UUID;
-import org.apache.commons.lang3.RandomStringUtils;
import org.junit.Before;
import org.junit.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import org.apache.commons.lang3.RandomStringUtils;
+
import org.apache.usergrid.AbstractCoreIT;
-import org.apache.usergrid.CoreITSuite;
import org.apache.usergrid.cassandra.Concurrent;
import org.apache.usergrid.count.SimpleBatcher;
import org.apache.usergrid.persistence.entities.Event;
@@ -61,7 +61,7 @@ public class CounterIT extends AbstractCoreIT {
@Before
public void getSubmitter() {
//set the batcher to block the submit so we wait for results when testing
- SimpleBatcher batcher = CoreITSuite.cassandraResource.getBean( SimpleBatcher.class );
+ SimpleBatcher batcher = cassandraResource.getBean( SimpleBatcher.class );
batcher.setBlockingSubmit( true );
batcher.setBatchSize( 1 );
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/persistence/IndexIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/persistence/IndexIT.java b/stack/core/src/test/java/org/apache/usergrid/persistence/IndexIT.java
index e839fa1..dc6593b 100644
--- a/stack/core/src/test/java/org/apache/usergrid/persistence/IndexIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/persistence/IndexIT.java
@@ -21,13 +21,14 @@ import java.nio.ByteBuffer;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.UUID;
-import me.prettyprint.cassandra.serializers.ByteBufferSerializer;
-import me.prettyprint.hector.api.Keyspace;
-import static me.prettyprint.hector.api.factory.HFactory.createMutator;
-import me.prettyprint.hector.api.mutation.Mutator;
+
+import org.junit.Test;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
import org.apache.commons.lang3.RandomStringUtils;
+
import org.apache.usergrid.AbstractCoreIT;
-import org.apache.usergrid.CoreITSuite;
import org.apache.usergrid.cassandra.Concurrent;
import org.apache.usergrid.persistence.cassandra.CassandraService;
import org.apache.usergrid.persistence.cassandra.IndexUpdate;
@@ -37,12 +38,14 @@ import org.apache.usergrid.persistence.index.query.Query;
import org.apache.usergrid.utils.JsonUtils;
import org.apache.usergrid.utils.UUIDUtils;
+import me.prettyprint.cassandra.serializers.ByteBufferSerializer;
+import me.prettyprint.hector.api.Keyspace;
+import me.prettyprint.hector.api.mutation.Mutator;
+
+import static me.prettyprint.hector.api.factory.HFactory.createMutator;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.fail;
-import org.junit.Test;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
@Concurrent()
@@ -445,7 +448,7 @@ public class IndexIT extends AbstractCoreIT {
RelationManagerImpl impl = (RelationManagerImpl)rm;
- CassandraService cass = CoreITSuite.cassandraResource.getBean( CassandraService.class );
+ CassandraService cass = cassandraResource.getBean( CassandraService.class );
ByteBufferSerializer buf = ByteBufferSerializer.get();
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/persistence/cassandra/EntityManagerFactoryImplIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/persistence/cassandra/EntityManagerFactoryImplIT.java b/stack/core/src/test/java/org/apache/usergrid/persistence/cassandra/EntityManagerFactoryImplIT.java
index 4cc0dbd..4edd121 100644
--- a/stack/core/src/test/java/org/apache/usergrid/persistence/cassandra/EntityManagerFactoryImplIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/persistence/cassandra/EntityManagerFactoryImplIT.java
@@ -22,16 +22,19 @@ import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.UUID;
-import org.apache.commons.lang3.RandomStringUtils;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
+import org.junit.ClassRule;
import org.junit.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+
+import org.apache.commons.lang3.RandomStringUtils;
+
import org.apache.usergrid.AbstractCoreIT;
-import org.apache.usergrid.CoreITSuite;
+import org.apache.usergrid.cassandra.CassandraResource;
import org.apache.usergrid.cassandra.Concurrent;
import org.apache.usergrid.persistence.Entity;
import org.apache.usergrid.persistence.EntityManager;
@@ -41,6 +44,7 @@ import org.apache.usergrid.persistence.SimpleEntityRef;
import org.apache.usergrid.persistence.cassandra.util.TraceTag;
import org.apache.usergrid.persistence.cassandra.util.TraceTagManager;
import org.apache.usergrid.persistence.cassandra.util.TraceTagReporter;
+import org.apache.usergrid.persistence.index.impl.ElasticSearchResource;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
@@ -57,8 +61,15 @@ public class EntityManagerFactoryImplIT extends AbstractCoreIT {
private static final Logger logger = LoggerFactory.getLogger( EntityManagerFactoryImplIT.class );
+ @ClassRule
+ public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts();
+
+ @ClassRule
+ public static ElasticSearchResource elasticSearchResource = new ElasticSearchResource();
+
+
public EntityManagerFactoryImplIT() {
- emf = CoreITSuite.cassandraResource.getBean( EntityManagerFactory.class );
+ emf = cassandraResource.getBean( EntityManagerFactory.class );
}
@@ -89,9 +100,9 @@ public class EntityManagerFactoryImplIT extends AbstractCoreIT {
@Before
public void initTracing() {
- traceTagManager = CoreITSuite.cassandraResource.getBean(
+ traceTagManager = cassandraResource.getBean(
"traceTagManager", TraceTagManager.class );
- traceTagReporter = CoreITSuite.cassandraResource.getBean(
+ traceTagReporter = cassandraResource.getBean(
"traceTagReporter", TraceTagReporter.class );
}
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/persistence/query/AbstractIteratingQueryIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/persistence/query/AbstractIteratingQueryIT.java b/stack/core/src/test/java/org/apache/usergrid/persistence/query/AbstractIteratingQueryIT.java
index d8f31ff..ff47846 100644
--- a/stack/core/src/test/java/org/apache/usergrid/persistence/query/AbstractIteratingQueryIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/persistence/query/AbstractIteratingQueryIT.java
@@ -30,11 +30,12 @@ import org.junit.ClassRule;
import org.junit.Rule;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import org.apache.usergrid.ConcurrentCoreIteratorITSuite;
import org.apache.usergrid.CoreApplication;
import org.apache.usergrid.CoreITSetup;
import org.apache.usergrid.CoreITSetupImpl;
+import org.apache.usergrid.cassandra.CassandraResource;
import org.apache.usergrid.persistence.Entity;
+import org.apache.usergrid.persistence.index.impl.ElasticSearchResource;
import org.apache.usergrid.persistence.index.query.Query;
import org.apache.usergrid.persistence.Results;
@@ -48,10 +49,16 @@ public abstract class AbstractIteratingQueryIT {
public static final long WRITE_DELAY = 0; // milliseconds to delay between writes in loop
+
+ @ClassRule
+ public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts();
+
+ @ClassRule
+ public static ElasticSearchResource elasticSearchResource = new ElasticSearchResource();
+
+
@ClassRule
- public static CoreITSetup setup = new CoreITSetupImpl(
- ConcurrentCoreIteratorITSuite.cassandraResource,
- ConcurrentCoreIteratorITSuite.elasticSearchResource );
+ public static CoreITSetup setup = new CoreITSetupImpl( cassandraResource, elasticSearchResource );
@Rule
public CoreApplication app = new CoreApplication( setup );
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/bc93f693/stack/core/src/test/java/org/apache/usergrid/system/UsergridSystemMonitorIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/system/UsergridSystemMonitorIT.java b/stack/core/src/test/java/org/apache/usergrid/system/UsergridSystemMonitorIT.java
index 7456106..a9f9e18 100644
--- a/stack/core/src/test/java/org/apache/usergrid/system/UsergridSystemMonitorIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/system/UsergridSystemMonitorIT.java
@@ -20,13 +20,15 @@ package org.apache.usergrid.system;
import java.util.Date;
import org.junit.Before;
+import org.junit.ClassRule;
import org.junit.Test;
-import org.apache.usergrid.CoreITSuite;
-import org.apache.usergrid.cassandra.Concurrent;
-import org.apache.usergrid.utils.MapUtils;
import org.apache.commons.lang.StringUtils;
+import org.apache.usergrid.cassandra.CassandraResource;
+import org.apache.usergrid.cassandra.Concurrent;
+import org.apache.usergrid.utils.MapUtils;
+
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
@@ -34,12 +36,16 @@ import static org.junit.Assert.assertTrue;
/** @author zznate */
@Concurrent
public class UsergridSystemMonitorIT {
+
+ @ClassRule
+ public static CassandraResource cassandraResource = CassandraResource.newWithAvailablePorts();
+
private UsergridSystemMonitor usergridSystemMonitor;
@Before
public void setupLocal() {
- usergridSystemMonitor = CoreITSuite.cassandraResource.getBean( UsergridSystemMonitor.class );
+ usergridSystemMonitor = cassandraResource.getBean( UsergridSystemMonitor.class );
}