0

I am working with a server extentsion for Neo4j. I got a problem with mapping POJOs to and from JSON, and found the solution in this thread: A message body writer for Java class not found The problem is that I do not have a web.xml in my project. I tried to add one, but it did not work.

Is it possible to add web.xml to a server extension plugin?

Thanks!

Community
  • 1
  • 1
David Berg
  • 1,958
  • 1
  • 21
  • 37
  • You don't need a web.xml perhaps this helps http://stackoverflow.com/questions/30929203/consuming-json-in-neo4j-server-extension – Michael Hunger Jul 01 '15 at 22:40
  • I looked at that example and can not see why my code does not work. I have almost the exact same setup. I do not get what "org.civinomics.graphapi.CivGraph" is in the pom. Also I use neo4j 2.2.0 and not 2.2.2 as he does. – David Berg Jul 02 '15 at 07:03
  • Both are unrelated, I think you need the jersey-jackson-json message converter lib that was mentioned. – Michael Hunger Jul 03 '15 at 06:42
  • I got it working. I was not aware of how to provide dependencies to Neo4J. When I added the jersey-json jar to system->lib folder it worked. I did only add it to my pom earlier. – David Berg Jul 03 '15 at 11:48
  • 1
    Add it to the plugins folder together with your extension jar – Michael Hunger Jul 04 '15 at 10:36

0 Answers0