geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <david_jen...@yahoo.com>
Subject Re: Usign Databasepool inside of an EAR Application
Date Tue, 17 Apr 2007 15:32:46 GMT
The resource-ref element you show should go in geronimo-web.xml, not  
geronimo-application.xml.  I'm not sure why geronimo isn't  
complaining about where you put it.

I'd recommend naming your datasource "documentDataSource" in which  
case you should be able to leave out the resource-ref element from  
the geronimo plan.

thanks
david jencks

On Apr 17, 2007, at 2:05 AM, Jochen Zink wrote:

> Hello at all,
>
> I have (maybe a simple) problem.
>
> I want to deploy an EAR Archive to geronimo 1.1.1. Inside this ear  
> is only one module and one global JAR Archive.
>
> ear:
>  |--WebApplication.war
>          |--META-INF
>                |--MANIFEST.MF
>          |--WEB-INF
>                 |--web.xml
>                 |--geronimo-web.xml
> |--lib
>     |--DatabaseAccess.jar
> |--application.xml
> |--geronimo-application.xml
>
>
>
> The WebApplication uses the DatabaseAccess.jar to connect to a  
> ServiceWide ConnectionPool. This works, if I deploy the  
> WebApplication.war as a standalone WAR. In this case, the  
> DatabaseAccess.jar is placed inside the WebApplication.war.
>
> But if I excluded the jar and pack everything together in a EAR  
> archive, it dosen't work.
>
> The Message is: "Unable to resolve resource reference  
> 'documentDataSource' (Could not find resource 'MySQLComServerPool'.  
> Perhaps it has not yet been configured, or your application does  
> not have a dependency declared for that resource module?) "
>
>
> I don't find a solution for this problem. In which deployment  
> files, I have to declare the dependency to the ConnectionPool?
>
> The web.xml and geronimo-web.xml contains the correct declarations.  
> This works standalone!
>
> I try to add the dependency to geronimo-application.xml (you can  
> see it, on the end of my mail), but it does not work.
>
> So, I don't no where the miss configuration is.
>
> Thanks for help!
>
> geronimo-application.xml
>
> <application
>     .. namespaceStuff...>
> 	
>     <sys:environment>
>         <sys:moduleId>
>             <sys:groupId>edocbox</sys:groupId>
>             <sys:artifactId>comserver</sys:artifactId>
>             <sys:version>1.0</sys:version>
>         </sys:moduleId>		
> 		
>         <sys:dependencies>
>             <sys:dependency>
>                 <sys:groupId>console.dbpool</sys:groupId>
>                 <sys:artifactId>MySQLComServerPool</sys:artifactId>
>             </sys:dependency>
>         </sys:dependencies>
>     </sys:environment>
>
>
>     <resource-ref>
>          <ref-name>documentDataSource</ref-name>
>         <pattern>
>             <groupId>console.dbpool</groupId>
>             <artifactId>MySQLComServerPool</artifactId>
>             <name>MySQLComServerPool</name>
>         </pattern>
>     </resource-ref>
>
>     <module>
> 	
>         <web>DocumentTransferService.war</web>
>     </module>
> </application>
>
>
>
>
> _______________________________________________________________
> SMS schreiben mit WEB.DE FreeMail - einfach, schnell und
> kostenguenstig. Jetzt gleich testen! http://f.web.de/?mc=021192
>


Mime
View raw message