usergrid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From toddn...@apache.org
Subject [32/33] incubator-usergrid git commit: Merge branch 'two-dot-o-dev' of https://git-wip-us.apache.org/repos/asf/incubator-usergrid into USERGRID-536
Date Mon, 13 Apr 2015 19:18:39 GMT
Merge branch 'two-dot-o-dev' of https://git-wip-us.apache.org/repos/asf/incubator-usergrid
into USERGRID-536


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

Branch: refs/heads/two-dot-o-dev
Commit: 641804790ee9a9465d854d9d0179274a90f064d7
Parents: 2eac3be de740a1
Author: Todd Nine <tnine@apigee.com>
Authored: Mon Apr 13 11:44:56 2015 -0600
Committer: Todd Nine <tnine@apigee.com>
Committed: Mon Apr 13 11:45:12 2015 -0600

----------------------------------------------------------------------
 .../corepersistence/ApplicationIdCache.java     |   3 +-
 .../ApplicationIdCacheFactory.java              |  43 ++
 .../corepersistence/ApplicationIdCacheFig.java  |  43 ++
 .../corepersistence/ApplicationIdCacheImpl.java |  95 +++--
 .../usergrid/corepersistence/CoreModule.java    |   7 +-
 .../corepersistence/CpEntityManager.java        |  25 +-
 .../corepersistence/CpEntityManagerFactory.java | 229 ++++++-----
 .../corepersistence/CpRelationManager.java      |  33 +-
 .../CpRelationManagerFactory.java               |  46 +++
 .../migration/AppInfoMigrationPlugin.java       | 250 +++++-------
 .../usergrid/persistence/EntityManager.java     |  10 +
 .../persistence/EntityManagerFactory.java       |  72 ++--
 .../org/apache/usergrid/CoreApplication.java    |  43 +-
 .../org/apache/usergrid/CoreITSetupImpl.java    |   9 +-
 .../usergrid/persistence/CollectionIT.java      |   1 +
 .../cassandra/EntityManagerFactoryImplIT.java   | 103 +++--
 .../persistence/query/IteratingQueryIT.java     |   9 +-
 .../serialization/impl/TypeField.java           |  43 ++
 .../impl/UniqueTypeFieldRowKeySerializer.java   |  60 +++
 .../UniqueValueSerializationStrategyV2Impl.java |  16 +-
 .../collection/EntityCollectionManagerIT.java   |  79 ++--
 .../apache/usergrid/mongo/BasicMongoTest.java   |   8 +-
 .../apache/usergrid/mongo/MongoQueryTest.java   |  18 +-
 .../org/apache/usergrid/rest/ApiResponse.java   |  50 ++-
 .../exceptions/AbstractExceptionMapper.java     |  11 +-
 .../rest/exceptions/UncaughtException.java      |  36 ++
 .../rest/management/ManagementResource.java     |  59 ++-
 .../organizations/OrganizationsResource.java    |  23 +-
 .../organizations/OrganizationResource.java     |  11 +-
 .../rest/test/RefreshIndexResource.java         |  16 +-
 .../apache/usergrid/rest/NotificationsIT.java   |  93 ++---
 .../rest/applications/ApplicationCreateIT.java  | 135 +++++++
 .../rest/applications/ApplicationDeleteIT.java  | 389 +++++++++++++++++++
 .../applications/ApplicationDeleteTest.java     | 387 ------------------
 .../applications/ApplicationResourceIT.java     |  37 +-
 .../collection/paging/PagingResourceIT.java     |  17 +-
 .../applications/queries/MatrixQueryTests.java  | 298 +++++++-------
 .../rest/filters/ContentTypeResourceIT.java     |  55 ++-
 .../rest/management/ExportResourceIT.java       |  26 +-
 .../rest/management/ImportResourceIT.java       |  10 +
 .../rest/management/OrganizationsIT.java        |  72 ++--
 .../endpoints/CollectionEndpoint.java           |  13 +
 .../endpoints/NamedResource.java                |  60 ++-
 .../cassandra/ApplicationCreatorImpl.java       |  12 +-
 .../cassandra/ManagementServiceImpl.java        |  16 +-
 .../apns/FailedConnectionListener.java          |  31 +-
 .../org/apache/usergrid/ServiceApplication.java |   2 +-
 .../org/apache/usergrid/ServiceITSetup.java     |   2 +
 .../org/apache/usergrid/ServiceITSetupImpl.java |  11 +-
 .../migration/AppInfoMigrationPluginTest.java   |  31 +-
 .../apache/usergrid/management/EmailFlowIT.java |   3 +-
 .../usergrid/management/OrganizationIT.java     |   6 +-
 .../cassandra/ApplicationCreatorIT.java         |  10 +-
 .../usergrid/services/CollectionServiceIT.java  |   2 +
 54 files changed, 1894 insertions(+), 1275 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/main/java/org/apache/usergrid/corepersistence/ApplicationIdCacheImpl.java
