Hi Brecht, Can you please try using : ConfigurationContext configContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem(repository,axis2xml);
Instead of :
String axis2xml = "com/invenso/xb/isp/xbconnect/wscall/axis2.xml"; String repository = "com/invenso/xb/isp/xbconnect/wscall/"; URL configFileUrl = ClassLoader.getSystemClassLoader().getResource(axis2xml); URL repositoryUrl = ClassLoader.getSystemClassLoader().getResource(repository); URLBasedAxisConfigurator configurator = new URLBasedAxisConfigurator(configFileUrl, repositoryUrl); ConfigurationContext cc = ConfigurationContextFactory.createConfigurationContext(configurator);
Thanks, Ruchith On 8/7/06, Brecht Yperman <[EMAIL PROTECTED]> wrote:
Hi, I use the following bit of code to call a webservice. I am now trying to engage the rampart module. String axis2xml = "com/invenso/xb/isp/xbconnect/wscall/axis2.xml"; String repository = "com/invenso/xb/isp/xbconnect/wscall/"; URL configFileUrl = ClassLoader.getSystemClassLoader().getResource(axis2xml); URL repositoryUrl = ClassLoader.getSystemClassLoader().getResource(repository); URLBasedAxisConfigurator configurator = new URLBasedAxisConfigurator(configFileUrl, repositoryUrl); ConfigurationContext cc = ConfigurationContextFactory.createConfigurationContext(configurator); Definition serviceDefinition = getWsdlDefinition(wsdl); ServiceClient client = new ServiceClient(cc, serviceDefinition, serviceName, port); client.getOptions().setProperty(MessageContextConstants.CHUNKED, new Boolean(true)); The call to ConfigurationContextFactory throws an exception: getBundle(org.apache.axis2,org.apache.axis2.i18n,resource,null,...) loadBundle: Ignoring MissingResourceException: Can't find bundle for base name org.apache.axis2.resource, locale en_US Created org.apache.axis2.i18n.resource, linked to parent null getBundle(org.apache.axis2,org.apache.axis2.i18n,resource,null,...) org.apache.axis2.i18n.resource::handleGetObject(addingnewmodule) adding new module [ERROR] Something went wrong java.lang.NullPointerException at org.apache.axis2.deployment.DeploymentEngine.loadServices(DeploymentEngine.java:91) at org.apache.axis2.deployment.URLBasedAxisConfigurator.loadServices(URLBasedAxisConfigurator.java:102) at org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:42) at com.invenso.xb.isp.xbconnect.wscall.WebserviceCallWorker.run(WebserviceCallWorker.java:113) [...] at java.lang.Thread.run(Unknown Source) repoListener is null, because it is only initialized in loadRepository(String repoDir), not in loadRepostoryFromURL, which is used when using the URLBasedAxisConfigurator. The repository directory contains one directory, modules, containing a file modules.list (with in that file only "rampart-1.0.mar") and a file rampart-1.0.mar. My axis2.xml file contains the following bit: <axisconfig name="AxisJava2.0"> <module ref="rampart-1.0" /> I guess this is a bug, but I can't find a way around it... Any help is very much appreciated, Thanks, Brecht Invenso - The "Integration Software" specialists. _____________________________________________ Brecht Yperman Development team Direct: +32 (0)3 780 30 05 Email: [EMAIL PROTECTED] INVENSO bvba Industriepark-West 75 9100 Sint-Niklaas Belgium - Europe Phone: +32 (0)3 780 30 02 Fax: +32 (0)3 780 30 03 Email: [EMAIL PROTECTED] Website: www.invenso.com "E-mail disclaimer: This e-mail, and any attachments thereto, is intended only for use by the addressee(s) named herein and may contain legally privileged and/or confidential information. If you are not the intended recipient, please note that any review, dissemination, disclosure, alteration, printing, copying or transmission of this e-mail and/or any file transmitted with it, is strictly prohibited and may be unlawful. If you have received this e-mail by mistake, please immediately notify the sender and permanently delete the original as well as any copy of any e-mail and any printout thereof."
-- www.ruchith.org --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]