Add missing license headers to packetcable-driver rcd
[packetcable.git] / packetcable-driver / src / main / java / org / pcmm / rcd / IPCMMServer.java
1 /*
2  * Copyright (c) 2014, 2015 Cable Television Laboratories, Inc. and others.  All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8
9 package org.pcmm.rcd;
10
11 import org.pcmm.concurrent.IWorker;
12 import org.pcmm.state.IStateful;
13
14 import java.io.IOException;
15
16 /**
17  * <p>
18  * As discussed in RFC 2753 [11], the policy management framework underlying
19  * PacketCable Multimedia is based on the work of the IETF's Resource Allocation
20  * Protocol (RAP) working group. Since the Policy Server is situated between the
21  * Application Manager and the CMTS, it simultaneously plays a dual role as a
22  * "proxy" for AM-initiated session requests and as a "sentry" for defining and
23  * enforcing Resource Control Domain policy.
24  * </p>
25  * <p>
26  * As described in [11] and in keeping with the PacketCable 1.x DQoS model, the
27  * Policy Server serves as Policy Decision Point (PDP) in relation to the CMTS
28  * resource-management procedures. Conversely, the Policy Server assumes the
29  * role of Policy Enforcement Point (PEP) in relation to the Application Manager
30  * as it proxies Gate Control messages to and from the CMTS element.
31  * </p>
32  * <p>
33  * To revisit the interaction scenario, the Application Manager issues policy
34  * requests to the Policy Server. The Policy Server acting as a "sentry" for
35  * these requests, and applies a set of policy rules that have been
36  * pre-provisioned by the MSO. Upon passing the checks, the Policy Server then
37  * acts as a "proxy" with respect to the Application Manager and the CMTS,
38  * forwarding the policy request and returning any associated response. Each
39  * policy request transaction must be processed individually.
40  * </p>
41  * <p>
42  * Policy decisions may be based on a number of factors, such as:
43  * <ul>
44  * <li>Parameters associated with the request and the status of available
45  * resources</li>
46  * <li>Identity of the particular client and associated profile information</li>
47  * <li>Application parameters</li>
48  * <li>Security considerations</li>
49  * <li>Time-of-day</li>
50  * </ul>
51  * The primary functions of the Policy Server include:
52  * <ul>
53  * <li>A policy decision request mechanism, invoked by Application Managers</li>
54  * <li>A policy decision request 'policing' mechanism, enforcing installed
55  * Policy Rules</li>
56  * <li>A policy decision delivery mechanism, used to install policy decisions on
57  * the CMTS</li>
58  * <li>A mechanism to allow for the proxying of QoS management messages to the
59  * CMTS on behalf of the Application Manager</li>
60  * <li>An event recording interface to a Record Keeping Server that is used to
61  * log policy requests, which may in turn be correlated with network resource
62  * usage records</li>
63  * </ul>
64  * <p>
65  * Since the Policy Server functions as a proxy between the AM and CMTS elements
66  * (with complementary client and server interfaces) some MSOs may elect to
67  * deploy multiple layers of Policy Servers and to delegate certain policy
68  * decisions among these servers in order to satisfy requirements associated
69  * with scalability and fault-tolerance.
70  * </p>
71  * </p>
72  */
73 public interface IPCMMServer extends IStateful {
74
75     /**
76      * Starts all connections and threads
77      */
78     void startServer() throws IOException;
79
80     /**
81      * Stops all connections and threads
82      */
83     void stopServer();
84
85     /**
86      * When a client connects to the server, a handler is needed to manage the
87      * exchange of the messages between this client and the server.
88      */
89     interface IPCMMClientHandler extends IWorker, IPCMMClient {
90         /**
91          * Responsible for closing resources such as server connections or threads
92          */
93         void stop();
94     }
95 }