Repository: polygene-java Updated Branches: refs/heads/serialization-3.0 [created] e4cca11ec
http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/configuration/ConfigurationModule.java ---------------------------------------------------------------------- diff --git a/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/configuration/ConfigurationModule.java b/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/configuration/ConfigurationModule.java index 87f5241..1050e8a 100644 --- a/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/configuration/ConfigurationModule.java +++ b/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/configuration/ConfigurationModule.java @@ -26,7 +26,6 @@ import org.apache.polygene.bootstrap.LayerAssembly; import org.apache.polygene.bootstrap.ModuleAssembly; import org.apache.polygene.bootstrap.layered.ModuleAssembler; import org.apache.polygene.entitystore.memory.MemoryEntityStoreService; -import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationAssembler; public class ConfigurationModule implements ModuleAssembler @@ -37,7 +36,6 @@ public class ConfigurationModule throws AssemblyException { module.services( MemoryEntityStoreService.class ).visibleIn( Visibility.layer ); - new JacksonValueSerializationAssembler().visibleIn( Visibility.layer ).assemble( module ); return module; } } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/infrastructue/SerializationModule.java ---------------------------------------------------------------------- diff --git a/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/infrastructue/SerializationModule.java b/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/infrastructue/SerializationModule.java index 736edaa..275cb27 100644 --- a/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/infrastructue/SerializationModule.java +++ b/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/assembly/infrastructue/SerializationModule.java @@ -20,12 +20,10 @@ package org.apache.polygene.library.restlet.assembly.infrastructue; -import org.apache.polygene.api.common.Visibility; import org.apache.polygene.bootstrap.AssemblyException; import org.apache.polygene.bootstrap.LayerAssembly; import org.apache.polygene.bootstrap.ModuleAssembly; import org.apache.polygene.bootstrap.layered.ModuleAssembler; -import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationAssembler; public class SerializationModule implements ModuleAssembler @@ -36,9 +34,6 @@ public class SerializationModule public ModuleAssembly assemble( LayerAssembly layer, ModuleAssembly module ) throws AssemblyException { - new JacksonValueSerializationAssembler() - .visibleIn( Visibility.layer ) - .assemble( module ); return module; } } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/serialization/JsonRepresentation.java ---------------------------------------------------------------------- diff --git a/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/serialization/JsonRepresentation.java b/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/serialization/JsonRepresentation.java index 74acdf8..ea0929b 100644 --- a/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/serialization/JsonRepresentation.java +++ b/libraries/restlet/src/main/java/org/apache/polygene/library/restlet/serialization/JsonRepresentation.java @@ -21,14 +21,15 @@ package org.apache.polygene.library.restlet.serialization; import java.io.IOException; +import java.io.InputStreamReader; import java.io.OutputStream; +import java.io.OutputStreamWriter; import org.apache.polygene.api.common.Optional; import org.apache.polygene.api.injection.scope.Service; import org.apache.polygene.api.injection.scope.Structure; import org.apache.polygene.api.injection.scope.Uses; +import org.apache.polygene.api.serialization.Serialization; import org.apache.polygene.api.structure.ModuleDescriptor; -import org.apache.polygene.api.value.ValueSerialization; -import org.apache.polygene.api.value.ValueSerializer; import org.apache.polygene.spi.PolygeneSPI; import org.restlet.data.MediaType; import org.restlet.representation.OutputRepresentation; @@ -42,13 +43,11 @@ import org.restlet.representation.Representation; public class JsonRepresentation<T> extends OutputRepresentation { - private static final ValueSerializer.Options OPTIONS_NO_TYPE = new ValueSerializer.Options().withoutTypeInfo().withMapEntriesAsObjects(); - @Structure private PolygeneSPI spi; @Service - private ValueSerialization serializer; + private Serialization stateSerialization; @Structure private ModuleDescriptor module; @@ -98,7 +97,8 @@ public class JsonRepresentation<T> extends OutputRepresentation } else if( this.representation != null ) { - result = serializer.deserialize( module, objectClass, this.representation.getStream() ); + result = stateSerialization.deserialize( module, objectClass, + new InputStreamReader( this.representation.getStream() ) ); } return result; } @@ -123,7 +123,8 @@ public class JsonRepresentation<T> extends OutputRepresentation } else if( object != null ) { - serializer.serialize( OPTIONS_NO_TYPE, object, outputStream ); + // TODO was WITHOUT TYPE INFO + stateSerialization.serialize( new OutputStreamWriter( outputStream ), object ); outputStream.write( '\n' ); } } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/sql-liquibase/build.gradle ---------------------------------------------------------------------- diff --git a/libraries/sql-liquibase/build.gradle b/libraries/sql-liquibase/build.gradle index 319cad1..ef69386 100644 --- a/libraries/sql-liquibase/build.gradle +++ b/libraries/sql-liquibase/build.gradle @@ -33,6 +33,7 @@ dependencies { testCompile polygene.core.testsupport testCompile polygene.library( 'sql-dbcp' ) + testCompile libraries.jooq testRuntime libraries.derby testRuntime libraries.logback http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/sql-liquibase/src/test/java/org/apache/polygene/library/sql/liquibase/LiquibaseServiceTest.java ---------------------------------------------------------------------- diff --git a/libraries/sql-liquibase/src/test/java/org/apache/polygene/library/sql/liquibase/LiquibaseServiceTest.java b/libraries/sql-liquibase/src/test/java/org/apache/polygene/library/sql/liquibase/LiquibaseServiceTest.java index 807990d..108a187 100644 --- a/libraries/sql-liquibase/src/test/java/org/apache/polygene/library/sql/liquibase/LiquibaseServiceTest.java +++ b/libraries/sql-liquibase/src/test/java/org/apache/polygene/library/sql/liquibase/LiquibaseServiceTest.java @@ -20,14 +20,10 @@ package org.apache.polygene.library.sql.liquibase; import java.io.IOException; -import java.sql.ResultSet; import java.sql.SQLException; -import java.util.ArrayList; import java.util.List; import java.util.function.Function; import javax.sql.DataSource; -import org.apache.polygene.api.activation.ActivationEvent; -import org.apache.polygene.api.activation.ActivationEventListener; import org.apache.polygene.api.activation.ActivationException; import org.apache.polygene.api.common.Visibility; import org.apache.polygene.api.property.Property; @@ -39,13 +35,22 @@ import org.apache.polygene.bootstrap.AssemblyException; import org.apache.polygene.bootstrap.ModuleAssembly; import org.apache.polygene.bootstrap.SingletonAssembler; import org.apache.polygene.library.sql.assembly.DataSourceAssembler; -import org.apache.polygene.library.sql.common.Databases; -import org.apache.polygene.library.sql.common.SQLUtil; import org.apache.polygene.library.sql.dbcp.DBCPDataSourceServiceAssembler; import org.apache.polygene.test.EntityTestAssembler; +import org.jooq.DSLContext; +import org.jooq.Field; +import org.jooq.InsertValuesStep2; +import org.jooq.Record; +import org.jooq.SQLDialect; +import org.jooq.Table; +import org.jooq.impl.DSL; import org.junit.Test; +import static java.util.stream.Collectors.toList; import static org.hamcrest.CoreMatchers.equalTo; +import static org.hamcrest.CoreMatchers.is; +import static org.jooq.impl.DSL.field; +import static org.jooq.impl.DSL.table; import static org.junit.Assert.assertThat; import static org.junit.Assert.assertTrue; @@ -68,23 +73,23 @@ public class LiquibaseServiceTest // Create in-memory store for configurations new EntityTestAssembler().assemble( configModule ); - new DBCPDataSourceServiceAssembler(). - identifiedBy( "datasource-service" ). - withConfig( configModule, Visibility.layer ). - assemble( module ); - new DataSourceAssembler(). - withDataSourceServiceIdentity( "datasource-service" ). - identifiedBy( "testds-liquibase" ). - withCircuitBreaker(). - assemble( module ); + new DBCPDataSourceServiceAssembler() + .identifiedBy( "datasource-service" ) + .withConfig( configModule, Visibility.layer ) + .assemble( module ); + new DataSourceAssembler() + .withDataSourceServiceIdentity( "datasource-service" ) + .identifiedBy( "testds-liquibase" ) + .withCircuitBreaker() + .assemble( module ); module.values( SomeValue.class ); // Set up Liquibase service that will create the tables // START SNIPPET: assembly - new LiquibaseAssembler(). - withConfig( configModule, Visibility.layer ). - assemble( module ); + new LiquibaseAssembler() + .withConfig( configModule, Visibility.layer ) + .assemble( module ); // END SNIPPET: assembly module.forMixin( LiquibaseConfiguration.class ).declareDefaults().enabled().set( true ); module.forMixin( LiquibaseConfiguration.class ).declareDefaults().changeLog().set( "changelog.xml" ); @@ -93,78 +98,48 @@ public class LiquibaseServiceTest @Override public void beforeActivation( Application application ) { - application.registerActivationEventListener( new ActivationEventListener() - { - - @Override - public void onEvent( ActivationEvent event ) - { - System.out.println( event ); - } - - } ); + application.registerActivationEventListener( System.out::println ); } - }; Module module = assembler.module(); - // START SNIPPET: io // Look up the DataSource DataSource ds = module.findService( DataSource.class ).get(); - // Instanciate Databases helper - Databases database = new Databases( ds ); + // Prepare jOOQ and the schema model + DSLContext jooq = DSL.using( ds, SQLDialect.DERBY ); + Table<Record> testTable = table( "TEST" ); + Field<String> idColumn = field( "ID", String.class ); + Field<String> fooColumn = field( "FOO", String.class ); // Assert that insertion works - assertTrue( database.update( "insert into test values ('someid', 'bar')" ) == 1 ); - // END SNIPPET: io - - database.query( "select * from test", new Databases.ResultSetVisitor() - { - @Override - public boolean visit( ResultSet visited ) - throws SQLException - { - assertThat( visited.getString( "id" ), equalTo( "someid" ) ); - assertThat( visited.getString( "foo" ), equalTo( "bar" ) ); + InsertValuesStep2 insert = jooq.insertInto( testTable ) + .columns( idColumn, fooColumn ) + .values( "someid", "bar" ); + assertTrue( insert.execute() == 1 ); - return true; - } - } ); + List<Record> records = jooq.selectFrom( testTable ).stream().collect( toList() ); + assertThat( records.size(), is( 1 ) ); + assertThat( records.get( 0 ).get( idColumn ), equalTo( "someid" ) ); + assertThat( records.get( 0 ).get( fooColumn ), equalTo( "bar" ) ); - Function<ResultSet, SomeValue> toValue = new Function<ResultSet, SomeValue>() + Function<Record, SomeValue> toValue = record -> { - @Override - public SomeValue apply( ResultSet resultSet ) - { - ValueBuilder<SomeValue> builder = assembler.module().newValueBuilder( SomeValue.class ); - try - { - builder.prototype().id().set( resultSet.getString( "id" ) ); - builder.prototype().foo().set( resultSet.getString( "foo" ) ); - } - catch( SQLException e ) - { - throw new IllegalArgumentException( "Could not convert to SomeValue", - SQLUtil.withAllSQLExceptions( e ) ); - } - - return builder.newInstance(); - } + ValueBuilder<SomeValue> builder = assembler.module().newValueBuilder( SomeValue.class ); + builder.prototype().id().set( record.get( idColumn ) ); + builder.prototype().foo().set( record.get( fooColumn ) ); + return builder.newInstance(); }; - List<SomeValue> rows = new ArrayList<SomeValue>(); - database.query( "select * from test", new Databases.ResultSetVisitor() { - @Override - public boolean visit( final ResultSet resultSet ) throws SQLException - { - rows.add( toValue.apply( resultSet ) ); - return true; - } - } ); + List<SomeValue> values = jooq.selectFrom( testTable ).stream() + .map( toValue ) + .peek( System.out::println ) + .collect( toList() ); - rows.forEach( System.out::println ); + assertThat( values.size(), is( 1 ) ); + assertThat( values.get( 0 ).id().get(), equalTo( "someid" ) ); + assertThat( values.get( 0 ).foo().get(), equalTo( "bar" ) ); } interface SomeValue @@ -174,5 +149,4 @@ public class LiquibaseServiceTest Property<String> foo(); } - } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/sql/src/main/java/org/apache/polygene/library/sql/common/Databases.java ---------------------------------------------------------------------- diff --git a/libraries/sql/src/main/java/org/apache/polygene/library/sql/common/Databases.java b/libraries/sql/src/main/java/org/apache/polygene/library/sql/common/Databases.java index ebed162..7710444 100644 --- a/libraries/sql/src/main/java/org/apache/polygene/library/sql/common/Databases.java +++ b/libraries/sql/src/main/java/org/apache/polygene/library/sql/common/Databases.java @@ -29,6 +29,7 @@ import org.apache.polygene.api.util.Visitor; /** * Utility methods for performing SQL calls wrapping a given DataSource. */ +// TODO Remove me! public class Databases { DataSource source; http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/libraries/uowfile/src/main/java/org/apache/polygene/library/uowfile/internal/ConcurrentUoWFileModificationException.java ---------------------------------------------------------------------- diff --git a/libraries/uowfile/src/main/java/org/apache/polygene/library/uowfile/internal/ConcurrentUoWFileModificationException.java b/libraries/uowfile/src/main/java/org/apache/polygene/library/uowfile/internal/ConcurrentUoWFileModificationException.java index b604702..b27c067 100644 --- a/libraries/uowfile/src/main/java/org/apache/polygene/library/uowfile/internal/ConcurrentUoWFileModificationException.java +++ b/libraries/uowfile/src/main/java/org/apache/polygene/library/uowfile/internal/ConcurrentUoWFileModificationException.java @@ -32,7 +32,7 @@ public class ConcurrentUoWFileModificationException ConcurrentUoWFileModificationException( Iterable<UoWFile> concurrentlyModifiedFiles, Usecase usecase ) { - super( Collections.<EntityComposite,HasTypes>emptyMap(), usecase ); + super( Collections.emptyMap(), usecase ); this.concurrentlyModifiedFiles = concurrentlyModifiedFiles; } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/manual/src/docs/userguide/extensions.txt ---------------------------------------------------------------------- diff --git a/manual/src/docs/userguide/extensions.txt b/manual/src/docs/userguide/extensions.txt index 524fec2..42f216e 100644 --- a/manual/src/docs/userguide/extensions.txt +++ b/manual/src/docs/userguide/extensions.txt @@ -28,7 +28,7 @@ We try to keep the Polygene⢠Core Runtime as lean as possible, and a lot of th Extension SPI, which defines clear ways to extend the platform. There are currently the following Extensions types, each with possibly more than one implementation; - * Value Serialization + * Serialization * Entity Stores * Index / Query Engines * Entity Caches @@ -45,23 +45,15 @@ for our users. :leveloffset: 2 -include::../../../../extensions/valueserialization-orgjson/src/docs/vs-orgjson.txt[] +include::../../../../extensions/serialization-javaxjson/src/docs/serialization-javaxjson.txt[] :leveloffset: 2 -include::../../../../extensions/valueserialization-jackson/src/docs/vs-jackson.txt[] +include::../../../../extensions/serialization-javaxxml/src/docs/serialization-javaxxml.txt[] :leveloffset: 2 -include::../../../../extensions/valueserialization-stax/src/docs/vs-stax.txt[] - -:leveloffset: 2 - -include::../../../../extensions/cache-ehcache/src/docs/cache-ehcache.txt[] - -:leveloffset: 2 - -include::../../../../extensions/cache-memcache/src/docs/cache-memcache.txt[] +include::../../../../extensions/serialization-msgpack/src/docs/serialization-msgpack.txt[] :leveloffset: 2 @@ -113,6 +105,14 @@ include::../../../../extensions/entitystore-sql/src/docs/es-sql.txt[] :leveloffset: 2 +include::../../../../extensions/cache-ehcache/src/docs/cache-ehcache.txt[] + +:leveloffset: 2 + +include::../../../../extensions/cache-memcache/src/docs/cache-memcache.txt[] + +:leveloffset: 2 + include::../../../../extensions/indexing-elasticsearch/src/docs/index-elasticsearch.txt[] :leveloffset: 2 http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/samples/forum/build.gradle ---------------------------------------------------------------------- diff --git a/samples/forum/build.gradle b/samples/forum/build.gradle index 7986214..52f0378 100644 --- a/samples/forum/build.gradle +++ b/samples/forum/build.gradle @@ -29,7 +29,6 @@ dependencies { compile polygene.core.bootstrap compile polygene.library( 'rest-server' ) compile polygene.library( 'fileconfig' ) - compile polygene.extension( 'valueserialization-orgjson' ) compile polygene.extension( 'entitystore-memory' ) compile polygene.extension( 'entitystore-file' ) compile polygene.extension( 'indexing-rdf' ) http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/samples/forum/src/main/java/org/apache/polygene/sample/forum/assembler/ForumAssembler.java ---------------------------------------------------------------------- diff --git a/samples/forum/src/main/java/org/apache/polygene/sample/forum/assembler/ForumAssembler.java b/samples/forum/src/main/java/org/apache/polygene/sample/forum/assembler/ForumAssembler.java index e3435b1..5f3b0cc 100644 --- a/samples/forum/src/main/java/org/apache/polygene/sample/forum/assembler/ForumAssembler.java +++ b/samples/forum/src/main/java/org/apache/polygene/sample/forum/assembler/ForumAssembler.java @@ -50,7 +50,6 @@ import org.apache.polygene.sample.forum.domainevent.ParameterValue; import org.apache.polygene.sample.forum.rest.ForumRestlet; import org.apache.polygene.sample.forum.rest.resource.RootResource; import org.apache.polygene.sample.forum.service.BootstrapData; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationAssembler; import org.restlet.service.MetadataService; import static java.util.stream.Collectors.toList; @@ -75,18 +74,12 @@ public class ForumAssembler LayerAssembly configuration = assembly.layer( "Configuration" ); { configModule = configuration.module( "Configuration" ); - new OrgJsonValueSerializationAssembler().assemble( configModule ); new MemoryEntityStoreAssembler().assemble( configModule ); new FileConfigurationAssembler().visibleIn( Visibility.application ).assemble( configModule ); } LayerAssembly infrastructure = assembly.layer( "Infrastructure" ).uses( configuration ); { - ModuleAssembly serialization = infrastructure.module( "Serialization" ); - new OrgJsonValueSerializationAssembler(). - visibleIn( Visibility.application ). - assemble( serialization ); - ModuleAssembly entityStore = infrastructure.module( "EntityStore" ); new FileEntityStoreAssembler() .visibleIn( Visibility.application ) @@ -133,8 +126,8 @@ public class ForumAssembler contexts.services( EventsService.class ); context.module( "Domain events" ) - .values( DomainEventValue.class, ParameterValue.class ) - .visibleIn( Visibility.application ); + .values( DomainEventValue.class, ParameterValue.class ) + .visibleIn( Visibility.application ); } LayerAssembly services = assembly.layer( "Service" ).uses( data ); @@ -154,12 +147,12 @@ public class ForumAssembler { new RestServerAssembler().assemble( transformation ); transformation.objects( RequestReaderDelegator.class, ResponseWriterDelegator.class ) - .visibleIn( Visibility.layer ); - new OrgJsonValueSerializationAssembler().assemble( transformation ); + .visibleIn( Visibility.layer ); } ModuleAssembly resources = rest.module( "Resources" ); - List<? extends Class<?>> resourceClasses = ClassScanner.findClasses( RootResource.class ).collect( toList() ); + List<? extends Class<?>> resourceClasses = ClassScanner.findClasses( RootResource.class ) + .collect( toList() ); for( Class<?> resourceClass : resourceClasses ) { resources.objects( resourceClass ).visibleIn( Visibility.layer ); http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/samples/rental/build.gradle ---------------------------------------------------------------------- diff --git a/samples/rental/build.gradle b/samples/rental/build.gradle index fca63d8..7f4cc30 100644 --- a/samples/rental/build.gradle +++ b/samples/rental/build.gradle @@ -33,7 +33,6 @@ jar { manifest { name = "Apache Polygene⢠Sample - Car Rental" } } dependencies { compile polygene.core.bootstrap - compile polygene.extension( 'valueserialization-orgjson' ) providedCompile libraries.servlet_api http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/samples/rental/src/main/java/org/apache/polygene/sample/rental/web/assembly/StorageModule.java ---------------------------------------------------------------------- diff --git a/samples/rental/src/main/java/org/apache/polygene/sample/rental/web/assembly/StorageModule.java b/samples/rental/src/main/java/org/apache/polygene/sample/rental/web/assembly/StorageModule.java index 7fd88ab..a7ca995 100644 --- a/samples/rental/src/main/java/org/apache/polygene/sample/rental/web/assembly/StorageModule.java +++ b/samples/rental/src/main/java/org/apache/polygene/sample/rental/web/assembly/StorageModule.java @@ -24,19 +24,14 @@ import org.apache.polygene.bootstrap.Assembler; import org.apache.polygene.bootstrap.AssemblyException; import org.apache.polygene.bootstrap.ModuleAssembly; import org.apache.polygene.entitystore.memory.MemoryEntityStoreService; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationAssembler; public class StorageModule implements Assembler { - @Override public void assemble( ModuleAssembly module ) throws AssemblyException { module.services( MemoryEntityStoreService.class ).visibleIn( Visibility.application ); - new OrgJsonValueSerializationAssembler(). - visibleIn( Visibility.application ). - assemble( module ); } } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/samples/sql-support/src/main/java/org/apache/polygene/sample/sqlsupport/AppAssembler.java ---------------------------------------------------------------------- diff --git a/samples/sql-support/src/main/java/org/apache/polygene/sample/sqlsupport/AppAssembler.java b/samples/sql-support/src/main/java/org/apache/polygene/sample/sqlsupport/AppAssembler.java index c6c7624..9c9fee6 100644 --- a/samples/sql-support/src/main/java/org/apache/polygene/sample/sqlsupport/AppAssembler.java +++ b/samples/sql-support/src/main/java/org/apache/polygene/sample/sqlsupport/AppAssembler.java @@ -20,7 +20,6 @@ package org.apache.polygene.sample.sqlsupport; import org.apache.polygene.api.common.Visibility; -import org.apache.polygene.api.value.ValueSerialization; import org.apache.polygene.bootstrap.ApplicationAssembler; import org.apache.polygene.bootstrap.ApplicationAssembly; import org.apache.polygene.bootstrap.ApplicationAssemblyFactory; @@ -33,7 +32,6 @@ import org.apache.polygene.index.sql.assembly.PostgreSQLIndexQueryAssembler; import org.apache.polygene.library.sql.assembly.DataSourceAssembler; import org.apache.polygene.library.sql.datasource.DataSources; import org.apache.polygene.library.sql.dbcp.DBCPDataSourceServiceAssembler; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationService; /** * Assemble the Application. @@ -56,8 +54,6 @@ public class AppAssembler LayerAssembly configLayer = appAss.layer( "config" ); ModuleAssembly configModule = configLayer.module( "config" ); { - configModule.services( OrgJsonValueSerializationService.class ). - taggedWith( ValueSerialization.Formats.JSON ); configModule.services( MemoryEntityStoreService.class ). visibleIn( Visibility.module ); // Use a PreferenceEntityStore instead if you want the configuration to be persistent @@ -68,9 +64,6 @@ public class AppAssembler LayerAssembly infraLayer = appAss.layer( "infra" ); ModuleAssembly persistenceModule = infraLayer.module( "persistence" ); { - persistenceModule.services( OrgJsonValueSerializationService.class ). - taggedWith( ValueSerialization.Formats.JSON ); - // SQL DataSource Service String dataSourceServiceIdentity = "postgresql-datasource-service"; new DBCPDataSourceServiceAssembler(). http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/settings.gradle ---------------------------------------------------------------------- diff --git a/settings.gradle b/settings.gradle index 6858c4c..3dbadfb 100644 --- a/settings.gradle +++ b/settings.gradle @@ -76,9 +76,9 @@ include 'core:api', 'extensions:metrics-codahale', 'extensions:migration', 'extensions:reindexer', - 'extensions:valueserialization-orgjson', - 'extensions:valueserialization-jackson', - 'extensions:valueserialization-stax', + 'extensions:serialization-javaxjson', + 'extensions:serialization-javaxxml', + 'extensions:serialization-msgpack', 'tools:model-detail', 'tools:envisage', 'tools:shell', http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tests/performance/build.gradle ---------------------------------------------------------------------- diff --git a/tests/performance/build.gradle b/tests/performance/build.gradle index a8613ad..e81318a 100644 --- a/tests/performance/build.gradle +++ b/tests/performance/build.gradle @@ -32,7 +32,6 @@ dependencies { perfCompile polygene.core.testsupport perfCompile polygene.library( 'sql-dbcp' ) - perfCompile polygene.extension( 'valueserialization-orgjson' ) perfCompile polygene.extension( 'entitystore-memory' ) perfCompile polygene.extension( 'entitystore-jdbm' ) perfCompile polygene.extension( 'entitystore-sql' ) http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/jdbm/JdbmEntityStorePerformanceTest.java ---------------------------------------------------------------------- diff --git a/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/jdbm/JdbmEntityStorePerformanceTest.java b/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/jdbm/JdbmEntityStorePerformanceTest.java index 047ffef..006cf85 100644 --- a/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/jdbm/JdbmEntityStorePerformanceTest.java +++ b/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/jdbm/JdbmEntityStorePerformanceTest.java @@ -29,7 +29,6 @@ import org.apache.polygene.entitystore.jdbm.JdbmConfiguration; import org.apache.polygene.entitystore.jdbm.assembly.JdbmEntityStoreAssembler; import org.apache.polygene.test.EntityTestAssembler; import org.apache.polygene.test.performance.entitystore.AbstractEntityStorePerformanceTest; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationAssembler; /** * Performance test for JdbmEntityStoreComposite @@ -51,7 +50,6 @@ public class JdbmEntityStorePerformanceTest throws AssemblyException { new JdbmEntityStoreAssembler().assemble( module ); - new OrgJsonValueSerializationAssembler().assemble( module ); ModuleAssembly configModule = module.layer().module( "Config" ); configModule.entities( JdbmConfiguration.class ).visibleIn( Visibility.layer ); new EntityTestAssembler().assemble( configModule ); http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/memory/MemoryEntityStorePerformanceTest.java ---------------------------------------------------------------------- diff --git a/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/memory/MemoryEntityStorePerformanceTest.java b/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/memory/MemoryEntityStorePerformanceTest.java index bd664e1..956cc7a 100644 --- a/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/memory/MemoryEntityStorePerformanceTest.java +++ b/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/memory/MemoryEntityStorePerformanceTest.java @@ -21,11 +21,10 @@ import org.apache.polygene.api.mixin.Mixins; import org.apache.polygene.bootstrap.Assembler; import org.apache.polygene.bootstrap.AssemblyException; import org.apache.polygene.bootstrap.ModuleAssembly; -import org.apache.polygene.entitystore.memory.assembly.MemoryEntityStoreAssembler; import org.apache.polygene.entitystore.memory.MemoryEntityStoreService; +import org.apache.polygene.entitystore.memory.assembly.MemoryEntityStoreAssembler; import org.apache.polygene.spi.entitystore.helpers.MapEntityStoreMixin; import org.apache.polygene.test.performance.entitystore.AbstractEntityStorePerformanceTest; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationAssembler; public class MemoryEntityStorePerformanceTest extends AbstractEntityStorePerformanceTest @@ -45,7 +44,6 @@ public class MemoryEntityStorePerformanceTest throws AssemblyException { new MemoryEntityStoreAssembler().assemble( module ); - new OrgJsonValueSerializationAssembler().assemble( module ); } }; } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/sql/DerbySQLEntityStorePerformanceTest.java ---------------------------------------------------------------------- diff --git a/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/sql/DerbySQLEntityStorePerformanceTest.java b/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/sql/DerbySQLEntityStorePerformanceTest.java index d1ea720..5906307 100644 --- a/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/sql/DerbySQLEntityStorePerformanceTest.java +++ b/tests/performance/src/perf/java/org/apache/polygene/test/performance/entitystore/sql/DerbySQLEntityStorePerformanceTest.java @@ -34,7 +34,6 @@ import org.apache.polygene.library.sql.common.SQLUtil; import org.apache.polygene.library.sql.dbcp.DBCPDataSourceServiceAssembler; import org.apache.polygene.test.EntityTestAssembler; import org.apache.polygene.test.performance.entitystore.AbstractEntityStorePerformanceTest; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationAssembler; /** * Performance test for DerbySQLEntityStore. @@ -59,8 +58,6 @@ public class DerbySQLEntityStorePerformanceTest ModuleAssembly config = module.layer().module( "config" ); new EntityTestAssembler().assemble( config ); - new OrgJsonValueSerializationAssembler().assemble( module ); - // DataSourceService new DBCPDataSourceServiceAssembler(). identifiedBy( "derby-datasource-service" ). http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tests/performance/src/perf/java/org/apache/polygene/test/performance/indexing/rdf/QueryPerformanceTest.java ---------------------------------------------------------------------- diff --git a/tests/performance/src/perf/java/org/apache/polygene/test/performance/indexing/rdf/QueryPerformanceTest.java b/tests/performance/src/perf/java/org/apache/polygene/test/performance/indexing/rdf/QueryPerformanceTest.java index a8e54ee..c83356a 100644 --- a/tests/performance/src/perf/java/org/apache/polygene/test/performance/indexing/rdf/QueryPerformanceTest.java +++ b/tests/performance/src/perf/java/org/apache/polygene/test/performance/indexing/rdf/QueryPerformanceTest.java @@ -19,12 +19,6 @@ package org.apache.polygene.test.performance.indexing.rdf; import java.io.File; import org.apache.derby.iapi.services.io.FileUtil; -import org.apache.polygene.api.query.QueryBuilderFactory; -import org.apache.polygene.api.unitofwork.UnitOfWorkFactory; -import org.junit.After; -import org.junit.Assert; -import org.junit.Before; -import org.junit.Test; import org.apache.polygene.api.common.Visibility; import org.apache.polygene.api.entity.EntityBuilder; import org.apache.polygene.api.entity.EntityComposite; @@ -33,12 +27,14 @@ import org.apache.polygene.api.mixin.Mixins; import org.apache.polygene.api.property.Property; import org.apache.polygene.api.query.Query; import org.apache.polygene.api.query.QueryBuilder; +import org.apache.polygene.api.query.QueryBuilderFactory; import org.apache.polygene.api.service.ServiceComposite; import org.apache.polygene.api.service.ServiceReference; import org.apache.polygene.api.structure.Application; import org.apache.polygene.api.structure.Module; import org.apache.polygene.api.unitofwork.UnitOfWork; import org.apache.polygene.api.unitofwork.UnitOfWorkCompletionException; +import org.apache.polygene.api.unitofwork.UnitOfWorkFactory; import org.apache.polygene.bootstrap.ApplicationAssembler; import org.apache.polygene.bootstrap.ApplicationAssembly; import org.apache.polygene.bootstrap.ApplicationAssemblyFactory; @@ -52,7 +48,10 @@ import org.apache.polygene.index.rdf.indexing.RdfIndexingService; import org.apache.polygene.index.rdf.query.SesameExpressions; import org.apache.polygene.library.rdf.repository.NativeConfiguration; import org.apache.polygene.test.EntityTestAssembler; -import org.apache.polygene.valueserialization.orgjson.OrgJsonValueSerializationAssembler; +import org.junit.After; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; import static org.apache.polygene.api.query.QueryExpressions.eq; import static org.apache.polygene.api.query.QueryExpressions.templateFor; @@ -300,7 +299,6 @@ public class QueryPerformanceTest new RdfNativeSesameStoreAssembler().assemble( persistenceModule ); // Entity store - new OrgJsonValueSerializationAssembler().assemble( persistenceModule ); new MemoryEntityStoreAssembler().visibleIn( Visibility.application ).assemble( persistenceModule ); return infrastructureLayer; http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/generator-polygene/app/index.js ---------------------------------------------------------------------- diff --git a/tools/generator-polygene/app/index.js b/tools/generator-polygene/app/index.js index 73f44e6..105dac9 100644 --- a/tools/generator-polygene/app/index.js +++ b/tools/generator-polygene/app/index.js @@ -105,9 +105,8 @@ module.exports = generators.Base.extend( type: 'list', name: 'serialization', choices: [ - 'Jackson', - 'Stax', - 'OrgJson' + 'JavaxJson', + 'JavaxXml' ], message: 'Which indexing system do you want to use?' }, @@ -166,9 +165,8 @@ module.exports = generators.Base.extend( copyPolygeneBootstrap( this, "infrastructure", "MemcacheCachingModule", hasCaching( 'Memcache' ) ); copyPolygeneBootstrap( this, "infrastructure", "EhCacheCachingModule", hasCaching( 'Ehcache' ) ); - copyPolygeneBootstrap( this, "infrastructure", "JacksonSerializationModule", hasSerialization( 'Jackson' ) ); - copyPolygeneBootstrap( this, "infrastructure", "StaxSerializationModule", hasSerialization( 'Stax' ) ); - copyPolygeneBootstrap( this, "infrastructure", "OrgJsonSerializationModule", hasSerialization( 'Orgjson' ) ); + copyPolygeneBootstrap( this, "infrastructure", "JavaxJsonSerializationModule", hasSerialization( 'JavaxJson' ) ); + copyPolygeneBootstrap( this, "infrastructure", "JavaxXmlSerializationModule", hasSerialization( 'JavaxXml' ) ); copyPolygeneBootstrap( this, "connectivity", "RestApiModule", hasFeature( 'rest api' ) ); copyPolygeneBootstrap( this, "infrastructure", "ReindexerModule", hasFeature( 'reindexer' ) ); http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/generator-polygene/app/templates/ConfigModule/bootstrap.tmpl ---------------------------------------------------------------------- diff --git a/tools/generator-polygene/app/templates/ConfigModule/bootstrap.tmpl b/tools/generator-polygene/app/templates/ConfigModule/bootstrap.tmpl index b152d3a..6cd155d 100644 --- a/tools/generator-polygene/app/templates/ConfigModule/bootstrap.tmpl +++ b/tools/generator-polygene/app/templates/ConfigModule/bootstrap.tmpl @@ -25,7 +25,6 @@ import org.apache.polygene.bootstrap.LayerAssembly; import org.apache.polygene.bootstrap.ModuleAssembly; import org.apache.polygene.bootstrap.layered.ModuleAssembler; import org.apache.polygene.entitystore.memory.MemoryEntityStoreService; -import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationAssembler; public class ConfigModule implements ModuleAssembler @@ -35,7 +34,6 @@ public class ConfigModule throws AssemblyException { module.services( MemoryEntityStoreService.class ).visibleIn( Visibility.layer ); - new JacksonValueSerializationAssembler().visibleIn( Visibility.layer ).assemble( module ); return module; } } http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/generator-polygene/app/templates/JacksonSerializationModule/bootstrap.tmpl ---------------------------------------------------------------------- diff --git a/tools/generator-polygene/app/templates/JacksonSerializationModule/bootstrap.tmpl b/tools/generator-polygene/app/templates/JacksonSerializationModule/bootstrap.tmpl deleted file mode 100644 index afc0439..0000000 --- a/tools/generator-polygene/app/templates/JacksonSerializationModule/bootstrap.tmpl +++ /dev/null @@ -1,43 +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 <%= packageName %>.bootstrap.infrastructure; - -import org.apache.polygene.api.common.Visibility; -import org.apache.polygene.bootstrap.AssemblyException; -import org.apache.polygene.bootstrap.LayerAssembly; -import org.apache.polygene.bootstrap.ModuleAssembly; -import org.apache.polygene.bootstrap.layered.ModuleAssembler; -import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationAssembler; - -public class JacksonSerializationModule - implements ModuleAssembler -{ - public static final String NAME = "Jackson Serialization Module"; - - @Override - public ModuleAssembly assemble( LayerAssembly layer, ModuleAssembly module ) - throws AssemblyException - { - new JacksonValueSerializationAssembler() - .visibleIn( Visibility.application ) - .assemble( module ); - return module; - } -} http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/generator-polygene/app/templates/JavaxJsonSerializationModule/bootstrap.tmpl ---------------------------------------------------------------------- diff --git a/tools/generator-polygene/app/templates/JavaxJsonSerializationModule/bootstrap.tmpl b/tools/generator-polygene/app/templates/JavaxJsonSerializationModule/bootstrap.tmpl new file mode 100644 index 0000000..6d4a93c --- /dev/null +++ b/tools/generator-polygene/app/templates/JavaxJsonSerializationModule/bootstrap.tmpl @@ -0,0 +1,39 @@ +<%# + * 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 <%= packageName %>.bootstrap.infrastructure; + +import org.apache.polygene.api.common.Visibility; +import org.apache.polygene.bootstrap.AssemblyException; +import org.apache.polygene.bootstrap.LayerAssembly; +import org.apache.polygene.bootstrap.ModuleAssembly; +import org.apache.polygene.bootstrap.layered.ModuleAssembler; + +public class JavaxJsonSerializationModule + implements ModuleAssembler +{ + public static final String NAME = "javax.json Serialization Module"; + + @Override + public ModuleAssembly assemble( LayerAssembly layer, ModuleAssembly module ) + throws AssemblyException + { + return module; + } +} http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/generator-polygene/app/templates/buildtool/gradle-bootstrap.tmpl ---------------------------------------------------------------------- diff --git a/tools/generator-polygene/app/templates/buildtool/gradle-bootstrap.tmpl b/tools/generator-polygene/app/templates/buildtool/gradle-bootstrap.tmpl index 3261944..4e47d7b 100644 --- a/tools/generator-polygene/app/templates/buildtool/gradle-bootstrap.tmpl +++ b/tools/generator-polygene/app/templates/buildtool/gradle-bootstrap.tmpl @@ -31,6 +31,6 @@ dependencies { <% } %> compile "org.apache.polygene.extension:org.apache.polygene.extension.entitystore-<%= polygene.entitystore.toLowerCase() %>:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.indexing-<%= polygene.indexing.toLowerCase() %>:$polygeneVersion" - compile "org.apache.polygene.extension:org.apache.polygene.extension.valueserialization-<%= polygene.serialization.toLowerCase() %>:$polygeneVersion" + compile "org.apache.polygene.extension:org.apache.polygene.extension.serialization-<%= polygene.serialization.toLowerCase() %>:$polygeneVersion" -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/model-detail/src/test/java/org/apache/polygene/tools/model/VisitableDetailTest.java ---------------------------------------------------------------------- diff --git a/tools/model-detail/src/test/java/org/apache/polygene/tools/model/VisitableDetailTest.java b/tools/model-detail/src/test/java/org/apache/polygene/tools/model/VisitableDetailTest.java index d6af619..d06bc96 100644 --- a/tools/model-detail/src/test/java/org/apache/polygene/tools/model/VisitableDetailTest.java +++ b/tools/model-detail/src/test/java/org/apache/polygene/tools/model/VisitableDetailTest.java @@ -22,6 +22,7 @@ package org.apache.polygene.tools.model; import java.util.ArrayList; import java.util.Arrays; import java.util.List; +import org.apache.polygene.api.service.ServiceActivation; import org.apache.polygene.tools.model.descriptor.ServiceDetailDescriptor; import org.apache.polygene.tools.model.descriptor.TransientDetailDescriptor; import org.junit.Test; @@ -82,6 +83,7 @@ public class VisitableDetailTest // Module "visitEnter( ModuleName )", "visit( " + ModuleActivator.class.getName() + " )", + "visit( " + ServiceActivation.ServiceActivator.class.getName() + " )", // Leaving Structure "visitLeave( ModuleName )", "visitLeave( LayerName )", http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/shell/src/dist/etc/templates/default/files/bootstrap/build.gradle_ ---------------------------------------------------------------------- diff --git a/tools/shell/src/dist/etc/templates/default/files/bootstrap/build.gradle_ b/tools/shell/src/dist/etc/templates/default/files/bootstrap/build.gradle_ index 37ddd9e..cb24601 100644 --- a/tools/shell/src/dist/etc/templates/default/files/bootstrap/build.gradle_ +++ b/tools/shell/src/dist/etc/templates/default/files/bootstrap/build.gradle_ @@ -11,6 +11,5 @@ dependencies { compile "org.apache.polygene.library:org.apache.polygene.library.restlet:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.entitystore-file:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.indexing-rdf:$polygeneVersion" - compile "org.apache.polygene.extension:org.apache.polygene.extension.valueserialization-jackson:$polygeneVersion" -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/shell/src/dist/etc/templates/ng2-heroes/files/bootstrap/build.gradle_ ---------------------------------------------------------------------- diff --git a/tools/shell/src/dist/etc/templates/ng2-heroes/files/bootstrap/build.gradle_ b/tools/shell/src/dist/etc/templates/ng2-heroes/files/bootstrap/build.gradle_ index 37ddd9e..cb24601 100644 --- a/tools/shell/src/dist/etc/templates/ng2-heroes/files/bootstrap/build.gradle_ +++ b/tools/shell/src/dist/etc/templates/ng2-heroes/files/bootstrap/build.gradle_ @@ -11,6 +11,5 @@ dependencies { compile "org.apache.polygene.library:org.apache.polygene.library.restlet:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.entitystore-file:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.indexing-rdf:$polygeneVersion" - compile "org.apache.polygene.extension:org.apache.polygene.extension.valueserialization-jackson:$polygeneVersion" -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/shell/src/dist/etc/templates/restapp/files/bootstrap/build.gradle_ ---------------------------------------------------------------------- diff --git a/tools/shell/src/dist/etc/templates/restapp/files/bootstrap/build.gradle_ b/tools/shell/src/dist/etc/templates/restapp/files/bootstrap/build.gradle_ index 37ddd9e..cb24601 100644 --- a/tools/shell/src/dist/etc/templates/restapp/files/bootstrap/build.gradle_ +++ b/tools/shell/src/dist/etc/templates/restapp/files/bootstrap/build.gradle_ @@ -11,6 +11,5 @@ dependencies { compile "org.apache.polygene.library:org.apache.polygene.library.restlet:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.entitystore-file:$polygeneVersion" compile "org.apache.polygene.extension:org.apache.polygene.extension.indexing-rdf:$polygeneVersion" - compile "org.apache.polygene.extension:org.apache.polygene.extension.valueserialization-jackson:$polygeneVersion" -} \ No newline at end of file +} http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/ConfigModuleWriter.java ---------------------------------------------------------------------- diff --git a/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/ConfigModuleWriter.java b/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/ConfigModuleWriter.java index 69a613a..74c4afc 100644 --- a/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/ConfigModuleWriter.java +++ b/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/ConfigModuleWriter.java @@ -46,7 +46,6 @@ public class ConfigModuleWriter "import org.apache.polygene.bootstrap.ModuleAssembly;\n" + "import org.apache.polygene.bootstrap.layered.ModuleAssembler;\n" + "import org.apache.polygene.entitystore.memory.MemoryEntityStoreService;\n" + - "import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationAssembler;\n" + "\n" + "public class ConfigModule\n" + " implements ModuleAssembler\n" + @@ -56,7 +55,6 @@ public class ConfigModuleWriter " throws AssemblyException\n" + " {\n" + " module.services( MemoryEntityStoreService.class ).visibleIn( Visibility.layer );\n" + - " new JacksonValueSerializationAssembler().visibleIn( Visibility.layer ).assemble( module );\n" + " return module;\n" + " }\n" + "}\n"); http://git-wip-us.apache.org/repos/asf/polygene-java/blob/e4cca11e/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/SerializationModuleWriter.java ---------------------------------------------------------------------- diff --git a/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/SerializationModuleWriter.java b/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/SerializationModuleWriter.java index b604916..9abb1cd 100644 --- a/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/SerializationModuleWriter.java +++ b/tools/shell/src/main/java/org/apache/polygene/tools/shell/create/project/common/SerializationModuleWriter.java @@ -45,7 +45,6 @@ public class SerializationModuleWriter "import org.apache.polygene.bootstrap.LayerAssembly;\n" + "import org.apache.polygene.bootstrap.ModuleAssembly;\n" + "import org.apache.polygene.bootstrap.layered.ModuleAssembler;\n" + - "import org.apache.polygene.valueserialization.jackson.JacksonValueSerializationAssembler;\n" + "\n" + "public class SerializationModule\n" + " implements ModuleAssembler\n" + @@ -56,9 +55,6 @@ public class SerializationModuleWriter " public ModuleAssembly assemble( LayerAssembly layer, ModuleAssembly module )\n" + " throws AssemblyException\n" + " {\n" + - " new JacksonValueSerializationAssembler()\n" + - " .visibleIn( Visibility.application )\n" + - " .assemble( module );\n" + " return module;\n" + " }\n" + "}\n"
