usergrid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sfeld...@apache.org
Subject [06/25] incubator-usergrid git commit: Finished migrating tests to new framework. Need to validate keyspace name.
Date Wed, 01 Apr 2015 20:44:41 GMT
Finished migrating tests to new framework.  Need to validate keyspace name.


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

Branch: refs/heads/two-dot-o-dev
Commit: 6bf2d3d2b262932866033ed73c3c66e8d5159639
Parents: c39be5d
Author: Todd Nine <tnine@apigee.com>
Authored: Thu Mar 26 17:47:52 2015 -0600
Committer: Todd Nine <tnine@apigee.com>
Committed: Thu Mar 26 17:47:52 2015 -0600

----------------------------------------------------------------------
 .../migration/EntityTypeMappingMigration.java   |   4 +-
 .../rx/AllEntitiesInSystemObservableIT.java     |   2 +-
 .../persistence/collection/CollectionScope.java |  45 --------
 .../collection/EntityCollectionManager.java     |   2 +
 .../persistence/collection/FieldSet.java        |   2 +-
 .../cache/CachedEntityCollectionManager.java    |   5 +-
 .../collection/event/EntityDeleted.java         |   8 +-
 .../collection/event/EntityVersionCreated.java  |   7 +-
 .../collection/event/EntityVersionDeleted.java  |   8 +-
 .../WriteOptimisticVerifyException.java         |   3 +-
 .../exception/WriteStartException.java          |   3 +-
 .../exception/WriteUniqueVerifyException.java   |   2 +-
 .../collection/guice/CollectionModule.java      |   2 +-
 .../guice/CollectionTaskExecutor.java           |   4 +-
 .../collection/impl/CollectionScopeImpl.java    | 102 -------------------
 .../EntityCollectionManagerFactoryImpl.java     |   2 +-
 .../impl/EntityCollectionManagerImpl.java       |   2 +-
 .../collection/impl/EntityDeletedTask.java      |  29 +++---
 .../impl/EntityVersionCleanupTask.java          |  16 ++-
 .../impl/EntityVersionCreatedTask.java          |  13 ++-
 .../impl/EntityVersionTaskFactory.java          |   7 +-
 .../collection/mvcc/changelog/ChangeLog.java    |   2 -
 .../mvcc/entity/MvccValidationUtils.java        |  16 ---
 .../mvcc/entity/impl/MvccEntityDeleteEvent.java |   8 +-
 .../mvcc/entity/impl/MvccEntityEvent.java       |  11 +-
 .../mvcc/entity/impl/MvccEntityWriteEvent.java  |   6 +-
 .../mvcc/stage/CollectionIoEvent.java           |   2 +-
 .../mvcc/stage/EntityUpdateEvent.java           |  34 -------
 .../mvcc/stage/delete/MarkCommit.java           |   5 +-
 .../collection/mvcc/stage/delete/MarkStart.java |   5 +-
 .../mvcc/stage/write/RollbackAction.java        |   5 +-
 .../mvcc/stage/write/WriteCommit.java           |  13 ++-
 .../mvcc/stage/write/WriteOptimisticVerify.java |   5 +-
 .../collection/mvcc/stage/write/WriteStart.java |   5 +-
 .../mvcc/stage/write/WriteUniqueVerify.java     |  18 ++--
 .../MvccEntitySerializationStrategy.java        |   1 -
 .../collection/serialization/UniqueValue.java   |   1 -
 .../UniqueValueSerializationStrategy.java       |   8 +-
 .../serialization/UniqueValueSet.java           |   3 -
 .../impl/EntityVersionSerializer.java           |   9 +-
 .../serialization/impl/LogEntryIterator.java    |   8 +-
 .../serialization/impl/MutableFieldSet.java     |   6 +-
 .../MvccEntitySerializationStrategyImpl.java    |   9 +-
 .../MvccEntitySerializationStrategyV3Impl.java  |   8 +-
 .../MvccLogEntrySerializationStrategyImpl.java  |   2 +-
 .../serialization/impl/SerializationModule.java |   2 +-
 .../serialization/impl/UniqueFieldEntry.java    |   1 -
 .../impl/UniqueFieldEntrySerializer.java        |   3 -
 .../serialization/impl/UniqueValueImpl.java     |   5 +-
 .../UniqueValueSerializationStrategyImpl.java   |   7 +-
 .../migration/CollectionMigrationPlugin.java    |   2 +-
 .../impl/migration/EntityIdScope.java           |  12 +--
 .../migration/MvccEntityDataMigrationImpl.java  |  14 ++-
 .../impl/util/LegacyScopeUtils.java             |   6 --
 .../collection/ApplicationContextImplTest.java  |  33 ++++++
 .../collection/CollectionContextImplTest.java   |  53 ----------
 .../EntityCollectionManagerFactoryTest.java     |   9 +-
 .../collection/EntityCollectionManagerIT.java   |  92 ++++++++---------
 .../EntityCollectionManagerStressTest.java      |  14 +--
 .../impl/EntityVersionCleanupTaskTest.java      |  24 ++---
 .../impl/EntityVersionCreatedTaskTest.java      |  27 +++--
 .../mvcc/stage/AbstractEntityStageTest.java     |   6 +-
 .../mvcc/stage/AbstractIdStageTest.java         |   4 +-
 .../mvcc/stage/AbstractMvccEntityStageTest.java |   6 +-
 .../mvcc/stage/TestEntityGenerator.java         |   2 +-
 .../mvcc/stage/delete/MarkCommitTest.java       |  14 +--
 .../mvcc/stage/delete/MarkStartTest.java        |   6 +-
 ...niqueValueSerializationStrategyImplTest.java |  50 ++++-----
 .../mvcc/stage/write/WriteCommitTest.java       |  12 +--
 .../stage/write/WriteOptimisticVerifyTest.java  |  23 ++---
 .../mvcc/stage/write/WriteStartTest.java        |  20 ++--
 .../mvcc/stage/write/WriteUniqueVerifyIT.java   |  34 +++----
 .../mvcc/stage/write/WriteUniqueVerifyTest.java |  13 ++-
 .../impl/LogEntryIteratorTest.java              |  14 +--
 ...MvccEntitySerializationStrategyImplTest.java |  50 ++++-----
 ...ccEntitySerializationStrategyV1ImplTest.java |  10 +-
 ...ccEntitySerializationStrategyV2ImplTest.java |  10 +-
 .../MvccEntitySerializationStrategyV2Test.java  |  20 ++--
 ...ccEntitySerializationStrategyV3ImplTest.java |  16 ++-
 .../impl/MvccLESSTransientTest.java             |  23 ++---
 ...ccLogEntrySerializationStrategyImplTest.java |  87 +++++++---------
 .../impl/ScopedRowKeySerializerTest.java        |   2 +-
 .../impl/SerializationComparison.java           |   2 +-
 .../impl/SettingsValidationTest.java            |   1 -
 ...ctMvccEntityDataMigrationV1ToV3ImplTest.java |   9 +-
 .../MvccEntityDataMigrationV1ToV3ImplTest.java  |   6 --
 .../collection/util/EntityHelper.java           |   1 -
 .../collection/util/LogEntryMock.java           |   9 +-
 .../collection/util/UniqueValueEntryMock.java   |   7 +-
 .../core/scope/ApplicationScopeImpl.java        |   3 +
 90 files changed, 457 insertions(+), 765 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/core/src/main/java/org/apache/usergrid/corepersistence/migration/EntityTypeMappingMigration.java
