14.2.2. POJOs


The same Connector could be configured by way of the org.jboss.remoting.ServerConfiguration POJO:
     <bean name="JBMConnector" class="org.jboss.remoting.transport.Connector">
       <annotation>@org.jboss.aop.microcontainer.aspects.jmx.JMX
        (name="jboss.messaging:service=Connector,transport=bisocket",
        exposedInterface=org.jboss.remoting.transport.ConnectorMBean.class,
        registerDirectly=true)</annotation>
       <property name="serverConfiguration"><inject bean="JBMConfiguration"/></property>
     </bean>
     
     <!-- Remoting server configuration -->
     <bean name="JBMConfiguration" class="org.jboss.remoting.ServerConfiguration">
       <constructor>
         <parameter>bisocket</parameter>
       </constructor>
     
        <!-- Parameters visible to both client and server -->
       <property name="invokerLocatorParameters">
         <map keyClass="java.lang.String" valueClass="java.lang.String">
           <entry>
             <key>serverBindAddress</key>
             <value>
               <value-factory bean="ServiceBindingManager" method="getStringBinding">
                 <parameter>JBMConnector</parameter>
                 <parameter>${host}</parameter>
               </value-factory>
             </value>
           </entry>
           <entry>
             <key>serverBindPort</key>
             <value>
               <value-factory bean="ServiceBindingManager" method="getStringBinding">
                 <parameter>JBMConnector</parameter>
                 <parameter>${port}</parameter>
               </value-factory>
             </value>
           </entry>
              ...
           <entry><key>marshaller</key> <value>org.jboss.jms.wireformat.JMSWireFormat</value></entry>
           <entry><key>unmarshaller</key> <value>org.jboss.jms.wireformat.JMSWireFormat</value></entry>
         </map
       </property>
       
       <!-- Parameters visible only to server -->
       <property name="serverParameters">
         <map keyClass="java.lang.String" valueClass="java.lang.String">
           <entry><key>callbackTimeout</key> <value>10000</value></entry>
         </map>
       </property>
                                  
        ...
     </bean>
Copy to Clipboard Toggle word wrap
In this version, the configuration information is expressed in the JBMConfiguration ServerConfiguration POJO, which is then injected into the JBMConnector org.jboss.remoting.transport.Connector POJO. The syntax is that of the Microcontainer, which is beyond the scope of this chapter. See Chapter 8, Microcontainer for details. One variation from the MBean version is the use of the ServiceBindingManager, which is also beyond the scope of this chapter. Note that the @org.jboss.aop.microcontainer.aspects.jmx.JMX annotation causes the JBMConnector to be visible as an MBean named "jboss.messaging:service=Connector,transport=bisocket".
トップに戻る
Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

Red Hat ドキュメントについて

Red Hat をお使いのお客様が、信頼できるコンテンツが含まれている製品やサービスを活用することで、イノベーションを行い、目標を達成できるようにします。 最新の更新を見る.

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

Theme

© 2025 Red Hat