Archived

This forum has been archived. Please start a new discussion on GitHub.

Preference for local/Collocated services.

When using IceGrid (with period registry lookup refresh and random connection selection strategy) will collocated services still get preference?
Is there a way that regardless the connection caching/pickup strategy collecated services will always get a preference?

Comments

  • Please let me know if my question was not clear.
    Also, I wonder if it is possible (and are there any examples) of setting a combined Connection selection strategy such as weighted random based on load (or at least Random but don't consider heavy loaded machines unless this is the only ones available).
    Thx.
  • benoit
    benoit Rennes, France
    Hi,

    Yes, if possible and not disabled, collocation optimization will always be used in preference.

    We don't provide such a random weighted load balancing policy. See here in the Ice manual for more information on the load balancing policies supported by IceGrid.

    Cheers,
    Benoit.
  • benoit
    benoit Rennes, France
    Btw, I assume that by "collocated service" you meant a service which is running within the same process and using the same Ice communicator as the client (otherwise collocation optimization can't be used, see here for more information on collocation optimization).

    If by collocated service, you meant a service which is running on the same host but in a different process or within the same process but using a different Ice communicator, then the answer is no, IceGrid won't return in preference the endpoints of this local service.

    Cheers,
    Benoit.
  • Yes, this is what I meant by Collocated Services (though it would be nice to consider and have a preference for services on the same process or machine).
    Ok, it is good to know that what ever Connection caching and selection strategy on the client (like no Cache and Random selection) a preference will be given to services using the same Communicator (I assume that is true as long as the Registry considers and provides its end points?).