Understanding WebLogic JMS 2-19
■
JMS 1.1. Specification, described at http:java.sun.comproductsjmsdocs.html
2.4.6.3 Message Body
A message body contains the content being delivered from producer to consumer. The following table describes the types of messages defined by JMS. All message types
extend javax.jms.Message, at http:java.sun.comjavaee5docsapijavaxjmsMessage.html
, which consists of message headers and properties, but no message body.
For more information, see the javax.jms.Message Javadoc at http:java.sun.comjavaee5docsapijavaxjmsMessage.html
. For more information about the access methods and, if applicable, the conversion charts
associated with a particular message type, see the Javadoc for that message type.
2.4.7 ServerSessionPoolFactory
Table 2–12 JMS Message Types
Type Description
javax.jms.BytesMessage Stream of uninterpreted bytes, which must be understood by
the sender and receiver. The access methods for this message type are stream-oriented readers and writers based on
java.io.DataInputStream and java.io.DataOutputStream. See
http:java.sun.comjavaee5docsapijavax jmsBytesMessage.html
. javax.jms.MapMessage
Set of namevalue pairs in which the names are strings and the values are Java primitive types. Pairs can be read
sequentially or randomly, by specifying a name. javax.jms.ObjectMessage
Single serializable Java object. See http:java.sun.comjavaee5docsapijavax
jmsObjectMessage.html .
javax.jms.StreamMessage Similar to a BytesMessage, except that only Java primitive
types are written to or read from the stream. See http:java.sun.comjavaee5docsapijavax
jmsStreamMessage.html .
javax.jms.TextMessage Single String. The TextMessage can also contain XML
content. See http:java.sun.comjavaee5docsapijavax
jmsTextMessage.html .
weblogic.jms.extensions.XML Message
XML content. Use of the XMLMessage type facilitates message filtering, which is more complex when performed
on XML content shipped in a TextMessage.
Note: Session pool and connection consumer configuration objects
are deprecated in this release of WebLogic Server. They are not a required part of the Java EE specification, do not support JTA user
transactions, and are largely superseded by message-driven beans MDBs, which are simpler, easier to manage, and more capable. For
more information on designing MDBs, see Message-Driven EJBs in Programming WebLogic Enterprise JavaBeans for Oracle WebLogic Server.
2-20 Programming JMS for Oracle WebLogic Server
A server session pool is a WebLogic-specific JMS feature that enables you to process messages concurrently. A server session pool factory is used to create a server-side
ServerSessionPool.
WebLogic JMS defines one ServerSessionPoolFactory object, by default: weblogic.jms.extensions.ServerSessionPoolFactory:name, where
name specifies the name of the JMS server to which the session pool is created. The WebLogic Server adds the default server session pool factory to the JNDI space during
startup and the application subsequently retrieves the server session pool factory using WebLogic JNDI.
To learn how to use the server session pool factory within an application, see Section A.1, Defining Server Session Pools,
or the weblogic.jms.extnesions.ServerSessionPoolFactory Javadoc.
2.4.8 ServerSessionPool
A ServerSessionPool application server object provides a pool of server sessions that connection consumers can retrieve in order to process messages concurrently.
A ServerSessionPool is created by the ServerSessionPoolFactory object see Section 2.4.7, ServerSessionPoolFactory
obtained through a JNDI lookup. To learn how to use the server session pool within an application, see
Section A.1, Defining Server Session Pools,
or the javax.jms.ServerSessionPool Javadoc at http:java.sun.comjavaee5docsapijavaxjmsServerSessionPoo
l.html .
2.4.9 ServerSession
A ServerSession application server object enables you to associate a thread with a JMS session by providing a context for creating, sending, and receiving messages.
A ServerSession is created by a ServerSessionPool object, described in Section 2.4.8, ServerSessionPool.
To learn how to use the server session within an application, see Section A.1, Defining
Server Session Pools, or the javax.jms.ServerSession Javadoc at
http:java.sun.comjavaee5docsapijavaxjmsServerSession.ht ml
.
2.4.10 ConnectionConsumer