Hi.
Currently, I have the following code snippet in one of the classes:
I'd like to have Spring handle the lookup itself.Code:InitialContext initialCtx = new InitialContext(); EventFactory eventFactory = (EventFactory) javax.rmi.PortableRemoteObject.narrow(initialCtx .lookup("com/ibm/websphere/events/factory"), EventFactory.class);
So, I created the following Spring bean configuration:
and use IoC to inject into the code (using setters).Code:<bean id="eventFactory" class="org.springframework.ejb.access.SimpleRemoteStatelessSessionProxyFactoryBean"> <property name="jndiName"> <value>com/ibm/websphere/events/factory</value> </property> <property name="businessInterface"> <value>org.eclipse.hyades.logging.events.cbe.EventFactory</value> </property> </bean>
The thing is, that I get an exception:
Which led me to think it's a stateful bean.Code:EJB home [org.eclipse.hyades.logging.events.cbe.impl.EventFactoryImpl@be208f7] has no no-arg create() method
any idea why this code does not work, or how to access a remote stateful bean via spring proxy?
Thanks


Reply With Quote
.
