Api jms download




















A client uses a QueueReceiver object to receive messages that have been delivered to a queue. A ServerSession object is an application server object that is used by a server to associate a thread with a JMS session optional.

A ServerSessionPool object is an object implemented by an application server to provide a pool of ServerSession objects for processing the messages of a ConnectionConsumer optional.

A Session object is a single-threaded context for producing and consuming messages. A StreamMessage object is used to send a stream of primitive types in the Java programming language.

A TemporaryQueue object is a unique Queue object created for the duration of a Connection. A TemporaryTopic object is a unique Topic object created for the duration of a Connection. A TextMessage object is used to send a message containing a java.

A client uses a TopicPublisher object to publish messages on a topic. A client uses a TopicSubscriber object to receive messages that have been published to a topic. The QueueRequestor helper class simplifies making service requests. The TopicRequestor helper class simplifies making service requests. This exception is thrown when a method is invoked at an illegal or inappropriate time or if the provider is not in an appropriate state for the requested operation. This unchecked exception is thrown when a method is invoked at an illegal or inappropriate time or if the provider is not in an appropriate state for the requested operation, and the method signature does not permit a IllegalStateRuntimeException to be thrown.

This exception must be thrown when a client attempts to set a connection's client ID to a value that is rejected by a provider. This unchecked exception must be thrown when a client attempts to set a connection's client ID to a value that is rejected by a provider, and the method signature does not permit a InvalidClientIDException to be thrown.

This exception must be thrown when a destination either is not understood by a provider or is no longer valid. This unchecked exception must be thrown when a destination either is not understood by a provider or is no longer valid, and the method signature does not permit a InvalidDestinationException to be thrown.

This exception must be thrown when a JMS client attempts to give a provider a message selector with invalid syntax. This unchecked exception must be thrown when a JMS client attempts to give a provider a message selector with invalid syntax, and the method signature does not permit a InvalidSelectorException to be thrown.

This exception must be thrown when an unexpected end of stream has been reached when a StreamMessage or BytesMessage is being read. This exception must be thrown when a JMS client attempts to use a data type not supported by a message or attempts to read data in a message as the wrong type. This unchecked exception must be thrown when a JMS application attempts to use a data type not supported by a message or attempts to read data in a message as the wrong type, and the method signature does not permit a MessageFormatException to be thrown.

This exception must be thrown when a JMS client attempts to read a write-only message. This exception must be thrown when a JMS client attempts to write to a read-only message. This unchecked exception must be thrown when a JMS client attempts to write to a read-only message. This exception is thrown when a provider is unable to allocate the resources required by a method.

This unchecked exception is thrown when a provider is unable to allocate the resources required by a method. This exception is thrown when an operation is invalid because a transaction is in progress. This unchecked exception is thrown when an operation is invalid because a transaction is in progress.

This exception must be thrown when a call to Session. This unchecked exception must be thrown when a call to JMSContext.

This annotation may be used to specify the JNDI lookup name of a javax. ConnectionFactory to be used when injecting a javax. JMSContext object. An application may use this annotation to specify a JMS ConnectionFactory resource that it requires in its operational environment. An application may use this annotation to specify a JMS Destination resource that it requires in its operational environment. This annotation may be used to specify the userName and password to be used when injecting a javax.

This annotation may be used to specify the session mode to be used when injecting a javax. Administration JMS providers differ significantly in their implementations of underlying messaging technology. There are two types of JMS administered objects: ConnectionFactory - the object a client uses to create a connection with a JMS provider Destination - the object a client uses to specify the destination of messages it is sending and the source of messages it receives Administered objects are placed by an administrator in a JNDI Java Naming and Directory Interface namespace.

A BytesMessage object is used to send a message containing a stream of uninterpreted bytes. A Destination object encapsulates a provider-specific address. A MapMessage object is used to send a set of name-value pairs. Using Converters, Listeners, and Validators. Developing with JavaServer Faces Technology. Composite Components: Advanced Topics and Example. Configuring JavaServer Faces Applications. Uploading Files with Java Servlet Technology. Internationalizing and Localizing Web Applications.

Using the Embedded Enterprise Bean Container. Getting Started Securing Web Applications. Getting Started Securing Enterprise Applications.

Messaging is a method of communication between software components or applications. A messaging system is a peer-to-peer facility: A messaging client can send messages to, and receive messages from, any other client. Each client connects to a messaging agent that provides facilities for creating, sending, receiving, and reading messages.

Messaging enables distributed communication that is loosely coupled. A component sends a message to a destination, and the recipient can retrieve the message from the destination. However, the sender and the receiver do not have to be available at the same time in order to communicate. In fact, the sender does not need to know anything about the receiver; nor does the receiver need to know anything about the sender.

The sender and the receiver need to know only which message format and which destination to use. Messaging also differs from electronic mail email , which is a method of communication between people or between software applications and people.

Messaging is used for communication between software applications or software components. Designed by Sun and several partner companies, the JMS API defines a common set of interfaces and associated semantics that allow programs written in the Java programming language to communicate with other messaging implementations. The JMS API minimizes the set of concepts a programmer must learn in order to use messaging products but provides enough features to support sophisticated messaging applications.

Asynchronous : A JMS provider can deliver messages to a client as they arrive; a client does not have to request messages in order to receive them. Lower levels of reliability are available for applications that can afford to miss messages or to receive duplicate messages. The current version of the JMS specification is Version 1. An enterprise application provider is likely to choose a messaging API over a tightly coupled API, such as a remote procedure call RPC , under the following circumstances.

The provider wants the application to run whether or not all components are up and running simultaneously. The application business model allows a component to send information to another and to continue to operate without receiving an immediate response. For example, components of an enterprise application for an automobile manufacturer can use the JMS API in situations like these:.

The inventory component can send a message to the factory component when the inventory level for a product goes below a certain level so the factory can make more cars. The factory component can send a message to the parts components so the factory can assemble the parts it needs. The parts components in turn can send messages to their own inventory and order components to update their inventories and to order new parts from suppliers.

Both the factory and the parts components can send messages to the accounting component to update budget numbers. Using messaging for these tasks allows the various components to interact with one another efficiently, without tying up network or other resources. Figure illustrates how this simple example might work. Retail applications, financial services applications, health services applications, and many others can make use of messaging.

Beginning with the 1. Application clients can in addition receive JMS messages asynchronously. Message-driven beans, which are a kind of enterprise bean, enable the asynchronous consumption of messages.

A JMS provider can optionally implement concurrent processing of messages by message-driven beans. Message send and receive operations can participate in distributed transactions, which allow JMS operations and database accesses to take place within a single transaction.



0コメント

  • 1000 / 1000