Hello all,

I have a problem deserializing some JSON stuff to my bean. The JSON string
in question looks like this:
"phase": "org.foo.bar.InterfaceName"

When I use an XML representation instead of JSON, deserialization works
without problems.

With JSON I get the following error:
Can not construct instance of java.lang.Class,
problem: org.foo.bar.InterfaceName from [Module
"org.codehaus.jackson.jackson-mapper-asl:main" from local module loader
@7c8af1d3 (roots: jboss-as-7.1.1.Final\modules)]

Caused by: java.lang.ClassNotFoundException: org.foo.bar.InterfaceName from
[Module "org.codehaus.jackson.jackson-mapper-asl:main" from local module
loader @7c8af1d3 (roots: jboss-as-7.1.1.Final\modules)]

The problem seems to be
in org.codehaus.jackson.map.deser.std.ClassDeserializer (line 42)

The corresponding source code is:
try {
    return Class.forName(jp.getText());
} catch (ClassNotFoundException e) {
    throw ctxt.instantiationException(_valueClass, e);
}

When I run this code in my app, there are no problems. I tried bundling a
newer jackson version with my war-file but this does not seem to be picked
up? JBoss always uses the jackson version that is coming with the app
server.

Any help would be appreciated. Thanks in advance.
------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb
_______________________________________________
Resteasy-users mailing list
Resteasy-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/resteasy-users

Reply via email to