You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by az...@apache.org on 2008/05/17 08:31:44 UTC
svn commit: r657297 - in
/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering:
configuration/ConfigurationManager.java context/ContextManager.java
Author: azeez
Date: Fri May 16 23:31:43 2008
New Revision: 657297
URL: http://svn.apache.org/viewvc?rev=657297&view=rev
Log:
More javadocs
Modified:
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/configuration/ConfigurationManager.java
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/context/ContextManager.java
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/configuration/ConfigurationManager.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/configuration/ConfigurationManager.java?rev=657297&r1=657296&r2=657297&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/configuration/ConfigurationManager.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/configuration/ConfigurationManager.java Fri May 16 23:31:43 2008
@@ -23,6 +23,42 @@
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.description.ParameterInclude;
+/**
+ * <p>
+ * This interface is responsible for handling configuration management. Configuraion changes include
+ * <p/>
+ * <ul>
+ * <li>Rebooting an entire cluster, in which case, all nodes have to load the new Axis2 configuration
+ * in a consistent manner
+ * </li>
+ * <li>
+ * Deploying a new service to a cluster or undeploying a service from a cluster
+ * </li>
+ * <li>
+ * Changing the policies of a service deployed on the cluster
+ * </li>
+ * </ul>
+ * </p>
+ * <p>
+ * It is not mandatory to have a ConfigurationManager in a node. In which case the cluster may be
+ * used only for <a href="http://afkham.org/2008/05/definition-of-high-availability.html">
+ * High Availability</a> through context replication. However, it is difficult to imagine that
+ * a cluster will be deployed in production with only context replication but without cluster
+ * configuration management.
+ * </p>
+ * <p>
+ * The implementation of this interface is set by the
+ * {@link org.apache.axis2.deployment.ClusterBuilder}, by
+ * reading the "configurationManager" element in the axis2.xml
+ * <p/>
+ * e.g.
+ * <code>
+ * <b>
+ * <configurationManager class="org.apache.axis2.cluster.configuration.TribesConfigurationManager">
+ * </b>
+ * </code>
+ * </p>
+ */
public interface ConfigurationManager extends ParameterInclude {
// ###################### Configuration management methods ##########################
@@ -30,7 +66,7 @@
* Load a set of service groups
*
* @param serviceGroupNames The set of service groups to be loaded
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while loading service groups
*/
void loadServiceGroups(String[] serviceGroupNames) throws ClusteringFault;
@@ -38,7 +74,7 @@
* Unload a set of service groups
*
* @param serviceGroupNames The set of service groups to be unloaded
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while unloading service groups
*/
void unloadServiceGroups(String[] serviceGroupNames) throws ClusteringFault;
@@ -47,14 +83,14 @@
*
* @param serviceName The name of the service to which this policy needs to be applied
* @param policy The serialized policy to be applied to the service
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while applying service policies
*/
void applyPolicy(String serviceName, String policy) throws ClusteringFault;
/**
* Reload the entire configuration of an Axis2 Node
*
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while reinitializing Axis2
*/
void reloadConfiguration() throws ClusteringFault;
@@ -64,14 +100,15 @@
* First phase of the 2-phase commit protocol.
* Notifies a node that it needs to prepare to switch to a new configuration.
*
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while preparing to commit
*/
void prepare() throws ClusteringFault;
/**
* Rollback whatever was done
*
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while rolling back a cluster configuration
+ * transaction
*/
void rollback() throws ClusteringFault;
@@ -79,7 +116,8 @@
* Second phase of the 2-phase commit protocol.
* Notifies a node that it needs to switch to a new configuration.
*
- * @throws ClusteringFault
+ * @throws ClusteringFault If an error occurs while committing a cluster configuration
+ * transaction
*/
void commit() throws ClusteringFault;
@@ -89,18 +127,24 @@
* of a {@link ConfigurationClusteringCommand}
*
* @param throwable The throwable which has to be propogated to other nodes
+ * @throws org.apache.axis2.clustering.ClusteringFault
+ * If an error occurs while processing the
+ * exception message
*/
void exceptionOccurred(Throwable throwable) throws ClusteringFault;
/**
* For registering a configuration event listener.
+ *
+ * @param listener The ConfigurationManagerListener instance
*/
void setConfigurationManagerListener(ConfigurationManagerListener listener);
/**
- * Set the configuration context
+ * Set the system's configuration context. This will be used by the clustering implementations
+ * to get information about the Axis2 environment and to correspond with the Axis2 environment
*
- * @param configurationContext
+ * @param configurationContext The configuration context
*/
void setConfigurationContext(ConfigurationContext configurationContext);
}
\ No newline at end of file
Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/context/ContextManager.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/context/ContextManager.java?rev=657297&r1=657296&r2=657297&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/context/ContextManager.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/clustering/context/ContextManager.java Fri May 16 23:31:43 2008
@@ -35,10 +35,12 @@
* </a> in this node, are propagated to all other nodes in the cluster.
* </p>
* <p>
- * It is not necessary to have a ContextManager in a node. If we are not interested in
+ * It is not mandatory to have a ContextManager in a node. If we are not interested in
* <a href="http://afkham.org/2008/05/definition-of-high-availability.html">
* High Availability</a>, we may disable context replication by commenting out the "contextManager"
- * section in the axis2.xml cluster configuration section.
+ * section in the axis2.xml cluster configuration section. In such a scenatio, the cluster will be
+ * used only for the purpose of
+ * <a href="http://afkham.org/2008/05/definition-of-scalability.html">Scalability</a>
* </p>
* <p>
* The implementation of this interface is set by the