You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by sf...@apache.org on 2015/03/31 23:01:14 UTC
[36/50] incubator-usergrid git commit: fix indexcacheimpl
fix indexcacheimpl
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/6a39add9
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/6a39add9
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/6a39add9
Branch: refs/heads/USERGRID-473
Commit: 6a39add920a052bf629c86df3d30615f59e0c22d
Parents: b98cdce
Author: Shawn Feldman <sf...@apache.org>
Authored: Thu Mar 26 16:04:00 2015 -0600
Committer: Shawn Feldman <sf...@apache.org>
Committed: Thu Mar 26 16:04:00 2015 -0600
----------------------------------------------------------------------
.../serialization/impl/migration/EdgeDataMigrationImpl.java | 2 ++
.../usergrid/persistence/index/impl/IndexMigrationTest.java | 8 +-------
2 files changed, 3 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6a39add9/stack/corepersistence/graph/src/main/java/org/apache/usergrid/persistence/graph/serialization/impl/migration/EdgeDataMigrationImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/graph/src/main/java/org/apache/usergrid/persistence/graph/serialization/impl/migration/EdgeDataMigrationImpl.java b/stack/corepersistence/graph/src/main/java/org/apache/usergrid/persistence/graph/serialization/impl/migration/EdgeDataMigrationImpl.java
index ecb9a9b..411e318 100644
--- a/stack/corepersistence/graph/src/main/java/org/apache/usergrid/persistence/graph/serialization/impl/migration/EdgeDataMigrationImpl.java
+++ b/stack/corepersistence/graph/src/main/java/org/apache/usergrid/persistence/graph/serialization/impl/migration/EdgeDataMigrationImpl.java
@@ -88,6 +88,8 @@ public class EdgeDataMigrationImpl implements DataMigration<GraphNode> {
final Observable<List<Edge>> observable = migrationDataProvider.getData().flatMap( graphNode -> {
final GraphManager gm = graphManagerFactory.createEdgeManager( graphNode.applicationScope );
+ //TODO: maybe move to retreive all indexes : https://github.com/elastic/elasticsearch/blob/master/src/main/java/org/elasticsearch/rest/action/cat/RestIndicesAction.java
+ //https://www.google.com/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=get%20all%20indexes%20elasticsearch
//get edges from the source
return edgesFromSourceObservable.edgesFromSource( gm, graphNode.entryNode ).buffer( 1000 )
.doOnNext( edges -> {
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/6a39add9/stack/corepersistence/queryindex/src/test/java/org/apache/usergrid/persistence/index/impl/IndexMigrationTest.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/queryindex/src/test/java/org/apache/usergrid/persistence/index/impl/IndexMigrationTest.java b/stack/corepersistence/queryindex/src/test/java/org/apache/usergrid/persistence/index/impl/IndexMigrationTest.java
index 47d81ed..1203e38 100644
--- a/stack/corepersistence/queryindex/src/test/java/org/apache/usergrid/persistence/index/impl/IndexMigrationTest.java
+++ b/stack/corepersistence/queryindex/src/test/java/org/apache/usergrid/persistence/index/impl/IndexMigrationTest.java
@@ -60,9 +60,6 @@ public class IndexMigrationTest extends BaseIT{
public EsProvider provider;
@Inject
- public MigrationDataProvider<ApplicationScope> applicationScopeMigrationDataProvider;
-
- @Inject
public AliasedEntityIndex ei;
@Inject
public IndexBufferProducer indexBatchBufferProducer;
@@ -98,12 +95,9 @@ public class IndexMigrationTest extends BaseIT{
}
};
- final ApplicationScope appScope = new ApplicationScopeImpl(new SimpleId(UUID.randomUUID(),"application"));
-
- LegacyIndexIdentifier legacyIndexIdentifier = new LegacyIndexIdentifier(fig,appScope);
TestIndexModule.TestAllApplicationsObservable obs = new TestIndexModule.TestAllApplicationsObservable(indexBatchBufferProducer,provider,indexCache,metricsFactory,fig);
- int version = indexDataMigration.migrate(0, applicationScopeMigrationDataProvider, po );
+ int version = indexDataMigration.migrate(0, obs, po );
assertEquals(version, IndexDataVersions.SINGLE_INDEX.getVersion());
}
}