Hi have deployed web app on Stratos Live I can run the web app there. But When I go to a particular web page that have dependencies with external libraris(Stanforsparser.jar, PdfBox.jar) it gives me a blank page. I found this error log on the server. I can run this webapp in my local Stratoes Application server without any problem
Server Log
[WSO2 Stratos Application Server] [2012-03-28 23:40:48,627] @karsha.opensource.lk [11051] [WSO2 Stratos Application Server]ERROR {org.apache.catalina.core.ContainerBase.[Tomcat].[defaulthost].[/t/karsha.opensource.lk/webapps/KarshaMarkUp].[jsp]} - Servlet.service() for servlet jsp threw exception {org.apache.catalina.core.ContainerBase.[Tomcat].[defaulthost].[/t/karsha.opensource.lk/webapps/KarshaMarkUp].[jsp]
What would causing this error?
I'm getting this error on webpage now when running my web app on StratoesLive App server, but I'm not getting this error on the local App server. A bug? Although I have debugged on my local machine I can't find the error.
code- http://paste.org/47396
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
java.lang.NullPointerException
controler.ControlerServelet.pdfDocToSentence(ControlerServelet.java:755) // I have mentioned thses two lines
controler.ControlerServelet.doPost(ControlerServelet.java:585) // in
javax.servlet.http.HttpServlet.service(HttpServlet.java:641)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
sun.reflect.GeneratedMethodAccessor1724.invoke(Unknown Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:597)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:273)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:270)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:305)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.14 logs.
This is because Stratos security manager dosen't allow writing temporary files. Mentioned external libraries writes temp files when they executing. Forcing to use memory buffers instead of temp files solves the error.