----------------------------------------------------------------------
diff --cc stack/core/src/main/java/org/apache/usergrid/corepersistence/ApplicationIdCacheImpl.java
index 5f85080,8247ead..f4b5a9a
--- a/stack/core/src/main/java/org/apache/usergrid/corepersistence/ApplicationIdCacheImpl.java
+++ b/stack/core/src/main/java/org/apache/usergrid/corepersistence/ApplicationIdCacheImpl.java
@@@ -23,17 -23,22 +23,25 @@@ package org.apache.usergrid.corepersist
  import com.google.common.cache.CacheBuilder;
  import com.google.common.cache.CacheLoader;
  import com.google.common.cache.LoadingCache;
++
+ import org.apache.usergrid.corepersistence.util.CpNamingUtils;
+ import org.apache.usergrid.persistence.EntityManager;
 +import org.apache.usergrid.persistence.Query;
+ import org.apache.usergrid.persistence.Schema;
+ import org.apache.usergrid.persistence.collection.EntityCollectionManager;
+ import org.apache.usergrid.persistence.core.scope.ApplicationScopeImpl;
+ import org.apache.usergrid.persistence.model.entity.Id;
+ import org.apache.usergrid.persistence.model.entity.SimpleId;
+ import org.apache.usergrid.persistence.model.field.StringField;
 +import org.apache.usergrid.utils.UUIDUtils;
  import org.slf4j.Logger;
  import org.slf4j.LoggerFactory;
