background image

Repackaging the SynchConsumer Example

<< Editing and Running the Programs | Deleting the Connection Factory >>
<< Editing and Running the Programs | Deleting the Connection Factory >>

Repackaging the SynchConsumer Example

ant
5. Open the following file in a text editor:
tut-installjavaeetutorial5/examples/jms/simple/synchconsumer/src/java/SynchConsumer.java
6. Repeat steps 2 and 3.
7. Recompile and repackage the SynchConsumer example on jupiter.
If you are using NetBeans IDE, right-click the synchconsumer project and choose Clean and
Build Project.
If you are using Ant, go to the synchconsumer directory and type:
ant
8. On earth, run Producer. If you are using NetBeans IDE on earth, perform these steps:
a. Right-click the producer project and choose Properties.
b. Select Run from the Categories tree.
c. In the Arguments field, type the following:
queue 3
d. Click OK.
e. Right-click the project and choose Run Project.
If you are using the appclient command, go to the producer/dist directory and type
the following:
appclient -client producer.jar queue 3
9. On jupiter, run SynchConsumer. If you are using NetBeans IDE on jupiter, perform these
steps:
a. Right-click the synchconsumer project and choose Properties.
b. Select Run from the Categories tree.
c. In the Arguments field, type the following:
queue
d. Click OK.
e. Right-click the project and choose Run Project.
If you are using the appclient command, go to the synchconsumer/dist directory and
type the following:
appclient -client synchconsumer.jar queue
Writing Simple JMS Client Applications
The Java EE 5 Tutorial · September 2007
934