This is a pretty simple request, but I just didn\'t find a way to do it.
I\'m basically trying to set up a role in JAXB which says that whenever an null field is enc
In MOXy u can specify how the jsonProvider must do its job for JAXB.
So when doing JAX-RS, add following code in your class derived from Application
I used this code on Tomcat 7 with good results. (eclipselink 2.4.1)
@ApplicationPath("/rest")
public class RestApplication extends Application
{
...
public Set< Object> getSingletons()
{
HashSet
On Glassfish 3.1.2 and WAS 8.5 however, newMoxyJsonProvider() is not needed, but then the JAXB provider gets configured by the server. In the case of Glassfish, which comes with MOXy, i witnessed same problems with null values. Did not check yet, but guess the answer is in configuring JAXB at application server level if possible at all.