Monday, November 24, 2008

How to deploy specified web services in a remote repository

While working in my project MOINC ( http://www.moinc.org ).  I had two specified requirements 
  • work in a remote repository
  • deploy only specified web services from that repository
in my project MOINC Agent the remote repository i used was a common repository which is used by many computers. Therefore my second requirement of deploying specified services cannot be handled by editing the services.list file since its a common file for all computers.
The selution i came up with is hacking axis2 source code where i changed the services.list file to a local directory.
To do this i had to change module kernel package deployment and class deployment engine
the method loadServicesFromUrl

old code
URL servicesDir = new URL(repoURL, path);
URL filelisturl = new URL(servicesDir ,"services.list");

new code
URL servicesDir = new URL(repoURL, path);
URL filelisturl = new URL("http://localhost:port/services.list");

so now i will keep the services.list file in the localhost root directory where i specify the services required to be deployed.

No comments:

Google