I have a servlet that returns a JSON string. For some reason it works
fine when I dispatch to a JSP, but sometimes fails when I write
directly to the response.

this works:

          req.setAttribute("json", json.toJSONString());
          req.getRequestDispatcher("json.jsp").forward(req, resp);

this (sometimes) doesn't work:

          json.writeJSONString(resp.getWriter());

Unfortunately the error is sporadic and I'm not reproducing right now,
but it was an "Illegal argument" exception in NucleusJDOHelper.

The request is reading and writing to persistence. I'm calling
PersistenceManager.close() immediately after this.

Any ideas? I can provide more details if necessary.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to