Cross-Application Service Variations

You can have many applications which house a slave service, for example, application A can house master service Sample. Applications B, C and D can all house slave services of Sample.

You can also have "slaves of slaves", in a similar manner to "clients of clients", the primary difference being that, because the slaves are in separate applications from the master, they can exist on the same machine (but don’t all have to).

To configure a "slave of a slave" configure an intermediate application service instance (the slave) to be the master for a second application. For example, if application A (GUID GA) houses the master service Sample, application B (GUID GB) houses a slave service Sample and application C (GUID GC) houses the slave of slave Sample, then create a RemoteGUID variable in service Sample of application B and set it to GUID GA and create a RemoteGUID variable in service Sample of application C and set it to GUID GB. Now, B’s Sample service will synchronize with and follow the server of application A’s Sample service and C’s Sample service will synchronize with B’s Sample service.

Beware that this can become complex. Consider the following example, in which three machines (FRED, JOE and BOB) each have an instance of applications A, B and C. Application A houses the master service, application B houses the slave service and application C houses the slave of slave service. Assume, also, that the server lists for the service have been configured FRED, then JOE for machines FRED and JOE, but only JOE for machine BOB (i.e. BOB is a client of a client):

Once again, the arrows point to the server instance of each service. Note that, because the slave services cannot be servers, they can only follow their master server location. For application B, the master is housed in application A and so, therefore, all application B slave services will have the current application A server as their current master. Because application B’s service instance can not be a server status (rather it is a master to application C’s slave service) all application C slaves regard the application B on the same machine as their master.

Be clear about this distinction between server and master: A server instance of a service has an RPCStatus (a pointer to which is returned from the register call) of server(2). A master instance of a service may have an RPCStatus of server(2) OR client(1), depending on whether it is server. A slave can not have an RPCStatus of server(2). Any instance can have an RPCStatus of unknown(0).