In Apache Axis2 you can define a parameter in different locations. For example, you could define parameter in axis2.xml , services.xml or module.xml (three description files in Axis2). No matter where you define them, the basic requirement of defining parameters is to access them at runtime.
If you look at axis2.xml file you could find a number of parameters in it. One can define parameters in one of the description files as follows: <parameter name="Name of the parameter" locked="true of false"> value of the parameter (it can be just a string or a complex xml element) </parameter> name - name is a mandatory attribute in a parameter. Parameter name may or may not be unique across the system. This depends on the value of the locked attribute. locked - this attribute is an optional attribute in a parameter and if the attribute is not there, then the value of locked attribute is assumed to be false by default. Of course, value of the parameter could be a simple string or a complex xml element. Now let's look at the semantics of the locked attribute. The simple use of locked attribute is to prevent overriding parent parameters from its child descriptors (Here the parent and children relationship come from Axis2 description hierarchy ). As an example let's say a system administrator wants to set a parameter foo in axis2.xml and further assume that he does not want anyone else to override this parameter. This can be done by setting the locked attribute to "true" (of the corresponding parameter) in axis2.xml. In this case, If a module or service tries to override the parameter foo, it will not be allowed to do so. Applies To: Apache Axis2/Java all versions This KB Q & A Applies to ------------------------1. Project(s)/programming language/version(s)- Axis2 1.1 2. Environments and version(s) (eg: OS/JDK)- N/A 3. Tools and version(s) (eg. Maven/Ant etc )- N/A 4. Any other relevant information that this Q & A is dependent on This KB item qualifies to be an FAQ based on developer/user mailing list inquiries- Yes/No - No Author ------ Deepal Jayasinghe, Senior Software Engineer , WSO2 Inc., email@example.com