----------------------------------------------------------------------
diff --git a/stack/core/src/main/java/org/apache/usergrid/corepersistence/migration/EntityTypeMappingMigration.java b/stack/core/src/main/java/org/apache/usergrid/corepersistence/migration/EntityTypeMappingMigration.java
index 6531d16..47ad30a 100644
--- a/stack/core/src/main/java/org/apache/usergrid/corepersistence/migration/EntityTypeMappingMigration.java
+++ b/stack/core/src/main/java/org/apache/usergrid/corepersistence/migration/EntityTypeMappingMigration.java
@@ -35,8 +35,6 @@ import org.apache.usergrid.persistence.map.MapScope;
 import com.google.inject.Inject;
 
 import rx.Observable;
-import rx.functions.Action1;
-import rx.functions.Func1;
 import rx.schedulers.Schedulers;
 
 
@@ -68,7 +66,7 @@ public class EntityTypeMappingMigration implements DataMigration<EntityIdScope>
         allEntitiesInSystemObservable.getData().flatMap( entityIdScope -> {
             return Observable.just( entityIdScope ).doOnNext( entityIdScopeObservable -> {
                 final MapScope ms = CpNamingUtils
-                                                 .getEntityTypeMapScope( entityIdScope.getCollectionScope().getApplication() );
+                                                 .getEntityTypeMapScope( entityIdScope.getApplicationScope().getApplication() );
 
                                              final MapManager mapManager = managerCache.getMapManager( ms );
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/core/src/test/java/org/apache/usergrid/corepersistence/rx/AllEntitiesInSystemObservableIT.java
----------------------------------------------------------------------
diff --git a/stack/core/src/test/java/org/apache/usergrid/corepersistence/rx/AllEntitiesInSystemObservableIT.java b/stack/core/src/test/java/org/apache/usergrid/corepersistence/rx/AllEntitiesInSystemObservableIT.java
index 7a6ec22..3e6a77f 100644
--- a/stack/core/src/test/java/org/apache/usergrid/corepersistence/rx/AllEntitiesInSystemObservableIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/corepersistence/rx/AllEntitiesInSystemObservableIT.java
@@ -99,7 +99,7 @@ public class AllEntitiesInSystemObservableIT extends AbstractCoreIT {
             @Override
             public void call( final EntityIdScope entityIdScope ) {
                 assertNotNull(entityIdScope);
-                assertNotNull(entityIdScope.getCollectionScope());
+                assertNotNull(entityIdScope.getApplicationScope());
                 assertNotNull(entityIdScope.getId());
 
                     //we should only emit each node once

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.java
deleted file mode 100644
index 7fda54e..0000000
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/CollectionScope.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.persistence.collection;
-
-
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
-import org.apache.usergrid.persistence.model.entity.Id;
-
-
-/**
- * A scope to use when creating the collection manager.  Typically, this would be something like an application, or an
- * organization. Data encapsulated within instances of a scope are mutually exclusive from instances with other ids and
- * names.
- */
-public interface CollectionScope extends ApplicationScope {
-
-    /**
-     * @return The name of the collection. If you use pluralization for you names vs types,
-     * you must keep the consistent or you will be unable to load data
-     */
-    public String getName();
-
-
-    /**
-     * @return A uuid that is unique to this context.  It can be any uuid (time uuid preferred).  Usually an application
-     *         Id, but could be an entity Id that is the parent of another collection
-     */
-    public Id getOwner();
-}

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
index d4232ca..5a329e3 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/EntityCollectionManager.java
@@ -20,10 +20,12 @@ package org.apache.usergrid.persistence.collection;
 
 
 import java.util.Collection;
+
 import org.apache.usergrid.persistence.core.util.Health;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;
 import org.apache.usergrid.persistence.model.field.Field;
+
 import rx.Observable;
 
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/FieldSet.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/FieldSet.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/FieldSet.java
index c46fa3b..43f470d 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/FieldSet.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/FieldSet.java
@@ -18,7 +18,7 @@
  */
 package org.apache.usergrid.persistence.collection;
 
-import org.apache.usergrid.persistence.model.entity.Id;
+
 import org.apache.usergrid.persistence.model.field.Field;
 
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/cache/CachedEntityCollectionManager.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/cache/CachedEntityCollectionManager.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/cache/CachedEntityCollectionManager.java
index 57dcc79..fa35580 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/cache/CachedEntityCollectionManager.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/cache/CachedEntityCollectionManager.java
@@ -23,7 +23,10 @@ package org.apache.usergrid.persistence.collection.cache;
 import java.util.Collection;
 import java.util.concurrent.TimeUnit;
 
-import org.apache.usergrid.persistence.collection.*;
+import org.apache.usergrid.persistence.collection.EntityCollectionManager;
+import org.apache.usergrid.persistence.collection.EntitySet;
+import org.apache.usergrid.persistence.collection.FieldSet;
+import org.apache.usergrid.persistence.collection.VersionSet;
 import org.apache.usergrid.persistence.core.util.Health;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityDeleted.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityDeleted.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityDeleted.java
index 0e2b8a2..0e9b62e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityDeleted.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityDeleted.java
@@ -18,11 +18,11 @@
 package org.apache.usergrid.persistence.collection.event;
 
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.model.entity.Id;
-
 import java.util.UUID;
 
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
+import org.apache.usergrid.persistence.model.entity.Id;
+
 
 /**
  *
@@ -40,6 +40,6 @@ public interface EntityDeleted {
      * @param entityId The id of the entity
      * @param version the entity version
      */
-    public void deleted( final CollectionScope scope, final Id entityId, final UUID version);
+    public void deleted( final ApplicationScope scope, final Id entityId, final UUID version);
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionCreated.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionCreated.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionCreated.java
index 4412b0c..7f1be1a 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionCreated.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionCreated.java
@@ -17,7 +17,8 @@
  */
 package org.apache.usergrid.persistence.collection.event;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
+
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 
 
@@ -29,10 +30,10 @@ public interface EntityVersionCreated {
 
     /**
      * The new version of the entity. Note that this should be a fully merged view of the entity.
-     * In the case of partial updates, the passed entity should be fully merged with it's previous 
+     * In the case of partial updates, the passed entity should be fully merged with it's previous
      * entries.
      * @param scope The scope of the entity
      * @param entity The fully loaded and merged entity
      */
-    public void versionCreated( final CollectionScope scope, final Entity entity );
+    public void versionCreated( final ApplicationScope scope, final Entity entity );
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionDeleted.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionDeleted.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionDeleted.java
index 179abc1..7fd8fe7 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionDeleted.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/event/EntityVersionDeleted.java
@@ -19,15 +19,15 @@ package org.apache.usergrid.persistence.collection.event;
 
 
 import java.util.List;
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.MvccEntity;
+
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Id;
 
 
 /**
  *
- * Invoked when an entity version is removed.  Note that this is not a deletion of the entity 
+ * Invoked when an entity version is removed.  Note that this is not a deletion of the entity
  * itself, only the version itself.
  *
  */
@@ -40,7 +40,7 @@ public interface EntityVersionDeleted {
      * @param entityId The entity Id that was removed
      * @param entityVersions The versions that are to be removed
      */
-    public void versionDeleted(final CollectionScope scope, final Id entityId, 
+    public void versionDeleted(final ApplicationScope scope, final Id entityId,
             final List<MvccLogEntry> entityVersions);
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteOptimisticVerifyException.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteOptimisticVerifyException.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteOptimisticVerifyException.java
index 0badc42..8a7a93d 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteOptimisticVerifyException.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteOptimisticVerifyException.java
@@ -17,8 +17,9 @@
  */
 package org.apache.usergrid.persistence.collection.exception;
 
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
+
 import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 
 
 public class WriteOptimisticVerifyException extends CollectionRuntimeException {

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteStartException.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteStartException.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteStartException.java
index 27f029b..9c556bf 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteStartException.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteStartException.java
@@ -17,8 +17,9 @@
  */
 package org.apache.usergrid.persistence.collection.exception;
 
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
+
 import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 
 
 public class WriteStartException extends CollectionRuntimeException {

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteUniqueVerifyException.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteUniqueVerifyException.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteUniqueVerifyException.java
index 083eddb..81165fa 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteUniqueVerifyException.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/exception/WriteUniqueVerifyException.java
@@ -20,8 +20,8 @@ package org.apache.usergrid.persistence.collection.exception;
 
 import java.util.Map;
 
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.field.Field;
 
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionModule.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionModule.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionModule.java
index 68ddab5..eaf89ef 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionModule.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionModule.java
@@ -21,12 +21,12 @@ package org.apache.usergrid.persistence.collection.guice;
 import org.safehaus.guicyfig.GuicyFigModule;
 
 import org.apache.usergrid.persistence.collection.EntityCollectionManagerFactory;
-import org.apache.usergrid.persistence.collection.impl.EntityVersionTaskFactory;
 import org.apache.usergrid.persistence.collection.cache.EntityCacheFig;
 import org.apache.usergrid.persistence.collection.event.EntityDeleted;
 import org.apache.usergrid.persistence.collection.event.EntityVersionCreated;
 import org.apache.usergrid.persistence.collection.event.EntityVersionDeleted;
 import org.apache.usergrid.persistence.collection.impl.EntityCollectionManagerFactoryImpl;
+import org.apache.usergrid.persistence.collection.impl.EntityVersionTaskFactory;
 import org.apache.usergrid.persistence.collection.mvcc.changelog.ChangeLogGenerator;
 import org.apache.usergrid.persistence.collection.mvcc.changelog.ChangeLogGeneratorImpl;
 import org.apache.usergrid.persistence.collection.serialization.SerializationFig;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionTaskExecutor.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionTaskExecutor.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionTaskExecutor.java
index 7c08437..53c1f48 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionTaskExecutor.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/guice/CollectionTaskExecutor.java
@@ -23,10 +23,10 @@ import java.lang.annotation.Target;
 
 import com.google.inject.BindingAnnotation;
 
-import static java.lang.annotation.RetentionPolicy.RUNTIME;
-import static java.lang.annotation.ElementType.PARAMETER;
 import static java.lang.annotation.ElementType.FIELD;
 import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.PARAMETER;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
deleted file mode 100644
index 958cc70..0000000
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/CollectionScopeImpl.java
+++ /dev/null
@@ -1,102 +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.persistence.collection.impl;
-
-
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.mvcc.entity.MvccValidationUtils;
-import org.apache.usergrid.persistence.core.scope.ApplicationScopeImpl;
-import org.apache.usergrid.persistence.model.entity.Id;
-
-import com.google.inject.Inject;
-
-
-/**
- * Simple impl of hte collection context
- *
- * @author tnine
- */
-public class CollectionScopeImpl extends ApplicationScopeImpl implements CollectionScope {
-    private final Id ownerId;
-    private final String name;
-
-    @Inject
-    public CollectionScopeImpl( final Id applicationId, final Id ownerId, final String name ) {
-        super( applicationId );
-        this.ownerId = ownerId;
-        this.name = name;
-
-        MvccValidationUtils.validateCollectionScope( this );
-    }
-
-
-    @Override
-    public Id getOwner() {
-        return ownerId;
-    }
-
-
-    @Override
-    public String getName() {
-        return name;
-    }
-
-
-    @Override
-    public boolean equals( final Object o ) {
-        if ( this == o ) {
-            return true;
-        }
-        if ( !( o instanceof CollectionScopeImpl ) ) {
-            return false;
-        }
-        if ( !super.equals( o ) ) {
-            return false;
-        }
-
-        final CollectionScope that = ( CollectionScope ) o;
-
-        if ( !name.equals( that.getName() ) ) {
-            return false;
-        }
-        if ( !ownerId.equals( that.getOwner() ) ) {
-            return false;
-        }
-
-        return true;
-    }
-
-
-    @Override
-    public int hashCode() {
-        int result = super.hashCode();
-        result = 31 * result + ownerId.hashCode();
-        result = 31 * result + name.hashCode();
-        return result;
-    }
-
-
-    @Override
-    public String toString() {
-        return "CollectionScopeImpl{" +
-                "ownerId=" + ownerId +
-                ", name='" + name + '\'' +
-                '}';
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerFactoryImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerFactoryImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerFactoryImpl.java
index 5cc326b..8574324 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerFactoryImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerFactoryImpl.java
@@ -28,7 +28,6 @@ import org.apache.usergrid.persistence.collection.EntityCollectionManagerFactory
 import org.apache.usergrid.persistence.collection.cache.CachedEntityCollectionManager;
 import org.apache.usergrid.persistence.collection.cache.EntityCacheFig;
 import org.apache.usergrid.persistence.collection.guice.CollectionTaskExecutor;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.mvcc.stage.delete.MarkCommit;
 import org.apache.usergrid.persistence.collection.mvcc.stage.delete.MarkStart;
 import org.apache.usergrid.persistence.collection.mvcc.stage.write.RollbackAction;
@@ -37,6 +36,7 @@ import org.apache.usergrid.persistence.collection.mvcc.stage.write.WriteOptimist
 import org.apache.usergrid.persistence.collection.mvcc.stage.write.WriteStart;
 import org.apache.usergrid.persistence.collection.mvcc.stage.write.WriteUniqueVerify;
 import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
 import org.apache.usergrid.persistence.core.guice.ProxyImpl;
 import org.apache.usergrid.persistence.core.metrics.MetricsFactory;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
index 1d73268..8e29f4a 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityCollectionManagerImpl.java
@@ -34,7 +34,6 @@ import org.apache.usergrid.persistence.collection.FieldSet;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.VersionSet;
 import org.apache.usergrid.persistence.collection.guice.CollectionTaskExecutor;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
 import org.apache.usergrid.persistence.collection.mvcc.stage.delete.MarkCommit;
 import org.apache.usergrid.persistence.collection.mvcc.stage.delete.MarkStart;
@@ -44,6 +43,7 @@ import org.apache.usergrid.persistence.collection.mvcc.stage.write.WriteOptimist
 import org.apache.usergrid.persistence.collection.mvcc.stage.write.WriteStart;
 import org.apache.usergrid.persistence.collection.mvcc.stage.write.WriteUniqueVerify;
 import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValue;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSet;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityDeletedTask.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityDeletedTask.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityDeletedTask.java
index 213cbb9..d858930 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityDeletedTask.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityDeletedTask.java
@@ -18,24 +18,27 @@
  */
 package org.apache.usergrid.persistence.collection.impl;
 
-import com.google.inject.Inject;
-import com.google.inject.assistedinject.Assisted;
-import com.netflix.astyanax.MutationBatch;
-import org.apache.usergrid.persistence.collection.CollectionScope;
+
+import java.util.Set;
+import java.util.UUID;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
 import org.apache.usergrid.persistence.collection.event.EntityDeleted;
 import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
+import org.apache.usergrid.persistence.core.guice.ProxyImpl;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.core.task.Task;
 import org.apache.usergrid.persistence.model.entity.Id;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import rx.Observable;
-import rx.schedulers.Schedulers;
 
-import java.util.Set;
-import java.util.UUID;
+import com.google.inject.Inject;
+import com.google.inject.assistedinject.Assisted;
+import com.netflix.astyanax.MutationBatch;
 
-import org.apache.usergrid.persistence.core.guice.ProxyImpl;
+import rx.Observable;
+import rx.schedulers.Schedulers;
 
 
 /**
@@ -48,7 +51,7 @@ public class EntityDeletedTask implements Task<Void> {
     private final MvccLogEntrySerializationStrategy logEntrySerializationStrategy;
     private final MvccEntitySerializationStrategy entitySerializationStrategy;
     private final Set<EntityDeleted> listeners;
-    private final CollectionScope collectionScope;
+    private final ApplicationScope collectionScope;
     private final Id entityId;
     private final UUID version;
 
@@ -59,7 +62,7 @@ public class EntityDeletedTask implements Task<Void> {
         final MvccLogEntrySerializationStrategy logEntrySerializationStrategy,
         @ProxyImpl final MvccEntitySerializationStrategy entitySerializationStrategy,
         final Set<EntityDeleted>                listeners, // MUST be a set or Guice will not inject
-        @Assisted final CollectionScope         collectionScope,
+        @Assisted final ApplicationScope  collectionScope,
         @Assisted final Id                      entityId,
         @Assisted final UUID                    version) {
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCleanupTask.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCleanupTask.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCleanupTask.java
index f52eb25..b5f9085 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCleanupTask.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCleanupTask.java
@@ -23,25 +23,23 @@ import java.util.List;
 import java.util.Set;
 import java.util.UUID;
 
-import com.google.inject.Inject;
-import com.google.inject.assistedinject.Assisted;
-
-import org.apache.usergrid.persistence.collection.serialization.UniqueValue;
-import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
-
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
 import org.apache.usergrid.persistence.collection.event.EntityVersionDeleted;
 import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.SerializationFig;
+import org.apache.usergrid.persistence.collection.serialization.UniqueValue;
+import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.impl.LogEntryIterator;
 import org.apache.usergrid.persistence.core.rx.ObservableIterator;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.core.task.Task;
 import org.apache.usergrid.persistence.model.entity.Id;
 
+import com.google.inject.Inject;
+import com.google.inject.assistedinject.Assisted;
 import com.netflix.astyanax.Keyspace;
 import com.netflix.astyanax.MutationBatch;
 import com.netflix.astyanax.connectionpool.exceptions.ConnectionException;
@@ -69,7 +67,7 @@ public class EntityVersionCleanupTask implements Task<Void> {
 
     private final SerializationFig serializationFig;
 
-    private final CollectionScope scope;
+    private final ApplicationScope scope;
     private final Id entityId;
     private final UUID version;
     private final boolean includeVersion;
@@ -82,7 +80,7 @@ public class EntityVersionCleanupTask implements Task<Void> {
         final UniqueValueSerializationStrategy  uniqueValueSerializationStrategy,
         final Keyspace                          keyspace,
         final Set<EntityVersionDeleted>         listeners, // MUST be a set or Guice will not inject
-        @Assisted final CollectionScope         scope,
+        @Assisted final ApplicationScope scope,
         @Assisted final Id                      entityId,
         @Assisted final UUID                    version,
         @Assisted final boolean includeVersion) {

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCreatedTask.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCreatedTask.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCreatedTask.java
index 16a6e77..fbbcdbd 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCreatedTask.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionCreatedTask.java
@@ -17,18 +17,21 @@
  */
 package org.apache.usergrid.persistence.collection.impl;
 
+
 import java.util.Set;
+
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
-import org.apache.usergrid.persistence.collection.CollectionScope;
+
 import org.apache.usergrid.persistence.collection.event.EntityVersionCreated;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.core.task.Task;
 import org.apache.usergrid.persistence.model.entity.Entity;
+
 import com.google.inject.Inject;
 import com.google.inject.assistedinject.Assisted;
+
 import rx.Observable;
-import rx.functions.Action1;
-import rx.functions.Func1;
 import rx.schedulers.Schedulers;
 
 
@@ -39,12 +42,12 @@ public class EntityVersionCreatedTask implements Task<Void> {
     private static final Logger logger = LoggerFactory.getLogger( EntityVersionCreatedTask.class );
 
     private Set<EntityVersionCreated> listeners;
-    private final CollectionScope collectionScope;
+    private final ApplicationScope collectionScope;
     private final Entity entity;
 
 
     @Inject
-    public EntityVersionCreatedTask( @Assisted final CollectionScope collectionScope,
+    public EntityVersionCreatedTask( @Assisted final ApplicationScope collectionScope,
                                      final Set<EntityVersionCreated> listeners,
                                      @Assisted final Entity entity ) {
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionTaskFactory.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionTaskFactory.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionTaskFactory.java
index e121b77..51a4607 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionTaskFactory.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/impl/EntityVersionTaskFactory.java
@@ -18,17 +18,12 @@
 package org.apache.usergrid.persistence.collection.impl;
 
 
+import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.impl.EntityDeletedTask;
-import org.apache.usergrid.persistence.collection.impl.EntityVersionCleanupTask;
-import org.apache.usergrid.persistence.collection.impl.EntityVersionCreatedTask;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;
 
-import java.util.UUID;
-
 
 public interface EntityVersionTaskFactory {
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/changelog/ChangeLog.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/changelog/ChangeLog.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/changelog/ChangeLog.java
index d028aa0..d5ea423 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/changelog/ChangeLog.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/changelog/ChangeLog.java
@@ -38,9 +38,7 @@ package org.apache.usergrid.persistence.collection.mvcc.changelog;/*
  */
 
 
-import java.util.List;
 import java.util.Set;
-import java.util.UUID;
 
 import org.apache.usergrid.persistence.model.field.Field;
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccValidationUtils.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccValidationUtils.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccValidationUtils.java
index 1f0c91b..f97db9c 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccValidationUtils.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/MvccValidationUtils.java
@@ -19,15 +19,12 @@
 package org.apache.usergrid.persistence.collection.mvcc.entity;
 
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 
 import com.google.common.base.Preconditions;
 
-import static org.apache.usergrid.persistence.core.util.ValidationUtils.validateApplicationScope;
 import static org.apache.usergrid.persistence.core.util.ValidationUtils.verifyEntityWrite;
 import static org.apache.usergrid.persistence.core.util.ValidationUtils.verifyIdentity;
-import static org.apache.usergrid.persistence.core.util.ValidationUtils.verifyString;
 import static org.apache.usergrid.persistence.core.util.ValidationUtils.verifyTimeUuid;
 import static org.apache.usergrid.persistence.core.util.ValidationUtils.verifyVersion;
 
@@ -66,19 +63,6 @@ public class MvccValidationUtils {
 
 
 
-    /**
-     * Validate the collection scope
-     */
-    public static void validateCollectionScope( final CollectionScope scope ) {
-
-        Preconditions.checkNotNull( scope, "collection scope is required" );
-
-        verifyIdentity( scope.getOwner() );
-
-        verifyString( scope.getName(), "name" );
-
-        validateApplicationScope( scope );
-    }
 
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityDeleteEvent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityDeleteEvent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityDeleteEvent.java
index 1f8fc24..e1a7ef3 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityDeleteEvent.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityDeleteEvent.java
@@ -21,8 +21,8 @@ package org.apache.usergrid.persistence.collection.mvcc.entity.impl;
 
 import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 
 
 /**
@@ -30,9 +30,9 @@ import org.apache.usergrid.persistence.collection.MvccEntity;
  */
 public class MvccEntityDeleteEvent extends MvccEntityEvent {
 
-    public MvccEntityDeleteEvent( 
-            final CollectionScope collectionScope, final UUID version, final MvccEntity entity ) {
+    public MvccEntityDeleteEvent(
+            final ApplicationScope applicationScope, final UUID version, final MvccEntity entity ) {
 
-        super( collectionScope, version, entity );
+        super( applicationScope, version, entity );
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityEvent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityEvent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityEvent.java
index f9f1389..ffedf86 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityEvent.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityEvent.java
@@ -18,29 +18,30 @@
 
 package org.apache.usergrid.persistence.collection.mvcc.entity.impl;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.MvccEntity;
 
 import java.io.Serializable;
 import java.util.UUID;
 
+import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
+
 /**
  * Entity Event for queues
  */
 public abstract class MvccEntityEvent implements Serializable {
 
-    private final CollectionScope collectionScope;
+    private final ApplicationScope collectionScope;
     private final MvccEntity entity;
     private final UUID version;
 
 
-    public MvccEntityEvent(final CollectionScope collectionScope, final UUID version, final MvccEntity entity) {
+    public MvccEntityEvent(final ApplicationScope collectionScope, final UUID version, final MvccEntity entity) {
         this.collectionScope = collectionScope;
         this.entity = entity;
         this.version = version;
     }
 
-    public CollectionScope getCollectionScope() {
+    public ApplicationScope getApplicationScope() {
         return collectionScope;
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityWriteEvent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityWriteEvent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityWriteEvent.java
index 84cfd18..c94f8a4 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityWriteEvent.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/entity/impl/MvccEntityWriteEvent.java
@@ -21,8 +21,8 @@ package org.apache.usergrid.persistence.collection.mvcc.entity.impl;
 
 import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 
 
 /**
@@ -30,7 +30,7 @@ import org.apache.usergrid.persistence.collection.MvccEntity;
  */
 public class MvccEntityWriteEvent extends MvccEntityEvent {
 
-    public MvccEntityWriteEvent( final CollectionScope collectionScope, final UUID version, final MvccEntity entity ) {
-        super( collectionScope, version, entity );
+    public MvccEntityWriteEvent( final ApplicationScope applicationScope, final UUID version, final MvccEntity entity ) {
+        super( applicationScope, version, entity );
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
index 20fa4be..4fc3f8e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/CollectionIoEvent.java
@@ -18,9 +18,9 @@
  */
 package org.apache.usergrid.persistence.collection.mvcc.stage;
 
+
 import java.io.Serializable;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/EntityUpdateEvent.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/EntityUpdateEvent.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/EntityUpdateEvent.java
deleted file mode 100644
index 3951226..0000000
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/EntityUpdateEvent.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.persistence.collection.mvcc.stage;
-
-
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.model.entity.Id;
-
-
-/**
- * Simple event to signal entity update
- */
-public class EntityUpdateEvent extends CollectionIoEvent<Id> {
-
-    public EntityUpdateEvent( final CollectionScope context, final Id event ) {
-        super( context, event );
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkCommit.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkCommit.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkCommit.java
index 1c5a1eb..14977eb 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkCommit.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkCommit.java
@@ -24,15 +24,14 @@ import java.util.UUID;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
 import org.apache.usergrid.persistence.collection.mvcc.entity.MvccValidationUtils;
 import org.apache.usergrid.persistence.collection.mvcc.entity.Stage;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccLogEntryImpl;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
+import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.SerializationFig;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
 import org.apache.usergrid.persistence.core.guice.ProxyImpl;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkStart.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkStart.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkStart.java
index 04059c5..4ab1b09 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkStart.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/delete/MarkStart.java
@@ -24,15 +24,14 @@ import java.util.UUID;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.exception.CollectionRuntimeException;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
+import org.apache.usergrid.persistence.collection.exception.CollectionRuntimeException;
 import org.apache.usergrid.persistence.collection.mvcc.entity.Stage;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccEntityImpl;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccLogEntryImpl;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.service.UUIDService;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.core.util.ValidationUtils;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/RollbackAction.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/RollbackAction.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/RollbackAction.java
index 0de1ab6..a54bf77 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/RollbackAction.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/RollbackAction.java
@@ -21,13 +21,12 @@ package org.apache.usergrid.persistence.collection.mvcc.stage.write;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
+import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.exception.CollectionRuntimeException;
 import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
-import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValue;
-import org.apache.usergrid.persistence.collection.serialization.impl.UniqueValueImpl;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
+import org.apache.usergrid.persistence.collection.serialization.impl.UniqueValueImpl;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.field.Field;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteCommit.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteCommit.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteCommit.java
index 50321b6..647f29e 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteCommit.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteCommit.java
@@ -23,26 +23,25 @@ import java.util.UUID;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.exception.WriteCommitException;
-import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
+import org.apache.usergrid.persistence.collection.exception.WriteCommitException;
 import org.apache.usergrid.persistence.collection.mvcc.entity.MvccValidationUtils;
 import org.apache.usergrid.persistence.collection.mvcc.entity.Stage;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccLogEntryImpl;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
+import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValue;
-import org.apache.usergrid.persistence.collection.serialization.impl.UniqueValueImpl;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
-import org.apache.usergrid.persistence.model.util.EntityUtils;
+import org.apache.usergrid.persistence.collection.serialization.impl.UniqueValueImpl;
 import org.apache.usergrid.persistence.core.guice.ProxyImpl;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.core.util.ValidationUtils;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;
 import org.apache.usergrid.persistence.model.field.Field;
+import org.apache.usergrid.persistence.model.util.EntityUtils;
 
 import com.google.common.base.Preconditions;
 import com.google.inject.Inject;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteOptimisticVerify.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteOptimisticVerify.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteOptimisticVerify.java
index 92656cc..4ced629 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteOptimisticVerify.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteOptimisticVerify.java
@@ -23,14 +23,13 @@ import java.util.List;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.exception.WriteOptimisticVerifyException;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
+import org.apache.usergrid.persistence.collection.exception.WriteOptimisticVerifyException;
 import org.apache.usergrid.persistence.collection.mvcc.entity.MvccValidationUtils;
 import org.apache.usergrid.persistence.collection.mvcc.entity.Stage;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteStart.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteStart.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteStart.java
index 453a043..26ea3cd 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteStart.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteStart.java
@@ -6,15 +6,14 @@ import java.util.UUID;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.exception.WriteStartException;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
+import org.apache.usergrid.persistence.collection.exception.WriteStartException;
 import org.apache.usergrid.persistence.collection.mvcc.entity.Stage;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccEntityImpl;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccLogEntryImpl;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteUniqueVerify.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteUniqueVerify.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteUniqueVerify.java
index 18c221c..b984ad8 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteUniqueVerify.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/mvcc/stage/write/WriteUniqueVerify.java
@@ -23,20 +23,11 @@ import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
-import com.netflix.astyanax.model.ConsistencyLevel;
-import com.netflix.hystrix.HystrixCommand;
-import com.netflix.hystrix.HystrixCommandGroupKey;
-import com.netflix.hystrix.HystrixThreadPoolProperties;
-
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
-import org.apache.usergrid.persistence.model.util.EntityUtils;
-import org.apache.usergrid.persistence.core.astyanax.CassandraConfig;
-
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import org.apache.usergrid.persistence.collection.exception.WriteUniqueVerifyException;
 import org.apache.usergrid.persistence.collection.MvccEntity;
+import org.apache.usergrid.persistence.collection.exception.WriteUniqueVerifyException;
 import org.apache.usergrid.persistence.collection.mvcc.entity.MvccValidationUtils;
 import org.apache.usergrid.persistence.collection.mvcc.stage.CollectionIoEvent;
 import org.apache.usergrid.persistence.collection.serialization.SerializationFig;
@@ -44,9 +35,12 @@ import org.apache.usergrid.persistence.collection.serialization.UniqueValue;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.UniqueValueSet;
 import org.apache.usergrid.persistence.collection.serialization.impl.UniqueValueImpl;
+import org.apache.usergrid.persistence.core.astyanax.CassandraConfig;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;
 import org.apache.usergrid.persistence.model.field.Field;
+import org.apache.usergrid.persistence.model.util.EntityUtils;
 
 import com.google.common.base.Preconditions;
 import com.google.inject.Inject;
@@ -54,6 +48,10 @@ import com.google.inject.Singleton;
 import com.netflix.astyanax.Keyspace;
 import com.netflix.astyanax.MutationBatch;
 import com.netflix.astyanax.connectionpool.exceptions.ConnectionException;
+import com.netflix.astyanax.model.ConsistencyLevel;
+import com.netflix.hystrix.HystrixCommand;
+import com.netflix.hystrix.HystrixCommandGroupKey;
+import com.netflix.hystrix.HystrixThreadPoolProperties;
 
 import rx.functions.Action1;
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/MvccEntitySerializationStrategy.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/MvccEntitySerializationStrategy.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/MvccEntitySerializationStrategy.java
index beb5621..fab0db6 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/MvccEntitySerializationStrategy.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/MvccEntitySerializationStrategy.java
@@ -23,7 +23,6 @@ import java.util.Collection;
 import java.util.Iterator;
 import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.collection.EntitySet;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.core.migration.data.VersionedData;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValue.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValue.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValue.java
index 2ba927c..41d9285 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValue.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValue.java
@@ -20,7 +20,6 @@ package org.apache.usergrid.persistence.collection.serialization;
 
 import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.model.entity.Id;
 import org.apache.usergrid.persistence.model.field.Field;
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSerializationStrategy.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSerializationStrategy.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSerializationStrategy.java
index 8cee99d..71af460 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSerializationStrategy.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSerializationStrategy.java
@@ -21,15 +21,15 @@ package org.apache.usergrid.persistence.collection.serialization;
 import java.util.Collection;
 import java.util.Iterator;
 
-import com.netflix.astyanax.MutationBatch;
-import com.netflix.astyanax.connectionpool.exceptions.ConnectionException;
-import com.netflix.astyanax.model.ConsistencyLevel;
-import org.apache.usergrid.persistence.collection.CollectionScope;
 import org.apache.usergrid.persistence.core.migration.schema.Migration;
 import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Id;
 import org.apache.usergrid.persistence.model.field.Field;
 
+import com.netflix.astyanax.MutationBatch;
+import com.netflix.astyanax.connectionpool.exceptions.ConnectionException;
+import com.netflix.astyanax.model.ConsistencyLevel;
+
 
 /**
  * Reads and writes to UniqueValues column family.

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSet.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSet.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSet.java
index 702e908..4fb163b 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSet.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/UniqueValueSet.java
@@ -18,9 +18,6 @@ package org.apache.usergrid.persistence.collection.serialization;/*
  */
 
 
-import java.util.Set;
-
-
 /**
  * A read only view of unique values
  */

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/EntityVersionSerializer.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/EntityVersionSerializer.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/EntityVersionSerializer.java
index 4fd3b33..97bad7a 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/EntityVersionSerializer.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/EntityVersionSerializer.java
@@ -21,9 +21,6 @@ package org.apache.usergrid.persistence.collection.serialization.impl;
 import java.nio.ByteBuffer;
 import java.util.UUID;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
 import org.apache.usergrid.persistence.model.entity.Id;
 import org.apache.usergrid.persistence.model.entity.SimpleId;
 
@@ -36,7 +33,7 @@ import com.netflix.astyanax.serializers.StringSerializer;
 import com.netflix.astyanax.serializers.UUIDSerializer;
 
 /**
- * Serialize EntityVersion, entity ID and version, for use a column name in Unique Values Column Family. 
+ * Serialize EntityVersion, entity ID and version, for use a column name in Unique Values Column Family.
  */
 public class EntityVersionSerializer extends AbstractSerializer<EntityVersion> {
 
@@ -69,8 +66,8 @@ public class EntityVersionSerializer extends AbstractSerializer<EntityVersion> {
         final UUID version      = composite.get( 0, UUIDSerializer.get() );
         final UUID entityId     = composite.get( 1, UUIDSerializer.get() );
         final String entityType = composite.get( 2, StringSerializer.get() );
-        
+
         return new EntityVersion( new SimpleId( entityId, entityType ), version);
     }
-    
+
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/LogEntryIterator.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/LogEntryIterator.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/LogEntryIterator.java
index 3ecc61d..e5c2896 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/LogEntryIterator.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/LogEntryIterator.java
@@ -6,9 +6,9 @@ import java.util.List;
 import java.util.NoSuchElementException;
 import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.CollectionScope;
-import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
 import org.apache.usergrid.persistence.collection.MvccLogEntry;
+import org.apache.usergrid.persistence.collection.serialization.MvccLogEntrySerializationStrategy;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Id;
 
 import com.google.common.base.Preconditions;
@@ -22,7 +22,7 @@ public class LogEntryIterator implements Iterator<MvccLogEntry> {
 
 
     private final MvccLogEntrySerializationStrategy logEntrySerializationStrategy;
-    private final CollectionScope scope;
+    private final ApplicationScope scope;
     private final Id entityId;
     private final int pageSize;
 
@@ -40,7 +40,7 @@ public class LogEntryIterator implements Iterator<MvccLogEntry> {
      * @param pageSize The fetch size to get when querying the serialization strategy
      */
     public LogEntryIterator( final MvccLogEntrySerializationStrategy logEntrySerializationStrategy,
-                             final CollectionScope scope, final Id entityId, final UUID maxVersion,
+                             final ApplicationScope scope, final Id entityId, final UUID maxVersion,
                              final int pageSize ) {
 
         Preconditions.checkArgument( pageSize > 0, "pageSize must be > 0" );

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MutableFieldSet.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MutableFieldSet.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MutableFieldSet.java
index ae921a7..df2b850 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MutableFieldSet.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MutableFieldSet.java
@@ -18,13 +18,13 @@ package org.apache.usergrid.persistence.collection.serialization.impl;/*
  */
 
 
+import java.util.HashMap;
+import java.util.Map;
+
 import org.apache.usergrid.persistence.collection.FieldSet;
 import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.model.field.Field;
 
-import java.util.HashMap;
-import java.util.Map;
-
 
 public class MutableFieldSet implements FieldSet {
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6bf2d3d2/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MvccEntitySerializationStrategyImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MvccEntitySerializationStrategyImpl.java b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MvccEntitySerializationStrategyImpl.java
index 5b324db..6fa539a 100644
--- a/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MvccEntitySerializationStrategyImpl.java
+++ b/stack/corepersistence/collection/src/main/java/org/apache/usergrid/persistence/collection/serialization/impl/MvccEntitySerializationStrategyImpl.java
@@ -25,7 +25,6 @@ import java.util.Iterator;
 import java.util.List;
 import java.util.UUID;
 
-import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -38,18 +37,19 @@ import org.apache.usergrid.persistence.collection.MvccEntity;
 import org.apache.usergrid.persistence.collection.exception.CollectionRuntimeException;
 import org.apache.usergrid.persistence.collection.exception.DataCorruptionException;
 import org.apache.usergrid.persistence.collection.mvcc.entity.impl.MvccEntityImpl;
+import org.apache.usergrid.persistence.collection.serialization.MvccEntitySerializationStrategy;
 import org.apache.usergrid.persistence.collection.serialization.SerializationFig;
 import org.apache.usergrid.persistence.collection.serialization.impl.util.LegacyScopeUtils;
-import org.apache.usergrid.persistence.core.scope.ApplicationScope;
-import org.apache.usergrid.persistence.model.util.EntityUtils;
 import org.apache.usergrid.persistence.core.astyanax.CassandraFig;
 import org.apache.usergrid.persistence.core.astyanax.ColumnNameIterator;
 import org.apache.usergrid.persistence.core.astyanax.ColumnParser;
 import org.apache.usergrid.persistence.core.astyanax.MultiTennantColumnFamily;
 import org.apache.usergrid.persistence.core.astyanax.MultiTennantColumnFamilyDefinition;
 import org.apache.usergrid.persistence.core.astyanax.ScopedRowKey;
+import org.apache.usergrid.persistence.core.scope.ApplicationScope;
 import org.apache.usergrid.persistence.model.entity.Entity;
 import org.apache.usergrid.persistence.model.entity.Id;
+import org.apache.usergrid.persistence.model.util.EntityUtils;
 import org.apache.usergrid.persistence.model.util.UUIDGenerator;
 
 import com.google.common.base.Optional;
@@ -62,14 +62,11 @@ import com.netflix.astyanax.connectionpool.exceptions.ConnectionException;
 import com.netflix.astyanax.model.Column;
 import com.netflix.astyanax.model.ColumnList;
 import com.netflix.astyanax.model.Row;
-import com.netflix.astyanax.model.Rows;
 import com.netflix.astyanax.query.RowQuery;
 import com.netflix.astyanax.serializers.AbstractSerializer;
 
 import rx.Observable;
 import rx.Scheduler;
-import rx.functions.Func1;
-import rx.functions.Func2;
 import rx.schedulers.Schedulers;
 
 


Mime
View raw message