Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

JSP NullPointerException in the next morning

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am using JRun the problem is when i access a particular JSP page in the next morning i am getting NullPointerException if i put the code again or restart the JRun then it works well, again in the next morning when i access the page i am getting NullPointerException what would be the prob.
Thanks in Advance.
------------------
Valan
 
Ranch Hand
Posts: 254
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is the database going down for backups every night. If yes, you need to set up a job to restart the jrun after the database comes back up. I had the same problem too.
Beksy
 
Thomas Samimuthu
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Besky,
Thanks, that is a good thought , no we are not doing any backup right now, other pages which access the databse are working fine
but one thing i over-ride the session creation in that jsp page
i set session=false in the "page" attribute and i create
the session object by myself like
HttpSession session = request.getSession(true)
is that any problem with session object???
or is there any objects created in the jspinit() method get carbage collected after some times???

------------------
Valan
 
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi thomas,
u should not set session=false in ur jsp page.doing this means that no further sessions will be created, even if u try to .try removing that statement from ur jsp page and try again.i think it will work.
Subbu
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You don't say exactly where the NullPointerException is coming from, I should think that would be the first thing to investigate. You should be dumping a StackTrace for that exception - either have an errorPage designated for your JSP or try-catch blocks for the code.
Bill

------------------
author of:
 
Thomas Samimuthu
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi This the stack dump i am getting:
null
java.lang.NullPointerException
at jrun__calendar2ejspd._jspService(jrun__calendar2ejspd.java:447)
at allaire.jrun.jsp.HttpJSPServlet.service(HttpJSPServlet.java:40)
at allaire.jrun.servlet.JRunServletPool.service(JRunServletPool.java:92)
at allaire.jrun.servlet.JRunSE.service(JRunSE.java:1013)
at allaire.jrun.servlet.JRunSE.runServlet(JRunSE.java:925)
at allaire.jrun.servlet.JRunNamedDispatcher.forward(JRunNamedDispatcher.java:34)
at allaire.jrun.jsp.JSPServlet.service(JSPServlet.java:175)
at allaire.jrun.servlet.JRunSE.service(JRunSE.java:1013)
at allaire.jrun.servlet.JRunSE.runServlet(JRunSE.java:925)
at allaire.jrun.servlet.JRunRequestDispatcher.forward(JRunRequestDispatcher.java:88)
at allaire.jrun.servlet.JRunSE.service(JRunSE.java:1131)
at allaire.jrun.servlet.JvmContext.dispatch(JvmContext.java:330)
at allaire.jrun.jrpp.ProxyEndpoint.run(ProxyEndpoint.java:382)
at allaire.jrun.ThreadPool.run(ThreadPool.java:272)
at allaire.jrun.WorkerThread.run(WorkerThread.java:75)

-Thanks
 
To do a great right, do a little wrong - shakepeare. twisted little ad:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic