Results 1 to 6 of 6
  1. #1

    How to connect a client two multiple adapter

    Hi,
    I am running three different remote adapters in different location, so my question is that can all my remote adapters be connected to my single Robust network adapter.

    Please help me

  2. #2
    Power Member
    Join Date
    Feb 2008
    Location
    Siracusa
    Posts
    161
    Hi,

    could you please expand on these three remote adapters? Are such adapters independent of each other? How would Lightstreamer clients address them in terms of adapter set name and data adapter name (within the same adapter set)?

    Let us know.
    Gianluca

  3. #3
    Yes, we have three data providers(Remote adapter) will be run in three remote server.so my question is that can my single client able to subscribe with all the three adapters(Data Providers)

    Please help me

  4. #4
    Power Member
    Join Date
    Feb 2008
    Location
    Siracusa
    Posts
    161
    Hi kailashb,

    as per my understanding, I'am trying to depict the scenario you are going to setup.
    You have three different remote Data Providers (let's name them d1, d2, d3) belonging to the same Adapter Set with ID "MyRobustAdapter". So you need to prepare an adapters.xml file, outlined as follows:

    Code:
    <adapters_conf id="MyRobustAdapter">
        ...
        
        <metadata_provider>
            <adapter_class>ROBUST_PROXY_FOR_REMOTE_ADAPTER</adapter_class>
            <param name="request_reply_port">6667</param>
            ...
        </metadata_provider>
    
        <data_provider name="d1">
            <adapter_class>ROBUST_PROXY_FOR_REMOTE_ADAPTER</adapter_class>
            <param name="request_reply_port">6661</param>
            <param name="notify_port">6662</param>
            ...
        </data_provider>
        
        <data_provider name="d2">
            <adapter_class>ROBUST_PROXY_FOR_REMOTE_ADAPTER</adapter_class>
            <param name="request_reply_port">6663</param>
            <param name="notify_port">6664</param>
            ...
        </data_provider>
        
        <data_provider name="d3">
            <adapter_class>ROBUST_PROXY_FOR_REMOTE_ADAPTER</adapter_class>
    
            <param name="request_reply_port">6665</param>
            <param name="notify_port">6666</param>
            ...
        </data_provider>
    
    </adapters_conf>
    Basically, you will have to define a Robust Proxy Metadata Adapter listening on a specific tcp port for request/reply, and three Robust Proxy Data Adapters each one listening on two different ports for request/reply and notification.
    In the example proposed, only basic parameters are shown, but for further details see the comments embedded in the generic adapters.xml file template, you can find in DOCS-SDKs/adapter_remoting_infrastructure/doc/adapter_robust_conf_template/adapters.xml of your Lightstreamer 6 local installation.

    A client can connect to all Data Providers, by specifying the Adapter Set ID and Data Providers names. Here a very simple example using the JavaScript Client API:

    Code:
    // Setup and connect to Lightstreamer Server for using the MyRobustAdapter" Adapter Set.
    var ls = new LightstreamerClient(<host>, "MyRobustAdapter");
    ...
    ls.connect();
    ...
    
    // Setup three subscriptions for each configured Data Provider.
    var s1 = new Subscription(<mode>,<items>,<fields>);
    s1.setDataAdapter("d1");
    
    var s2 = new Subscription(<mode>,<items>,<fields>);
    s2.setDataAdapter("d2");
    
    var s3 = new Subscription(<mode>,<items>,<fields>);
    s3.setDataAdapter("d3");
    
    // Submit the subscriptions.
    ls.subscribe(s1);
    ls.subscribe(s2);
    ls.subscribe(s3);
    ...
    Hope this helps, but please get back to us for any doubt.
    Gianluca

  5. #5
    Thanx a lot for depicting scenario . perfect answer got it

  6. #6
    Power Member
    Join Date
    Feb 2008
    Location
    Siracusa
    Posts
    161
    Thanks for your feedback!

    Gianluca

 

 

Similar Threads

  1. Replies: 14
    Last Post: November 24th, 2020, 04:48 PM
  2. Replies: 3
    Last Post: November 14th, 2011, 10:33 AM
  3. Replies: 2
    Last Post: December 24th, 2010, 08:51 AM
  4. Two Instance in One Page Browser using IFrame
    By gani in forum Client SDKs
    Replies: 1
    Last Post: May 19th, 2010, 10:26 AM
  5. 2 ArrayList for two pages ?? (StockList example)
    By mohamida in forum Adapter SDKs
    Replies: 2
    Last Post: November 17th, 2009, 03:46 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT +1. The time now is 10:05 AM.