Results 1 to 4 of 4
  1. #1

    How to change items names in a group after IMetadataProvider.GetItems() is called

    From your help: (Lightstreamer .Net Adapter 1.7)
    IMetadataProvider string[] GetItems(string user, string sessionID, string group);
    "Called by Lightstreamer Kernel through the Remote Server to resolve an Item Group name (or Item List specification) supplied in a Request.
    The names of the Items in the Group must be returned. For instance, the client could be allowed to specify the "NASDAQ100" Group name and,
    upon that, the list of all items corresponding to the stocks included in that index could be returned."

    The question:
    The group "NASDAQ100" changes every few months, that is new stokes are entered or removed from "NASDAQ100".
    How should I notify the clients about these changes in the items that constitute the group ?


  2. #2
    Join Date
    Jul 2006
    In fact, the reported example based on NASDAQ100 assumes a short time frame.
    If clients are expected to reopen the page every day and the NASDAQ100 composition changes overnight, they will perform a new subscription request each morning, hence getting the right composition.

    If you consider a longer time frame and accept that a client subscription can last for days, then the problem arises.
    You can address the problem at application level, by having your application subscribe to a custom notification item, which will instruct the page to unsubscribe from the NASDAQ100 group, then resubscribe, when needed.
    Otherwise, you could resort to COMMAND mode; a single item in COMMAND mode represents a dynamical list and would replace the whole group, allowing you to add and remove elements when the composition of the list changes (see the PortolioDemo for a typical case).

  3. #3
    so I need to choose between re-subscribe and command mode...

    BTW, is command mode sends more data per update than merge (since we send item+command+key)


  4. #4
    Join Date
    Feb 2012
    Hi Avi,

    You are right, generally COMMAND mode sends more data than MERGE mode, but if you implement a subscription with "two-level push" (as our PorfolioDemo does) then the outgoing bandwidth will be very similar to the MERGE mode.




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:05 PM.