9.2. Writing and Compiling the Application Components
Writing and compiling the components of the application involve
Coding the application client
Coding the message-driven beans
Coding the entity bean
Compiling the source files
9.2.1. Coding the Application Client: HumanResourceClient.java
The application client program, HumanResourceClient.java, performs the following steps:
1. |
Uses the Java Naming and Directory Interface (JNDI) API naming context java:comp/env to look up a TopicConnectionFactory, a QueueConnectionFactory, and a topic
|
2. |
Creates a TemporaryQueue to receive notification of processing that occurs, based on new-hire events it has published
|
3. |
Creates a QueueReceiver for the TemporaryQueue, sets the QueueReceiver's message listener, ... |
Get Java™ Message Service API Tutorial and Reference: Messaging for the J2EE™ Platform now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.