KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > ejbca > ui > web > pub > cluster > IHealthResponse


1 /*************************************************************************
2  * *
3  * EJBCA: The OpenSource Certificate Authority *
4  * *
5  * This software is free software; you can redistribute it and/or *
6  * modify it under the terms of the GNU Lesser General Public *
7  * License as published by the Free Software Foundation; either *
8  * version 2.1 of the License, or any later version. *
9  * *
10  * See terms of license at gnu.org. *
11  * *
12  *************************************************************************/

13
14 package org.ejbca.ui.web.pub.cluster;
15
16 import javax.servlet.ServletConfig JavaDoc;
17 import javax.servlet.http.HttpServletResponse JavaDoc;
18
19
20 /**
21  * Inteface used to generate apporiate responses to different LoadBalancers HTTP requests.
22  *
23  * @author Philip Vendil
24  * @version $Id: IHealthResponse.java,v 1.2 2006/02/08 07:31:48 anatom Exp $
25  */

26 public interface IHealthResponse {
27     
28     /**
29      * Method used to initialize the health checker responder with parameters set
30      * in the web.xml file.
31      *
32      *
33      */

34     public void init(ServletConfig JavaDoc config);
35     
36     /**
37      * Method in charge of creating a response to the loadbalancer that this node in the
38      * cluster shouldn't be used.
39      *
40      * @param status, if status is null then everything is OK, othervise failure with a errormessage
41      * that might be used in the reply.
42      * @param resp the HttpServletResponse.
43      */

44     public void respond(String JavaDoc status, HttpServletResponse JavaDoc resp);
45
46 }
47
Popular Tags