Catch certain updates at sync server side?

CapableObjects Forums SupportForum Catch certain updates at sync server side?

This topic contains 1 reply, has 2 voices, and was last updated by  Admin 1 week, 4 days ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #5017 Score: 0

    krilbe
    Participant

    Hi,

    I’m building a Windows service that will (among other things) act as a MDriven sync server.

    In this service, I’d like to perform certain special actions whenever new instances of a specific class are created.

    How do I catch “new instance” events?

    It’s possible that I’d like to trigger actions based on attribute or link changes as well. How do I catch those?

    In my client code I already have a cache inserted in the EcoSpace, like this:

    MyCache cache = new MyCache(FrontsidePolicy.ObjectRepresentationProvider);
    cache.NextCache = FrontsidePolicy.Cache;
    FrontsidePolicy.Cache = cache;

    I suppose it’s something similar, but at the sync server side, that I need. I am under the impression that the EcoSpace there is only used for type info, so I assume that inserting a cache in that EcoSpace wouldn’t help. Am I wrong?

    #5020 Score: 0

    Admin
    Keymaster

    Hi,
    The Persistencemapper on a lean server side does not have a cache. It is totally stateless. It only gets datablock that contains enough information for identity and what the old and new value is per changed property.
    The Model information on the server side is only used for the persistence mapping – ie how the changes in the datablock translates to crud operations.
    (Sync server holds state – but only identities and version number)

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

Comments are closed.