next up previous contents
Next: Simple Policies Up: Policy Implementation Previous: Policy Implementation   Contents

General Concepts

Recall from Section 3.3.2 that policy implementations are called from the policy-switching component. Firstly, it forwards all the policy initialization and destruction calls, so that each of the policy implementations could initialize and release any resources it needs. Secondly, for each client query, it retrieves the list of candidate replicas from the database and passes them to the implementation of the policy that has been configured for the site in question. The implementation-specific functions accept the following parameters:
  1. The IP address of the client;
  2. The identifier of the site that replicas belong to;
  3. The IP addresses of replicas;
  4. The current configuration of the redirector;
  5. An empty table for the policy to return the result.
The site name that is passed to the policy-switching component is translated to a site identifier. A policy implementation can use it to identify any policy-internal, site-related data. Also, since the list of replicas is passed as parameter, policy implementations do not need to contact the replica database. In this way they work independently from the rest of the redirector.


next up previous contents
Next: Simple Policies Up: Policy Implementation Previous: Policy Implementation   Contents
root 2002-08-27