geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <david_jen...@yahoo.com>
Subject Re: using resource-ref in web.xml?
Date Wed, 08 Sep 2004 22:31:45 GMT
Don't know about the wiki but it ought to look like this (taken from an  
openejb example):

             <resource-ref>
                  
<ref-name>stateless/references/Resource_manager_access</ref-name>
                 <target-name>DefaultDatasource</target-name>
             </resource-ref>


BTW I fixed some major problems with jndi and servlet init last week.   
Does your ejb lookup work any better (without the ejb-link)?

thanks
david jencks

On Sep 8, 2004, at 5:28 PM, toby cabot wrote:

> Hi folks,
>
> It's great to see the increase in activity lately.
>
> I'm trying to use a resource adapter in a web application.  The
> adapter is home-grown but I expect that the technique would be similar
> for an off-the-shelf one.  Following the instructions on
> http://wiki.apache.org/geronimo/OpenJCA I've added to web.xml:
>
>     <resource-ref>
>         <res-ref-name>ra/CF</res-ref-name>
>         <res-type>g6o.ra.ConnectionFactory</res-type>
>         <res-auth>Application</res-auth>
>     </resource-ref>
>
> and to geronimo-jetty.xml:
>
>     <resource-ref>
>         <res-ref-name>ra/CF</res-ref-name>
>         <res-type>g6o.ra.ConnectionFactory</res-type>
>         <res-auth>Application</res-auth>
>          
> <jndi-name>geronimo.server: 
> J2EEServer=geronimo,j2eeType=JCAManagedConnectionFactory,name=testCF</ 
> jndi-name>
>     </resource-ref>
>
> I checked that the "jndi-name" value that I'm using is a valid mbean
> name by cutting and pasting into the "Filter Output" box of the debug
> console.  When I try to deploy I get a stack trace (included below).
> Is this something that's changed since the wiki page was written or am
> I just on the wrong track somehow?
>
> Thanks,
> Toby
>
> PS.  Stack trace:
>
> tcabot@mad:~/try/incubator-geronimo$ java -jar target/bin/deployer.jar  
> --install --module ../hello-g6o/build/g6o.ear
> org.apache.geronimo.deployment.DeploymentException: No geronimo  
> configuration for resource ref named: ra/CF
>         at  
> org.apache.geronimo.naming.deployment.ENCConfigBuilder.addResourceRefs( 
> ENCConfigBuilder.java:72)
>         at  
> org.apache.geronimo.naming.deployment.ENCConfigBuilder.buildComponentCo 
> ntext(ENCConfigBuilder.java:266)
>         at  
> org.apache.geronimo.jetty.deployment.JettyModuleBuilder.buildComponentC 
> ontext(JettyModuleBuilder.java:389)
>         at  
> org.apache.geronimo.jetty.deployment.JettyModuleBuilder.addGBeans(Jetty 
> ModuleBuilder.java:325)
>         at  
> org.apache.geronimo.jetty.deployment.JettyModuleBuilder$$FastClassByCGL 
> IB$$b30bba8a.invoke(<generated>)
>         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
>         at  
> org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoke 
> r.java:38)
>         at  
> org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOper 
> ation.java:142)
>         at  
> org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:744)
>         at  
> org.apache.geronimo.gbean.jmx.RawInvoker.invoke(RawInvoker.java:89)
>         at  
> org.apache.geronimo.gbean.jmx.RawOperationInvoker.invoke(RawOperationIn 
> voker.java:34)
>         at  
> org.apache.geronimo.gbean.jmx.CGLibMethodInterceptor.intercept(CGLibMet 
> hodInterceptor.java:112)
>         at  
> org.apache.geronimo.j2ee.deployment.ModuleBuilder$$EnhancerByCGLIB$$9e4 
> 5a280.addGBeans(<generated>)
>         at  
> org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration 
> (EARConfigBuilder.java:442)
>         at  
> org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration 
> (EARConfigBuilder.java:346)
>         at  
> org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration 
> (EARConfigBuilder.java:244)
>         at  
> org.apache.geronimo.j2ee.deployment.EARConfigBuilder$$FastClassByCGLIB$ 
> $38e56ec6.invoke(<generated>)
>         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
>         at  
> org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoke 
> r.java:38)
>         at  
> org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOper 
> ation.java:142)
>         at  
> org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:744)
>         at  
> org.apache.geronimo.gbean.jmx.RawInvoker.invoke(RawInvoker.java:89)
>         at  
> org.apache.geronimo.gbean.jmx.RawOperationInvoker.invoke(RawOperationIn 
> voker.java:34)
>         at  
> org.apache.geronimo.gbean.jmx.CGLibMethodInterceptor.intercept(CGLibMet 
> hodInterceptor.java:112)
>         at  
> org.apache.geronimo.deployment.ConfigurationBuilder$$EnhancerByCGLIB$$7 
> a1ca0ae.buildConfiguration(<generated>)
>         at  
> org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:198)
>         at  
> org.apache.geronimo.deployment.Deployer$$FastClassByCGLIB$$734a235d.inv 
> oke(<generated>)
>         at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
>         at  
> org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoke 
> r.java:38)
>         at  
> org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOper 
> ation.java:142)
>         at  
> org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:767)
>         at  
> mx4j.server.interceptor.InvokerMBeanServerInterceptor.invoke(InvokerMBe 
> anServerInterceptor.java:218)
>         at  
> mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBe 
> anServerInterceptor.java:121)
>         at  
> mx4j.server.interceptor.SecurityMBeanServerInterceptor.invoke(SecurityM 
> BeanServerInterceptor.java:86)
>         at  
> mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBe 
> anServerInterceptor.java:121)
>         at  
> mx4j.server.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBe 
> anServerInterceptor.java:121)
>         at  
> mx4j.server.interceptor.ContextClassLoaderMBeanServerInterceptor.invoke 
> (ContextClassLoaderMBeanServerInterceptor.java:205)
>         at  
> mx4j.server.MX4JMBeanServer.invoke(MX4JMBeanServer.java:1079)
>         at org.apache.geronimo.kernel.Kernel.invoke(Kernel.java:231)
>         at  
> org.apache.geronimo.system.main.CommandLine.main(CommandLine.java:93)
>


Mime
View raw message