+ import rx.Observable;
+ 
+ import com.google.common.base.Optional;
+ import java.util.UUID;
+ import java.util.concurrent.TimeUnit;
+ 
  
  
  /**

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/main/java/org/apache/usergrid/corepersistence/CpEntityManager.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/main/java/org/apache/usergrid/corepersistence/CpEntityManagerFactory.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/main/java/org/apache/usergrid/corepersistence/CpRelationManager.java
----------------------------------------------------------------------
diff --cc stack/core/src/main/java/org/apache/usergrid/corepersistence/CpRelationManager.java
index 5044298,67a1f19..e100924
--- a/stack/core/src/main/java/org/apache/usergrid/corepersistence/CpRelationManager.java
+++ b/stack/core/src/main/java/org/apache/usergrid/corepersistence/CpRelationManager.java
@@@ -151,16 -215,22 +149,15 @@@ public class CpRelationManager implemen
          this.applicationId = applicationId;
          this.headEntity = headEntity;
          this.managerCache = emf.getManagerCache();
 -        this.applicationScope = CpNamingUtils.getApplicationScope(applicationId);
 -        this.cass = em.getCass(); // TODO: eliminate need for this via Core Persistence
 -        this.indexBucketLocator = indexBucketLocator; // TODO: this also
 +        this.applicationScope = CpNamingUtils.getApplicationScope( applicationId );
 +
          this.metricsFactory = metricsFactory;
          this.updateCollectionTimer = metricsFactory
 -            .getTimer(CpRelationManager.class, "relation.manager.es.update.collection");
 -        this.createConnectionTimer = metricsFactory
 -            .getTimer(CpRelationManager.class, "relation.manager.es.create.connection.timer");
 -        this.cassConnectionDelete = metricsFactory
 -            .getTimer(CpRelationManager.class, "relation.manager.cassandra.delete.connection.batch.timer");
 -        this.esDeleteConnectionTimer = metricsFactory.getTimer(CpRelationManager.class,
 -            "relation.manager.es.delete.connection.batch.timer");
 +            .getTimer( CpRelationManager.class, "relation.manager.es.update.collection"
);
  
- 
-         if ( logger.isDebugEnabled() ) {
-             logger.debug( "Loading head entity {}:{} from app {}",
-                 new Object[] {
+         if (logger.isDebugEnabled()) {
+             logger.debug("Loading head entity {}:{} from app {}",
+                 new Object[]{
                      headEntity.getType(),
                      headEntity.getUuid(),
                      applicationScope

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/main/java/org/apache/usergrid/persistence/EntityManager.java
----------------------------------------------------------------------
diff --cc stack/core/src/main/java/org/apache/usergrid/persistence/EntityManager.java
index fdae4df,d070756..7929b12
--- a/stack/core/src/main/java/org/apache/usergrid/persistence/EntityManager.java
+++ b/stack/core/src/main/java/org/apache/usergrid/persistence/EntityManager.java
@@@ -30,9 -34,9 +30,10 @@@ import org.apache.usergrid.persistence.
  import org.apache.usergrid.persistence.entities.Role;
  import org.apache.usergrid.persistence.index.query.CounterResolution;
  import org.apache.usergrid.persistence.index.query.Identifier;
 -import org.apache.usergrid.persistence.index.query.Query.Level;
+ import org.apache.usergrid.persistence.model.entity.Id;
  
 +import me.prettyprint.hector.api.mutation.Mutator;
 +
  
  /**
   * The interface class for the data access object for Applications. Each application contains
a set of users as well as

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/test/java/org/apache/usergrid/CoreApplication.java
----------------------------------------------------------------------
diff --cc stack/core/src/test/java/org/apache/usergrid/CoreApplication.java
index d3861a6,266388f..a5b8da2
--- a/stack/core/src/test/java/org/apache/usergrid/CoreApplication.java
+++ b/stack/core/src/test/java/org/apache/usergrid/CoreApplication.java
@@@ -23,7 -24,17 +24,10 @@@ import java.util.UUID
  import java.util.concurrent.ExecutionException;
  
  import com.google.inject.Injector;
- import org.apache.usergrid.persistence.index.EntityIndex;
+ import org.apache.usergrid.corepersistence.util.CpNamingUtils;
 -import org.apache.usergrid.persistence.*;
 -import org.apache.usergrid.persistence.core.scope.ApplicationScopeImpl;
 -import org.apache.usergrid.persistence.geo.GeoIndexSearcher;
+ import org.apache.usergrid.persistence.index.*;
 -import org.apache.usergrid.persistence.index.impl.IndexScopeImpl;
 -import org.apache.usergrid.persistence.index.impl.IndexingUtils;
 -import org.apache.usergrid.persistence.index.query.CandidateResults;
 -import org.apache.usergrid.persistence.index.utils.UUIDUtils;
+ import org.apache.usergrid.persistence.model.entity.Id;
+ import org.apache.usergrid.persistence.model.entity.SimpleId;
  import org.junit.rules.TestRule;
  import org.junit.runner.Description;
  import org.junit.runners.model.Statement;

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/test/java/org/apache/usergrid/CoreITSetupImpl.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/test/java/org/apache/usergrid/persistence/CollectionIT.java
----------------------------------------------------------------------
diff --cc stack/core/src/test/java/org/apache/usergrid/persistence/CollectionIT.java
index 669c380,6780d1d..ac37bfd
--- a/stack/core/src/test/java/org/apache/usergrid/persistence/CollectionIT.java
+++ b/stack/core/src/test/java/org/apache/usergrid/persistence/CollectionIT.java
@@@ -314,9 -323,11 +314,10 @@@ public class CollectionIT extends Abstr
          assertNotNull( user );
  
          app.refreshIndex();
+         Thread.sleep(100);
  
          // EntityRef
 -        Query query = new Query();
 -        query.addEqualityFilter( "lastname", lastName );
 +        final Query query = Query.fromQL( "lastname = '" + lastName + "'" );
  
          Results r = em.searchCollection( em.getApplicationRef(), "users", query );
  

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/core/src/test/java/org/apache/usergrid/persistence/query/IteratingQueryIT.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/services/src/main/java/org/apache/usergrid/management/cassandra/ManagementServiceImpl.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/64180479/stack/services/src/test/java/org/apache/usergrid/corepersistence/migration/AppInfoMigrationPluginTest.java
----------------------------------------------------------------------
diff --cc stack/services/src/test/java/org/apache/usergrid/corepersistence/migration/AppInfoMigrationPluginTest.java
index 8c4924e,be999c8..a51630c
--- a/stack/services/src/test/java/org/apache/usergrid/corepersistence/migration/AppInfoMigrationPluginTest.java
+++ b/stack/services/src/test/java/org/apache/usergrid/corepersistence/migration/AppInfoMigrationPluginTest.java
@@@ -27,9 -28,12 +28,11 @@@ import org.apache.usergrid.corepersiste
  import org.apache.usergrid.management.OrganizationOwnerInfo;
  import org.apache.usergrid.persistence.*;
  import org.apache.usergrid.persistence.cassandra.CassandraService;
+ import org.apache.usergrid.persistence.collection.EntityCollectionManagerFactory;
+ import org.apache.usergrid.persistence.core.migration.data.MigrationInfoSerialization;
  import org.apache.usergrid.persistence.core.migration.data.ProgressObserver;
  import org.apache.usergrid.persistence.entities.Application;
- import org.apache.usergrid.persistence.Query;
+ import org.apache.usergrid.persistence.graph.GraphManagerFactory;
 -import org.apache.usergrid.persistence.index.query.Query;
  import org.junit.ClassRule;
  import org.junit.Rule;
  import org.junit.Test;


Mime
View raw message