-
1. Re: In the init() mothod couldn't lookup datasource,thank u
genman Oct 26, 2005 2:31 AM (in response to zhjjava)You may need to add a jboss-web.xml with a
<depends>
in it so that the data source gets deployed before your web app does. -
2. Re: In the init() mothod couldn't lookup datasource,thank u
zhjjava Nov 8, 2005 10:22 PM (in response to zhjjava)hahaha,I have solved the problem.
thank u,genman,but u didn't give me some valuable message.
We maybe should offer the answer if we knew,so that it can save many people's time!
I need thank the jboss-wiki,
http://wiki.jboss.org/wiki/Wiki.jsp?page=DependOnDataSource.
That gives me the inspiration!
Thus in your admin-doc,JBoss Admin Development Guide(jboss3.2.6), Figure 3.4,didn't offer the depends element.
I can find some info in ...docs/dtd/jboss-web_3_2.dtd.
but when I wrote this message, I found the Figure 9.1----"The complete jboss-web.xml descriptor DTD", ah... ah... ah....
Reference http://wiki.jboss.org/wiki/Wiki.jsp?page=DependOnDataSource.
I modified ...sar/...war/WEB-INF/jboss-web.xml,then run jboss,I have looked up the datasource!!!
<jboss-web> jboss.jca:service=LocalTxCM,name=jdbc/test
</jboss-web>
In the log,I can find these info:
2005-11-08 19:12:49,859 DEBUG [org.jboss.system.ServiceController] waiting in start jboss.web.deployment:war=Crm.war,id=843359960 on jboss.jca:service=LocalTxCM,name=jdbc/test
...........
2005-11-08 19:12:51,046 DEBUG [org.jboss.system.ServiceController] Starting dependent components for: jboss.jca:service=LocalTxCM,name=jdbc/test dependent components: [ObjectName: jboss.web.deployment:war=Crm.war,id=843359960
state: CREATED
I Depend On: jboss.jca:service=LocalTxCM,name=jdbc/test
Depends On Me: ]
2005-11-08 19:12:51,046 DEBUG [org.jboss.system.ServiceController] starting service jboss.web.deployment:war=Crm.war,id=843359960
In more detail,I will offer later on. Thank u jboss.Inc!!! -
3. Re: In the init() mothod couldn't lookup datasource,thank u
zhjjava Nov 8, 2005 10:28 PM (in response to zhjjava)sorry!
<jboss-web>
jboss.jca:service=LocalTxCM,name=jdbc/test
</jboss-web>
should be ,maybe use (code /code),:0)<jboss-web> <depends>jboss.jca:service=LocalTxCM,name=jdbc/test</depends> </jboss-web>
-
4. Re: In the init() mothod couldn't lookup datasource,thank u
adrian.brock Nov 9, 2005 8:24 AM (in response to zhjjava)"zhjjava" wrote:
thank u,genman,but u didn't give me some valuable message.
Yes, he did, he just doesn't know how to use bbcode (I fixed it for him) -
5. Re: In the init() mothod couldn't lookup datasource,thank u
zhjjava Nov 10, 2005 11:47 PM (in response to zhjjava)hahaha,thank u very much,
Although your info is a little later.
Good luck! all friends! -
6. More better answer message.
zhjjava Nov 11, 2005 12:54 AM (in response to zhjjava)More better answer message
my blog: http://spaces.msn.com/members/zhj-michael/
my msn:zhj_michael@hotmail.com
English answer version:
http://spaces.msn.com/members/zhj-michael/Blog/cns!1pygmarxwX748Rh107mOyeGQ!180.entry
Chinese answer version:
http://spaces.msn.com/members/zhj-michael/Blog/cns!1pygmarxwX748Rh107mOyeGQ!181.entry
or u can refer to
http://www.javaworld.com.tw/jute/post/view?bid=9&id=129747&sty=1&tpg=1&age=0
There,u can find Chinese and English version.