Results 1 to 10 of 10

Hybrid View

  1. #1
    Member
    Join Date
    Sep 2007
    Location
    Chicago
    Posts
    20

    How to specify the Adapter mode

    It is just a matter of sending the key/value of (COMMAND, ADD/UPDATE) in the 'Update by MAP' protocol?

    I did this in a Java adapter but not sure how to do this in ARI.

    Thanks,
    Kal

  2. #2
    Administrator
    Join Date
    Jul 2006
    Location
    Milan
    Posts
    973
    Yes; if you are providing data for an item to be subscribed in COMMAND mode, then your "UD3" messages should contain
    a string field named "command", valued with one out of "ADD", "UPDATE" and "DELETE"
    and a string field named "key", valued with the current key,
    as well as the other fields.

    Dario

  3. #3
    Member
    Join Date
    Sep 2007
    Location
    Chicago
    Posts
    20
    Great! Thank you.

  4. #4
    Member
    Join Date
    Sep 2007
    Location
    Chicago
    Posts
    20
    Dario,

    Just to verify, is this a good format? This is for a view with 2 rows. I am trying add key1 and key2 rows.

    <timestamp>|UD3|S|<item name>|S|<ID>|B|<is snapshot>|S|key|S|key1|S|command|S|ADD|S|<field 1>|S|<value 1>|<field 2>|S|<value 2>|S|key|S|key2|S|command|S|ADD|S|<field 1>|S|<value 1>|<field 2>|S|<value 2>|

    Thanks
    -Kal

  5. #5
    Administrator
    Join Date
    Jul 2006
    Location
    Milan
    Posts
    973
    Kal,

    You need two distinct update lines for the two keys:
    <timestamp>|UD3|S|<item name>|S|<ID>|B|<is snapshot>|S|key|S|key1|S|command|S|ADD|S|<field 1>|S|<value 1>|<field 2>|S|<value 2>
    <timestamp>|UD3|S|<item name>|S|<ID>|B|<is snapshot>|S|key|S|key2|S|command|S|ADD|S|<field 1>|S|<value 1>|<field 2>|S|<value 2>
    This also holds when you are providing the initial snapshot.
    I have also removed the trailing '|' separator, though it is probably tolerated by the Proxy Adapter.

    Dario

  6. #6
    Member
    Join Date
    Sep 2007
    Location
    Chicago
    Posts
    20
    Dario,

    In case of a portfolio case, we don't know the number of entries. How can we add/remove multiple rows? I consider the item as a group of say, securities in a portfolio.

    Thanks
    Kal

 

 

Similar Threads

  1. Data Adapter sample for COMMAND mode
    By Otake in forum Adapter APIs
    Replies: 5
    Last Post: October 18th, 2009, 07:09 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 12:42 PM.