Page Flow Application Blocks/Work Flow and orphan rows.

Topics: Web Client Software Factory, User Forum
Jul 23, 2007 at 5:41 AM

I’m having issues with orphan rows being created when using page flow application block(WCSF) and work flow are working together.

Basically, whenever a user has an unexpected error within a web page that is using page flow and work flow the data row within the ‘instancestate’ table is removed via the correlation key held in the web browser, this is the correct thing to do.
However, the dependant ‘pageflowinstance’(created by page flow block) table does not have related rows removed which creates orphan rows as the ‘InstanceState’ and ‘pageflowinstance’ tables have a one too many relationship (InstanceState.uidInstanceID = pageflow_instance.InstanceID).

This is causing a problem as the correlation key is not removed from the users web browser, stopping the user from using the web site as Page flow instance hasn’t been removed and correlation key still exist that doesn’t point to any work flow instance.
The page flow is using work flow to manage the site navigation, which means the user is stuck in one web location unless they clean cookies.

Possible solution:
I’m looking for a way to have the pageflow_instance table cleaned the same way the instance row is automatically removed within work flow when an exception occurs.

Should the SQL script used by Page Flow Block be extended to add a function that also deletes ‘pageflow_instance ‘ whenever a row is removed from ‘instanceState’.

Temp solution:
I’ve got a task that removes orphan rows running every few hours, but this means the users can’t access the site immediately.
I might be missing something, but it seems that the page flow should be extended to add data logic that force the one too many relationship between the two tables that hold work flow and page flow together.
• Maybe there is an existing stored procedure that I can add the logic to remove the child rows.

Help much appreciated