You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+23-33
Original file line number
Diff line number
Diff line change
@@ -19,13 +19,13 @@
19
19
This is the material accompanying the presentation of webinar part II - Transaction Management with Fuse ESB, Camel and Persistent EIPs.
20
20
It covers the different demo made during the talk and is organized like that :
21
21
22
-
aggregator = Camel route project to persist aggregate in H2 DB using JDBCAggregateRepository
23
-
idempotent = Camel route using JPAIdempotentRepository to persist messages already processed
24
-
dao = DAO layer to persist Incident record in H2 DB using OpenJPA
25
-
dao-jta = Idem but configured to use JTA
26
-
features = features to be deployed on Fuse ESB
27
-
route-one-tx-manager = Camel routes using one Global Tx Manager (Aries Tx Manager on Fuse ESB)
28
-
route-two-tx-manager = Camel routes using tewo separate Tx Managers (JMS and JDBC)
22
+
-aggregator = Camel route project to persist aggregate in H2 DB using JDBCAggregateRepository
23
+
-idempotent = Camel route using JPAIdempotentRepository to persist messages already processed
24
+
-dao = DAO layer to persist Incident record in H2 DB using OpenJPA
25
+
-dao-jta = Idem but configured to use JTA
26
+
-features = features to be deployed on Fuse ESB
27
+
-route-one-tx-manager = Camel routes using one Global Tx Manager (Aries Tx Manager on Fuse ESB)
28
+
-route-two-tx-manager = Camel routes using tewo separate Tx Managers (JMS and JDBC)
29
29
30
30
# H2 DATABASE
31
31
@@ -54,10 +54,14 @@ route-two-tx-manager = Camel routes using tewo separate Tx Managers (JMS and JDB
54
54
Check that the records are well created using the command : SELECT * FROM REPORT.T_INCIDENT;
55
55
56
56
57
-
# FUSE ESB INSTALLATION
57
+
# FUSE ESB INSTALLATION AND CONFIGURATION
58
58
59
-
1. Download and install the Fuse ESB server : http://repo.fusesource.com/nexus/content/repositories/releases/org/apache/servicemix/apache-servicemix/4.4.1-fuse-01-06/
60
-
2. Start Fuse ESB server /bin/karaf.sh
59
+
1. Download and install the Fuse ESB : http://www.fusesource.com/downloads
60
+
2. Add the following credentials to the `$FUSE_ESB_HOME>etc/users.properties` file:
61
+
62
+
admin=admin,admin
63
+
64
+
3. Start Fuse ESB server ./bin/karaf
61
65
62
66
63
67
# Camel Route with 2 Tx Managers
@@ -68,46 +72,32 @@ To install and test, perform the following steps:
68
72
69
73
1. cd camel-persistence-part2/
70
74
2. Run: mvn clean install
71
-
72
-
3. ServiceMix offers a simple JNDI implementation for OSGi, but for this example we are interested in leveraging the more sophisticated Aries JNDI
73
-
lookup handler. Thus, we need to remove the ServiceMix Naming bundle as it will conflict with the Aries JNDI implementation. Run the following command:
74
-
75
-
list | grep -i naming | grep -i servicemix
76
-
77
-
Make note of the bundle id (the number inside the leftmost square brackets).
78
-
79
-
Run the following command:
80
-
81
-
uninstall <bundle-id>
82
-
83
-
Restart Karaf (use Ctrl-D to stop it).
84
-
85
-
4. Install the relevant bundles by executing the following command in the FUSE ESB console:
75
+
3. Install the relevant bundles by executing the following command in the FUSE ESB console:
6. Start H2 console and connect to the DB using the following parameters
88
+
5. Start H2 console and connect to the DB using the following parameters
99
89
Driver class = org.h2.Driver
100
90
JDBC URL : jdbc:h2:tcp://localhost/~/reportdb
101
91
User name : sa
102
92
Password :
103
93
104
94
Run the following SQL sentence to ensure that the REPORT.T_INCIDENT is empty: SELECT * FROM REPORT.T_INCIDENT;
105
95
106
-
7. Launch JConsole (inside $JAVA_HOME/bin) and connect to the local process named "org.apache.karaf.main.Main". Switch to the MBeans tab at the top.
107
-
On the left pane, expand the org.apache.activemq domain, then navigate to: default > Queue. You will see the incident and rollback queues.
96
+
6. Launch JConsole (inside $JAVA_HOME/bin) and connect to the local process named "org.apache.karaf.main.Main". Switch to the MBeans tab at the top.
97
+
On the left pane, expand the org.apache.activemq domain, then navigate to: fusemq > Queue. You will see the incident and rollback queues.
108
98
The registerCall queue will appear when it is first used. For these queues, you will be interested in tracking the EnqueueCount attribute.
109
99
110
-
8. Copy the following files and notice the effect in the registerCall queue and the REPORT.T_INCIDENT table:
100
+
7. Copy the following files and notice the effect in the registerCall queue and the REPORT.T_INCIDENT table:
111
101
112
102
- camel-persistence-part2/data/csv-one-record-allok.txt to $SERVICEMIX_HOME/datainsert --> record written in table, new message on registerCall queue
113
103
- camel-persistence-part2/data/csv-one-record-failjms-dbok.txt to $SERVICEMIX_HOME/datainsert --> record written in table, NO new message on registerCall queue
@@ -156,9 +146,9 @@ To install and test, assuming that you have previously run the "Camel Route with
156
146
SELECT * FROM CAMEL_MESSAGEPROCESSED
157
147
5. Copy the following file
158
148
cp cp ../data/csv-one-record.txt datainsert/
159
-
6. The exchange is not filters out and camel logs that
149
+
6. The exchange is not filtered out and camel logs that
160
150
%%% File receive -> csv-one-record.txt
161
-
7.Shutdown the camel route and restart
151
+
7.Shutdown the camel route and restart
162
152
Verify after copying the file that the camel route will not display the following message
163
153
%%% File receive -> csv-one-record.txt
164
154
@@ -170,7 +160,7 @@ To install and test, assuming that you have previously run the "Camel Route with
0 commit comments