geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bongosdude <>
Subject How to Inject Datasource into session stateless bean?
Date Mon, 12 Jan 2009 03:08:56 GMT


I have created sucessfully a data pool name="jdbc/mydb" and below is my
stateless ejb

public class MySLSB implements ISessionLocal, ISessionRemote {

    private DataSource ds = null;

my slsb ejb tried to get a datasource and pass it to another bean which can
execute a stored procedure. however, when I try to deploy it from eclipse, I
got the following error:

Unable to resolve resource reference 'jdbc/mydb' (Could not auto-map to
resource.  Try adding a resource-ref mapping to your Geronimo deployment

1. I have tried all value for the name, including the global JNDI value but
all failed with the same error.
2. If I have to modify openejb-jar.xml, can someone give help on how to add
ref to datasource in the openejb-jar.xml



B Amigo:super:
View this message in context:
Sent from the Apache Geronimo - Users mailing list archive at

View raw message