beehive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daryl Olander (JIRA)" <...@beehive.apache.org>
Subject [jira] Resolved: (BEEHIVE-1028) Controls in pageflows do not appear to be receiving lifecycle events in the proper order
Date Tue, 24 Jan 2006 20:47:10 GMT
     [ http://issues.apache.org/jira/browse/BEEHIVE-1028?page=all ]
     
Daryl Olander resolved BEEHIVE-1028:
------------------------------------

    Resolution: Fixed

I reworked how the ControlContainerContext inside of the page flow runtime works to fix a
number of problems that could have caused problems.  The following is a brief description
of this fix.

There are now two sets of ControlContainerContext  (CCC) objects.  For page flows and faces
backing files, the CCC is scoped into the lifetime of the page flow.  For all shared flows
(and global app) there is a single CCC.  

In order to handle the property beginContext/endContext, we now do the beginContext/endContext
in the three single threaded execution sections where page flow code runs.  These are the
around onCreate, beforeAction/Action/afterAction, and then JSP rendering.  In each of these
sections will will run beginContext and endContext.  In addition, there is a single lock object
that is obtained to gain access to the shared flow CCC. 

The result is that we now provide single threaded access to a shared flow (assuming that there
is a control in some shared flow).  In addition, we will serialize execution of thread within
the session.  We also run the proper resource event lifecycle on the controls.



> Controls in pageflows do not appear to be receiving lifecycle events in the proper order
> ----------------------------------------------------------------------------------------
>
>          Key: BEEHIVE-1028
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-1028
>      Project: Beehive
>         Type: Bug
>   Components: NetUI
>     Versions: 1.0.1, V1
>     Reporter: Chad Schoettger
>     Assignee: Chad Schoettger
>      Fix For: 1.0.1
>  Attachments: beehive1028.zip, jira1028Simplified.zip
>
> So I have a small webapp which basically consists of a pageflow and a jdbc control. 
The single jsp in the web app invokes an action in the page flow as:
>  	 	<tr><td><img src="doRenderChart.do?versionName=9.2Beta&projectName=Workshop&componentName=W-IDE&JFWidth=500&JFHeight=300"
border="0"/></td></tr>
> It does this 10 or 11 times to build a table which contains images generated by the action
using the jdbc control to retrieve data from a database.  Typically (although not always)
at least one of the images will not be generated due to an SQL Error throw by the jdbc control.
 The error is that the SQLConnection has been closed.
> Here is a portion of the tomcat log, I've added some debugging statements in the ControlContainerContext
class to help me see what was going on, the doRenderChart() is the page flow action being
called by the jsp.  It appears the control's begin and end events are not fired in the right
order, causing (in some instances) the control to be unititialzed before a call has been completed.
> log4j:WARN Please initialize the log4j system properly.
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=null
> BEGIN_CONTEXT: THREAD ID = 35
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-IDE
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Docs
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-IDECore
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-External
> BEGIN_CONTEXT: THREAD ID = 35
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Project
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Javelin
> BEGIN_CONTEXT: THREAD ID = 35
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-RuntimeControls
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-RuntimeNetUI
> BEGIN_CONTEXT: THREAD ID = 35
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Upgrade
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 33
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=null
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 33
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Docs
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-IDE
> BEGIN_CONTEXT: THREAD ID = 33
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 33
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-External
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 33
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-IDECore
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Project
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 33
> calling version=9.2Beta project=Workshop component=W-Javelin
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-RuntimeControls
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 33
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-RuntimeNetUI
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Upgrade
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> END_CONTEXT: THREAD ID = 33
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> Listening for transport dt_shmem at address: jdbconn
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=null
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Docs
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-External
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-IDE
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> BEGIN_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-IDECore
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> **** Enter: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 34
> calling version=9.2Beta project=Workshop component=W-Project
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Javelin
> BEGIN_CONTEXT: THREAD ID = 35
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-RuntimeControls
> BEGIN_CONTEXT: THREAD ID = 34
> **** Leave: doRenderChart() ****
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-RuntimeNetUI
> BEGIN_CONTEXT: THREAD ID = 35
> **** Leave: doRenderChart() ****
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 35
> BEGIN_CONTEXT: THREAD ID = 35
> **** Enter: doRenderChart() ****
> calling version=9.2Beta project=Workshop component=W-Upgrade
> **** Leave: doRenderChart() ****
> BEGIN_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 35
> END_CONTEXT: THREAD ID = 34
> END_CONTEXT: THREAD ID = 34

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message