You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@polygene.apache.org by ni...@apache.org on 2016/08/27 11:10:17 UTC
zest-java git commit: ZEST-158,
ZEST-165 - Fixing for Memory ES generation.
Repository: zest-java
Updated Branches:
refs/heads/develop a218171a6 -> d72bd89aa
ZEST-158, ZEST-165 - Fixing for Memory ES generation.
Project: http://git-wip-us.apache.org/repos/asf/zest-java/repo
Commit: http://git-wip-us.apache.org/repos/asf/zest-java/commit/d72bd89a
Tree: http://git-wip-us.apache.org/repos/asf/zest-java/tree/d72bd89a
Diff: http://git-wip-us.apache.org/repos/asf/zest-java/diff/d72bd89a
Branch: refs/heads/develop
Commit: d72bd89aa77db87f372cc57cf5dddbe71919569c
Parents: a218171
Author: Niclas Hedhman <ni...@hedhman.org>
Authored: Sat Aug 27 19:10:06 2016 +0800
Committer: Niclas Hedhman <ni...@hedhman.org>
Committed: Sat Aug 27 19:10:06 2016 +0800
----------------------------------------------------------------------
.../memory/MemoryEntityStoreAssembler.java | 45 -------------------
.../assembly/MemoryEntityStoreAssembler.java | 46 ++++++++++++++++++++
.../memory/MemoryEntityStoreTest.java | 1 +
.../memory/MemoryEntityStoreWithCacheTest.java | 1 +
.../sample/forum/assembler/ForumAssembler.java | 2 +-
5 files changed, 49 insertions(+), 46 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/zest-java/blob/d72bd89a/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/MemoryEntityStoreAssembler.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/MemoryEntityStoreAssembler.java b/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/MemoryEntityStoreAssembler.java
deleted file mode 100644
index 8000834..0000000
--- a/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/MemoryEntityStoreAssembler.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.zest.entitystore.memory;
-
-import org.apache.zest.bootstrap.Assemblers;
-import org.apache.zest.bootstrap.AssemblyException;
-import org.apache.zest.bootstrap.ModuleAssembly;
-import org.apache.zest.bootstrap.ServiceDeclaration;
-import org.apache.zest.spi.uuid.UuidIdentityGeneratorService;
-
-/**
- * Assemble an in-memory EntityStore.
- */
-public class MemoryEntityStoreAssembler
- extends Assemblers.VisibilityIdentity<MemoryEntityStoreAssembler>
-{
- @Override
- public void assemble( ModuleAssembly module )
- throws AssemblyException
- {
- module.services( UuidIdentityGeneratorService.class ).visibleIn( visibility() );
- ServiceDeclaration service = module.services( MemoryEntityStoreService.class ).visibleIn( visibility() );
- if( hasIdentity() )
- {
- service.identifiedBy( identity() );
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/zest-java/blob/d72bd89a/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/assembly/MemoryEntityStoreAssembler.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/assembly/MemoryEntityStoreAssembler.java b/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/assembly/MemoryEntityStoreAssembler.java
new file mode 100644
index 0000000..d6b09d1
--- /dev/null
+++ b/extensions/entitystore-memory/src/main/java/org/apache/zest/entitystore/memory/assembly/MemoryEntityStoreAssembler.java
@@ -0,0 +1,46 @@
+/*
+ * 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.zest.entitystore.memory.assembly;
+
+import org.apache.zest.bootstrap.Assemblers;
+import org.apache.zest.bootstrap.AssemblyException;
+import org.apache.zest.bootstrap.ModuleAssembly;
+import org.apache.zest.bootstrap.ServiceDeclaration;
+import org.apache.zest.entitystore.memory.MemoryEntityStoreService;
+import org.apache.zest.spi.uuid.UuidIdentityGeneratorService;
+
+/**
+ * Assemble an in-memory EntityStore.
+ */
+public class MemoryEntityStoreAssembler
+ extends Assemblers.VisibilityIdentityConfig<MemoryEntityStoreAssembler>
+{
+ @Override
+ public void assemble( ModuleAssembly module )
+ throws AssemblyException
+ {
+ module.services( UuidIdentityGeneratorService.class ).visibleIn( visibility() );
+ ServiceDeclaration service = module.services( MemoryEntityStoreService.class ).visibleIn( visibility() );
+ if( hasIdentity() )
+ {
+ service.identifiedBy( identity() );
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/zest-java/blob/d72bd89a/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreTest.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreTest.java b/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreTest.java
index ad192f4..3528857 100644
--- a/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreTest.java
+++ b/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreTest.java
@@ -21,6 +21,7 @@ package org.apache.zest.entitystore.memory;
import org.apache.zest.bootstrap.AssemblyException;
import org.apache.zest.bootstrap.ModuleAssembly;
+import org.apache.zest.entitystore.memory.assembly.MemoryEntityStoreAssembler;
import org.apache.zest.test.entity.AbstractEntityStoreTest;
import org.apache.zest.valueserialization.orgjson.OrgJsonValueSerializationAssembler;
http://git-wip-us.apache.org/repos/asf/zest-java/blob/d72bd89a/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreWithCacheTest.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreWithCacheTest.java b/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreWithCacheTest.java
index 85c829b..94f588c 100644
--- a/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreWithCacheTest.java
+++ b/extensions/entitystore-memory/src/test/java/org/apache/zest/entitystore/memory/MemoryEntityStoreWithCacheTest.java
@@ -21,6 +21,7 @@ package org.apache.zest.entitystore.memory;
import org.apache.zest.bootstrap.AssemblyException;
import org.apache.zest.bootstrap.ModuleAssembly;
+import org.apache.zest.entitystore.memory.assembly.MemoryEntityStoreAssembler;
import org.apache.zest.test.cache.AbstractEntityStoreWithCacheTest;
import org.apache.zest.valueserialization.orgjson.OrgJsonValueSerializationAssembler;
http://git-wip-us.apache.org/repos/asf/zest-java/blob/d72bd89a/samples/forum/src/main/java/org/apache/zest/sample/forum/assembler/ForumAssembler.java
----------------------------------------------------------------------
diff --git a/samples/forum/src/main/java/org/apache/zest/sample/forum/assembler/ForumAssembler.java b/samples/forum/src/main/java/org/apache/zest/sample/forum/assembler/ForumAssembler.java
index c47345e..6ef446f 100644
--- a/samples/forum/src/main/java/org/apache/zest/sample/forum/assembler/ForumAssembler.java
+++ b/samples/forum/src/main/java/org/apache/zest/sample/forum/assembler/ForumAssembler.java
@@ -32,7 +32,7 @@ import org.apache.zest.bootstrap.ClassScanner;
import org.apache.zest.bootstrap.LayerAssembly;
import org.apache.zest.bootstrap.ModuleAssembly;
import org.apache.zest.entitystore.file.assembly.FileEntityStoreAssembler;
-import org.apache.zest.entitystore.memory.MemoryEntityStoreAssembler;
+import org.apache.zest.entitystore.memory.assembly.MemoryEntityStoreAssembler;
import org.apache.zest.index.rdf.assembly.RdfNativeSesameStoreAssembler;
import org.apache.zest.library.fileconfig.FileConfigurationAssembler;
import org.apache.zest.library.rdf.repository.NativeConfiguration;