Peter Ansell
unread,Aug 10, 2014, 11:52:26 PM8/10/14Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to sta...@clarkparsia.com
Hi,
I am running into the following issue due to a hardcoded link to an old version (~16 months ago) of the JSON-LD-Java library that I attempted to remove just by eliminating the jar file, to replace it with a current version.
java.lang.NoClassDefFoundError: de/dfki/km/json/jsonld/impl/SesameJSONLDWriterFactory
at com.complexible.stardog.Stardog.init(Stardog.java:136)
at com.complexible.stardog.Stardog.<clinit>(Stardog.java:64)
....
Caused by: java.lang.ClassNotFoundException: de.dfki.km.json.jsonld.impl.SesameJSONLDWriterFactory
at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 27 more
Not sure if you are aware but that version of the library is not likely to generate valid JSON-LD-1.0 documents, as the specification was heavily updated since we moved to using the com.github.jsonldjava namespace on its way to becoming a W3C recommendation.
The distributed jar file for jsonld-java-sesame has the META-INF/services/org.openrdf.rio.RDFWriterFactory file and it seems to point to the right class so not sure why it was necessary to hardcode the link in the first place as everything should just work using java.util.ServiceLoader as for the other Rio parsers/writers.
Cheers,
Peter