Consumer endpoint configuration is specified using the jms:conduit
element. Using this configuration element, you specify the message type supported by the consumer endpoint using the jms:runtimePolicy
child element. The message type is specified using the messageType
attribute. The messageType
attribute has two possible values:
Table 6.2. messageType
Values
text | Specifies that the data will be packaged as a TextMessage . |
binary | specifies that the data will be packaged as an ByteMessage . |
Example 6.4 shows a configuration entry for configuring a JMS consumer endpoint.
Example 6.4. Configuration for a JMS Consumer Endpoint
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ct="http://cxf.apache.org/configuration/types" xmlns:jms="http://cxf.apache.org/transports/jms" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd" http://cxf.apache.org/jaxws http://cxf.apache.org/schemas/jaxws.xsd http://cxf.apache.org/transports/jms http://cxf.apache.org/schemas/configuration/jms.xsd"> ... <jms:conduit name="{http://cxf.apache.org/jms_endpt}HelloWorldJMSPort.jms-conduit"> <jms:address ... > ... </jms:address> ... <jms:runtimePolicy messageType="binary"/> ... </jms:conduit> ... </beans>