NIP Session and INT session in one config file

In the TREPS 3 configuration example below, there are 2 sessions defined :-Connection_XTRA_RSSL_INT,Connection_XTRA_RSSL_NIP, which are configured to connect to different servers ads-int.intra and ads-nip.intra

\Sessions\XtraOMMSession\connectionList = "Connection_XTRA_RSSL_INT,Connection_XTRA_RSSL_NIP" \Sessions\XtraOMMSessionContrib\connectionList = " Connection_XTRA_RSSL_NIP" \Adapters\RSSL_Cons_Adapter\singleton = false

\XTRA\Common\RDMFDataDictAccess = "DOWNLOAD"

\XTRA\Common\MfeedDataDictAccess = "LOAD" \Connections\Connection_XTRA_RSSL_INT\connectionType = "RSSL" \Connections\Connection_XTRA_RSSL_INT\rsslport = "14002" \Connections\Connection_XTRA_RSSL_INT\ServerList = "ads-int.intra" \Connections\Connection_XTRA_RSSL_NIP\connectionType = "RSSL" \Connections\Connection_XTRA_RSSL_NIP \rsslport = "14002" \Connections\Connection_XTRA_RSSL_NIP\ServerList = "ads-nip.intra"

Therefore what I want to do is when my application, connecting using the TREPS3 configuration connects, it will make 2 mounts per session, 2 mounts split between different servers.

Does anyone knows how to do this? How to have Session.aquire() can give me a session that is split between two servers?

Thanks

Best Answer

  • Hello @5c9f43d0-0efe-4df2-b156-eea9f0359498

    In RFA Java, a single RFA Session can have multiple mounts on different servers by calling Session.aquire(<session_name>) when <session_name>’s connectionList parameter contains multiple connections. Each connection node specifies each server. Hence, when your application runs, the session is split between the connections (connect to the servers) simultaneously.

    For example: based on the given configuration, modify [RFA_Java_Package]\QuickStart\quickstart.xml as the steps below:

    1. Under myNamespace\Connections node add Connection_XTRA_RSSL_INT and Connection_XTRA_RSSL_NIP connection node:

                  <node name="Connection_XTRA_RSSL_INT">
    <map>
    <entry key="connectionType" value="RSSL"/>
    <entry key="serverList" value="ads-int.intra"/>
    <entry key="portNumber" value="14002"/>
    </map>
    </node>
    <node name="Connection_XTRA_RSSL_NIP">
    <map>
    <entry key="connectionType" value="RSSL"/>
    <entry key="serverList" value="ads-nip.intra"/>
    <entry key="portNumber" value="14002"/>
    </map>
    </node>

      2. Under myNamespace\Sessions node add XtraOMMSession which connectionList contains Connection_XTRA_RSSL_INT and Connection_XTRA_RSSL_NIP connection node defined in the previous step:

      	      <node name="XtraOMMSession">
      <map>
      <entry key="connectionList" value="myNamespace::Connection_XTRA_RSSL_INT,myNamespace::Connection_XTRA_RSSL_NIP"/>
      </map>
      </node>

      3. Save quickstart.xml. To import the RFA configuration in quickstart.xml into the machine. At [RFA_Java_Package]\Tools, type:

      java -jar config_loader.jar -file [RFA_Java_Package]\QuickStart\quickstart.xml

      4. Make sure that the application loads the correct session. From the previous steps, the session name which is the input of Session.acquire(..) should be myNamespace::XtraOMMSession. For example:

      _session = 
      Session.acquire("myNamespace::XtraOMMSession");

        After doing the steps above and running the application, I saw the result which shows 2 mounts split between different servers:

        image

        Hope this help.

      Answers