Skip to content

Commit

Permalink
prepared and no_join diagrams
Browse files Browse the repository at this point in the history
  • Loading branch information
ar committed Oct 20, 2014
1 parent 83b5cc0 commit cb918d7
Show file tree
Hide file tree
Showing 6 changed files with 1,437 additions and 43 deletions.
16 changes: 15 additions & 1 deletion doc/src/asciidoc/ch09/assembly_line.asc
Original file line number Diff line number Diff line change
Expand Up @@ -117,5 +117,19 @@ Here is the sample log:
commit: org.jpos.transaction.Debug
----------

image:images/tm.png[width="100%",alt="TransactionManager"]
In a blue sky scenario like the previous one, the TM calls all participant's
`prepare` method, which return PREPARED, and then the `commit` method on
those that have joined the transaction (by not returning the `NO_JOIN`
modifier).

Here is a diagram for a situation where all participants return just `PREPARED`
(meaning they DO want to join the transaction, so commit gets called).

image:images/tm_prepared.png[width="75%",alt="PREPARED"]

When a participant adds the `NO_JOIN` modifier (by returning
`PREPARE | NO_JOIN`), then the TM skips calling that participant's
`commit` method as shown in the following diagram.

image:images/tm_no_join.png[width="75%",alt="PREPARED | NO_JOIN"]

Binary file removed doc/src/asciidoc/images/tm.png
Binary file not shown.
Loading

0 comments on commit cb918d7

Please sign in to comment.