Axis2 services can be deployed to a running Carbon instance as archive files, given that the required features are installed. See the section on developing and deploying services in AS for step-by-step instructions. Some of these Axis2 service archives may require additional libraries. As explained in the section on class loading for services, these external libraries can be applied to services at individual service level or they can be shared across multiple services.
With the Axis2 Repository Management Feature that is installed in WSO2 AS by default, you are able to directly upload the common libraries to the Axis2 Repository using the management console. You can also remove uploaded/shared libraries that are no longer necessary.
Follow the instructions below to upload shared libraries.
- Log in to the product's management console and click Carbon under Configure -> Repositories.
The Artifact Dependency Manager page opens. To upload shared libraries, click Add dependencies link next to the relevant lib directory icon.
This uploads libraries that can be used by Axis2 artifacts that are deployed under the Parent directory of that particular lib directory. For example, libraries uploaded to the lib directory of axis2services can also be shared by Axis2 artifacts deployed under axis2services directory.
The artifact upload page appears. Browse for the .jar file and click Upload as shown below.
If the file is uploaded successfully, a message will appear asking if you want to restart Axis2 Configuration now. Click Yes and similarly confirm the message that follows.
The Axis2 configuration is restarted and the following message is displayed. Click OK.
You can see the uploaded .jar file in the in the lib folder.