Bug 153908 - Transaction API doesn't scale well for multiple transactions in a parent transaction
Summary: Transaction API doesn't scale well for multiple transactions in a parent tran...
Status: VERIFIED FIXED
Alias: None
Product: EMF Services
Classification: Modeling
Component: Transaction (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P1 major
Target Milestone: ---   Edit
Assignee: Christian Damus CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance
Depends on:
Blocks:
 
Reported: 2006-08-15 10:05 EDT by Maneesh CLA
Modified: 2017-02-24 15:10 EST (History)
0 users

See Also:


Attachments
A complete fix to consider for the next release (67.70 KB, patch)
2006-09-13 11:42 EDT, Christian Damus CLA
ahunter.eclipse: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Maneesh CLA 2006-08-15 10:05:57 EDT
Whenever a child transaction is closed, the parent transaction resumes recording. For that it creates a new ChangeDescription and other overhead associated with ChangeDescriptions.

It is noticed that this causes an additional memory consumption of hundreds of megabytes in a complex scenario while the transaction is in progress.
Comment 1 Christian Damus CLA 2006-09-13 11:42:25 EDT
Created attachment 50052 [details]
A complete fix to consider for the next release

Attached a rather involved change that implements concatenation of ChangeDescriptions, so that when child transactions commit, they append their changes onto the parent's change description, which is then resumed.  This drastically reduces the number of change descriptions for complex transactions (as low as 1 when there are no non-EMF changes to include) and allows a large amount of garbage to be reclaimed on-the-fly.
Comment 2 Christian Damus CLA 2006-09-13 11:47:06 EDT
For this release, a smaller change is committed that ensures that child transactions that are not recorded (OPTION_NO_UNDO/OPTION_UNPROTECTED) do not interrupt the parent's change description and generate no additional overhead in change description storage.

When an unrecorded transaction is started, the change recorder is "paused" but does not complete its change description.  While the unrecorded transaction is in progress, no changes are added to the active description.  Recording is resumed when the transaction completes, after which point the active change description may receive updates.

This, combined with efforts in the client of the Transaction API to reduce the number of nested transactions (that are recorded), should address the scalability issue sufficiently.
Comment 3 Nick Boldt CLA 2008-01-28 16:35:16 EST
Move to verified as per bug 206558.