Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[riena-dev] Interface not visible from class loader!

Hi,

I have 2 plugin in my project, 

the one is common plugin, it defines a Interface ITestService (the package is exported), and in the plugin's Activator.start(), I do this:

  RemoteServiceFactory rsf = new RemoteServiceFactory();
  Class<?> servIntf = ITestService.class;
  String url = "http://127.0.0.1:8080/dwserver/test/testService";;
  String protocol = "hessian";
  
  remoteServReg = rsf.createAndRegisterProxy(servIntf, url, protocol, context);

The second plugin, is the client application plugin, this plugin require the common plugin, when I try to get the service references by:

  BundleContext ctx = plugin.getBundle().getBundleContext();
  
  ServiceReference ref = ctx.getServiceReference(ITestService.class.getName());
  ...

eclipse try load the common plugin, and invoke the Actiator.start(), and then, an exception "Interface ....ITestService is not visible from class loader" was raised at rsf.createAndRegisterProxy(servIntf, url, protocol, context);

What's wrong?


Thanks,
Yau

Back to the top