当前位置: 技术问答>java相关
测试BMP EJB时客户端出现以下错误
来源: 互联网 发布时间:2015-02-23
本文导语: 程序是用jb与wl6.1自动生成的BMP bean.在客户端测试时出现如下错误: java.rmi.RemoteException: Error during setXXXContext: ; nested exception is: javax.ejb.EJBException: Error initializing context:javax.ejb.EJBException: Error looking up dataSour...
程序是用jb与wl6.1自动生成的BMP bean.在客户端测试时出现如下错误:
java.rmi.RemoteException: Error during setXXXContext: ; nested exception is:
javax.ejb.EJBException: Error initializing context:javax.ejb.EJBException: Error looking up dataSource: javax.naming.LinkException: [Root exception is javax.naming.NameNotFoundException: Unable to resolve DataSource. Resolved: '' Unresolved:'DataSource' ; remaining name '']; Link Remaining Name: 'DataSource'
javax.ejb.EJBException: Error initializing context:javax.ejb.EJBException: Error looking up dataSource: javax.naming.LinkException: [Root exception is javax.naming.NameNotFoundException: Unable to resolve DataSource. Resolved: '' Unresolved:'DataSource' ; remaining name '']; Link Remaining Name: 'DataSource'
bean能布署到wl上面,并且cnsole上面能够Monitor 这个bean.
在客户端测试时,如果执行 acount3 = acoun3tHome.findByPrimaryKey( acount3PK ) ;
就会出现以上错误,而去掉该句就能够正确执行。提示信息是不能寻找DataSource???
各位出现过这个错误吗?肯定大家帮我解决,一定送分!
java.rmi.RemoteException: Error during setXXXContext: ; nested exception is:
javax.ejb.EJBException: Error initializing context:javax.ejb.EJBException: Error looking up dataSource: javax.naming.LinkException: [Root exception is javax.naming.NameNotFoundException: Unable to resolve DataSource. Resolved: '' Unresolved:'DataSource' ; remaining name '']; Link Remaining Name: 'DataSource'
javax.ejb.EJBException: Error initializing context:javax.ejb.EJBException: Error looking up dataSource: javax.naming.LinkException: [Root exception is javax.naming.NameNotFoundException: Unable to resolve DataSource. Resolved: '' Unresolved:'DataSource' ; remaining name '']; Link Remaining Name: 'DataSource'
bean能布署到wl上面,并且cnsole上面能够Monitor 这个bean.
在客户端测试时,如果执行 acount3 = acoun3tHome.findByPrimaryKey( acount3PK ) ;
就会出现以上错误,而去掉该句就能够正确执行。提示信息是不能寻找DataSource???
各位出现过这个错误吗?肯定大家帮我解决,一定送分!
|
很好。
|
送分吧