jclouds-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Abiquo Jenkins <notificati...@github.com>
Subject Re: [jclouds-labs-openstack] Adds missing constructor properties (#124)
Date Tue, 05 Aug 2014 21:45:04 GMT
> @@ -33,6 +35,7 @@
>     protected final String start;
>     protected final String end;
>  
> +   @ConstructorProperties({"start", "end"})

Previous investigations of how Gson works (in another PR) showed that, as Zack points, if
the annotation is not present, the default Gson impl will be used to build the deserialized
object. If there is no default constructor and the fields are final, an impl that uses sun.misc.Unsafe
will be used to set the values directly in memory. We should avoid falling back to it, as
that might not be available in all JVM implementations.

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs-openstack/pull/124/files#r15844109
Mime
View raw message