Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » EJB with Geronimo(Problems making remote calls to Geronimo)
EJB with Geronimo [message #1139342] Tue, 15 October 2013 18:06 Go to next message
Roland Welker is currently offline Roland WelkerFriend
Messages: 13
Registered: October 2013
Junior Member
Hi

I have tried to setup a RAP project, running directly out of my Workspace.

I am trying to access a Geronimo Server. I have done this before using RCP app and a open ejb client lib that required Buddy Loading to be set to work. However I can't get this to work in RAP.

The problem is that the Proxy Interface is not visible in the application's classloader:

java.lang.IllegalArgumentException: interface org.apache.openejb.client.EJBObjectProxy is not visible from class loader

Code:

Properties prop = new Properties();
prop.put(Context.INITIAL_CONTEXT_FACTORY, "org.apache.openejb.client.RemoteInitialContextFactory");
prop.put("java.naming.provider.url", "ejbd://localhost:4201");
prop.setProperty(Context.SECURITY_PRINCIPAL, "system");
prop.setProperty(Context.SECURITY_CREDENTIALS, "manager");
prop.setProperty("openejb.authentication.realmName", "geronimo-admin");

try {

InitialContext ServerContext = new InitialContext(prop);

ITestMe testme = (ITestMe) ServerContext.lookup("TestMeRemote");
.....

Any ideas how I get around this in in my RAP application?

Roland
Re: EJB with Geronimo [message #1140457 is a reply to message #1139342] Wed, 16 October 2013 11:17 Go to previous message
Roland Welker is currently offline Roland WelkerFriend
Messages: 13
Registered: October 2013
Junior Member
Hi,

Solved it. Here is what I have done ... for everyone who is looking for a similar solution.

I had used a seperate Plugin Project that was holding the remote interfaces (and was shared with the ejb project). I just added the following to the manifest:

Import-Package: javax.ejb,
javax.ejb.embeddable,
javax.ejb.spi,
org.apache.openejb.client,
org.apache.openejb.client.java,
org.apache.openejb.client.proxy,
org.openejb.client

which has solved the issue.

Roland
Previous Topic:Strange behavior of computeSize() methods
Next Topic:CTabItem background-color not themable?
Goto Forum:
  


Current Time: Sat Apr 20 02:00:50 GMT 2024

Powered by FUDForum. Page generated in 0.02893 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top