• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Application terminates when a session times out
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Application terminates when a session times out


  • Subject: Re: Application terminates when a session times out
  • From: Seejo Pylappan <email@hidden>
  • Date: Thu, 13 Feb 2003 11:37:24 -0500

Check the code segment in : Session.isAnIAEmployee. That seems to be where the problem is comming from. where are you getting the IA_User from? Are you fetching it in a session and then setting it as a universal user? in other words what is happening is the EOEditingContext in which the IA_User is fetched has been finalized when your session times out (check finalize code?) and then when you reenter, you are messaging to the IA_User whose editingContext is no longer around and is causing the crash.


On Thursday, February 13, 2003, at 11:14 AM, meena wrote:

Hello all,

I have moved my WebObjects 4.5 application to WebObjects 5.1.4 on Mac OS X 10.2.3. I have successfully compiled the application and even could execute the application with no problems. But, there is a problem when my session times out. I have set a time out in my session for 12minutes. Also, I have found that once a session is timed out, the application gets terminated at the next request by either other sessions or when I try to establish a new session. Do I need to explicitily do some settings ? I don't remember doing one such when I used WebObjects 4.5. I feel that when one session times out, it times out the rest of the sessions or and somehow fails when there is a new request to the application.

In my Session.java, I have the following

    public Session ()  {
        super();
        this.setTimeOut(12*60); // Shut down if idle for 12minutes.
    }

I have the following piece of code is present in my Application.java

/* The following method is invoked when the application receives a request from a session that has timed out. */
public WOResponse handleSessionRestorationErrorInContext(WOContext aContext) {
WOComponent nextPage;
nextPage = this.pageWithName("Main", aContext);
return nextPage.generateResponse();
}


When the session times out, and I click on a link on the page which was linked to timed out session, I expect the system to display the Home page ("Main"), rather the application is terminated. I get the following error. This application is really working very well with WebObjects 4.5 (both development and deployment environment), but currently this problem occurs with WebObjects 5.1.4. Development environment. I never thought that such a serious problem would arise when I move to a higher version. I really appreciate any suggestions/help in this matter.

Meena.
****************************************
[2003-02-13 15:45:17 CET] <WorkerThread10> <WOApplication 'LAWeb'>: Exception occurred while handling request:
com.webobjects.foundation.NSForwardException [java.lang.IllegalStateException] null
[2003-02-13 15:45:17 CET] <WorkerThread10> com.webobjects.foundation.NSForwardException for java.lang.IllegalStateException: attempt to send message to object of class class IA_User after its EOEditingContext was finalized
at com.webobjects.eocontrol.EOEditingContext$_EOInvalidationFaultHandler.c ompleteInitializationOfObject(EOEditingContext.java:165)
at com.webobjects.eocontrol.EOCustomObject.willRead(EOCustomObject.java:83 2)
at com.webobjects.eocontrol._EOMutableKnownKeyDictionary$Initializer$_Gene ricRecordBinding.valueInObject(_EOMutableKnownKeyDictionary.java:492)
at com.webobjects.eocontrol.EOCustomObject.storedValueForKey(EOCustomObjec t.java:1174)
at IA_User.user_Id(IA_User.java:136)
at Session.isAnIAEmployee(Session.java:134)
at Main.<init>(Main.java:66)
at java.lang.reflect.Constructor.newInstance(Native Method)
at com.webobjects.foundation._NSUtilities.instantiateObject(_NSUtilities.j ava:526)
at com.webobjects.appserver._private.WOComponentDefinition._componentInsta nceInContext(WOComponentDefinition.java:470)
at com.webobjects.appserver._private.WOComponentDefinition.componentInstan ceInContext(WOComponentDefinition.java:576)
at com.webobjects.appserver.WOApplication.pageWithName(WOApplication.java: 1738)
at Application.handleSessionRestorationErrorInContext(Application.java:187 )
at com.webobjects.appserver._private.WOComponentRequestHandler._dispatchWi thPreparedApplication(WOComponentRequestHandler.java:308)
at com.webobjects.appserver._private.WOComponentRequestHandler._handleRequ est(WOComponentRequestHandler.java:346)
at com.webobjects.appserver._private.WOComponentRequestHandler.handleReque st(WOComponentRequestHandler.java:414)
at com.webobjects.appserver.WOApplication.dispatchRequest(WOApplication.ja va:1133)
at com.webobjects.appserver._private.WOWorkerThread.runOnce(WOWorkerThread .java:158)
at com.webobjects.appserver._private.WOWorkerThread.run(WOWorkerThread.jav a:231)
at java.lang.Thread.run(Thread.java:491)
[2003-02-13 15:45:17 CET] <WorkerThread10> <WOWorkerThread id=10 socket=Socket[addr=iamac49.epfl.ch/ 128.178.5.78,port=49538,localport=51746]> Exception occurred while responding to client: java.lang.NullPointerException
[2003-02-13 15:45:17 CET] <WorkerThread10> java.lang.NullPointerException
at Application.handleException(Application.java:167)
at com.webobjects.appserver._private.WOComponentRequestHandler._handleRequ est(WOComponentRequestHandler.java:366)
at com.webobjects.appserver._private.WOComponentRequestHandler.handleReque st(WOComponentRequestHandler.java:414)
at com.webobjects.appserver.WOApplication.dispatchRequest(WOApplication.ja va:1133)
at com.webobjects.appserver._private.WOWorkerThread.runOnce(WOWorkerThread .java:158)
at com.webobjects.appserver._private.WOWorkerThread.run(WOWorkerThread.jav a:231)
at java.lang.Thread.run(Thread.java:491)


****************************************
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Application terminates when a session times out
      • From: meena <email@hidden>
    • Re: Application terminates when a session times out
      • From: Art Isbell <email@hidden>
References: 
 >Application terminates when a session times out (From: meena <email@hidden>)

  • Prev by Date: Application terminates when a session times out
  • Next by Date: Re: Can you compare webobjects to other similar tools.
  • Previous by thread: Application terminates when a session times out
  • Next by thread: Re: Application terminates when a session times out
  • Index(es):
    • Date
    • Thread