2015 Dec 10 11:56 AM
Hi Members,
regarding the interface /BOBF/IF_TRA_TRANSACTION_MGR, what is the difference between the methods CLEANUP and ROLLBACK_TO_SYNC_POINT?
Would it be better to use CREATE_SYNC_POINT and ROLLBACK_TO_SYNC_POINT if you want to discard changes you do not want to save during a session?
Or what’s the purpose of creating a sync point?
Kind regards,
Bjoern
Hi Members,
regarding the interface /BOBF/IF_TRA_TRANSACTION_MGR, what is the difference between the methods CLEANUP and ROLLBACK_TO_SYNC_POINT?
Would it be better to use CREATE_SYNC_POINT and ROLLBACK_TO_SYNC_POINT if you want to discard changes you do not want to save during a session?
Or what’s the purpose of creating a sync point?
Kind regards,
Bjoern
2015 Dec 11 4:31 AM
Hi Björn,
in a session multiple BOPF transactions can be sequently processed. They are finished each by a SAVE. If you would like to discard all changes of the current transaction (meaning to rollback to the last saved state), you should use the CLEANUP method.
Only in certain scenarios you have the requirement not to discard all changes of the current transaction but all changes done since a certain event during the current transaction. In that case, you have to create a syncpoint to rollback later on to this kind of "snapshot".
Example: If your UI implementation supports modal popups in the same session than the main window, it is often a requirement to rollback to the state of the current transaction before the popup is opened in case of cancelling the popup. A cleanup would be not suitable as it would also make all changes undone that are done before opening the popup and the last SAVE before.
Best regards
Tilmann
2015 Dec 11 10:59 AM
Now that sounds interesting, almost as if you could implement a generic undo - what a dream of a business transaction
Some more questions around syncpoints:
Thanks for the enlightment!
Cheers,
Oliver
2015 Dec 14 3:32 AM
Hello Oliver,
there can be only one syncpoint during a transaction and you can only rollback to that snapshot. There is no option to compare that snapshot/syncpoint with the transactional image. However I dont expect that the creation usually takes a lot of memory and runtime. From a technical viewpoint, creating a syncpoint means in the worst case doublicating the buffer instances - so in a common scenario (not mass data processing) that shouldn't be a problem.
Best regards
Tilmann
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |