polygene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nic...@apache.org
Subject zest-java git commit: ZEST-118; Missed a getName() call in Serialization.
Date Thu, 27 Aug 2015 10:34:01 GMT
Repository: zest-java
Updated Branches:
  refs/heads/develop 360c40e39 -> 77bedb5e0


ZEST-118; Missed a getName() call in Serialization.


Project: http://git-wip-us.apache.org/repos/asf/zest-java/repo
Commit: http://git-wip-us.apache.org/repos/asf/zest-java/commit/77bedb5e
Tree: http://git-wip-us.apache.org/repos/asf/zest-java/tree/77bedb5e
Diff: http://git-wip-us.apache.org/repos/asf/zest-java/diff/77bedb5e

Branch: refs/heads/develop
Commit: 77bedb5e047ca861072fe66db9bdb624576d8990
Parents: 360c40e
Author: Niclas Hedhman <niclas@hedhman.org>
Authored: Thu Aug 27 18:33:42 2015 +0800
Committer: Niclas Hedhman <niclas@hedhman.org>
Committed: Thu Aug 27 18:33:42 2015 +0800

----------------------------------------------------------------------
 .../java/org/apache/zest/runtime/service/ImportedServiceModel.java | 2 +-
 .../java/org/apache/zest/spi/value/ValueSerializerAdapter.java     | 2 +-
 .../org/apache/zest/test/value/AbstractJsonDateFormatTest.java     | 1 +
 3 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zest-java/blob/77bedb5e/core/runtime/src/main/java/org/apache/zest/runtime/service/ImportedServiceModel.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/zest/runtime/service/ImportedServiceModel.java
b/core/runtime/src/main/java/org/apache/zest/runtime/service/ImportedServiceModel.java
index da2d28c..648f5ba 100644
--- a/core/runtime/src/main/java/org/apache/zest/runtime/service/ImportedServiceModel.java
+++ b/core/runtime/src/main/java/org/apache/zest/runtime/service/ImportedServiceModel.java
@@ -145,9 +145,9 @@ public final class ImportedServiceModel
     @SuppressWarnings( { "raw", "unchecked" } )
     public <T> ImportedServiceInstance<T> importInstance( Module module )
     {
-        ServiceImporter importer = module.newObject( serviceImporter );
         try
         {
+            ServiceImporter importer = module.newObject( serviceImporter );
             T instance = (T) importer.importService( this );
             return new ImportedServiceInstance<>( instance, importer );
         }

http://git-wip-us.apache.org/repos/asf/zest-java/blob/77bedb5e/core/spi/src/main/java/org/apache/zest/spi/value/ValueSerializerAdapter.java
----------------------------------------------------------------------
diff --git a/core/spi/src/main/java/org/apache/zest/spi/value/ValueSerializerAdapter.java
b/core/spi/src/main/java/org/apache/zest/spi/value/ValueSerializerAdapter.java
index 632602c..5f5314f 100644
--- a/core/spi/src/main/java/org/apache/zest/spi/value/ValueSerializerAdapter.java
+++ b/core/spi/src/main/java/org/apache/zest/spi/value/ValueSerializerAdapter.java
@@ -340,7 +340,7 @@ public abstract class ValueSerializerAdapter<OutputType>
         {
             onFieldStart( output, "_type" );
             onValueStart( output );
-            onValue( output, descriptor.valueType().types().findFirst().orElse( null ));
+            onValue( output, descriptor.valueType().types().findFirst().get().getName());
             onValueEnd( output );
             onFieldEnd( output );
         }

http://git-wip-us.apache.org/repos/asf/zest-java/blob/77bedb5e/core/testsupport/src/main/java/org/apache/zest/test/value/AbstractJsonDateFormatTest.java
----------------------------------------------------------------------
diff --git a/core/testsupport/src/main/java/org/apache/zest/test/value/AbstractJsonDateFormatTest.java
b/core/testsupport/src/main/java/org/apache/zest/test/value/AbstractJsonDateFormatTest.java
index cfeea10..9a65bd3 100644
--- a/core/testsupport/src/main/java/org/apache/zest/test/value/AbstractJsonDateFormatTest.java
+++ b/core/testsupport/src/main/java/org/apache/zest/test/value/AbstractJsonDateFormatTest.java
@@ -54,6 +54,7 @@ public class AbstractJsonDateFormatTest
     {
         module.injectTo( this );
     }
+
     @Service
     protected ValueDeserializer valueDeserializer;
 


Mime
View raw message