Ejb-ref in the deployment descriptor

Could someone help me on how to configure an ejb-reference in the 3 xml
files.
ejb-jar.xml, weblogic-ejb-jar.xml and web.xml
These are the entries for my application, but I get some exception. Can
somebody help me pls?
ejb-jar.xml
<enterprise-beans>
<session id="Abcd">
<small-icon></small-icon>
<ejb-name>ABCD</ejb-name>
<home>AbcdHome</home>
<remote>AbcdRemote</remote>
<ejb-class>AbcdBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
</enterprise-beans>
web.xml contains the foll,
<ejb-ref>
<ejb-ref-name>ejb/abcd</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>AbcdHome</home>
<remote>AbcdRemote</remote>
<ejb-link>ABCD</ejb-link>
</ejb-ref>
weblogic.ejb-jar.xml contains,
<weblogic-enterprise-bean>
<ejb-name>ABCD</ejb-name>
<caching-descriptor>
<max-beans-in-free-pool>100</max-beans-in-free-pool>
</caching-descriptor>
<reference-descriptor>
<ejb-reference-description>
<ejb-ref-name>ejb/abcd</ejb-ref-name>
<jndi-name>ejb/ABCD</jndi-name>
</ejb-reference-description>
</reference-descriptor>
</weblogic-enterprise-bean>
But when i run the application, I get the foll exception,
In EJB RemotePlatform, a session or entity bean that has a remote home m
ust be given a JNDI name in the weblogic-ejb-jar.xml descriptor file.
at weblogic.ejb20.compliance.EJBComplianceChecker.check(EJBComplianceChe
cker.java:256)
at weblogic.ejb20.compliance.EJBComplianceChecker.checkDeploymentInfo(EJ
BComplianceChecker.java:220)
at weblogic.ejb20.ejbc.EJBCompiler.complianceCheckJar(EJBCompiler.java:4
52)
at weblogic.ejb20.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:409)
at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:202)
at weblogic.ejb20.deployer.Deployer.runEJBC(Deployer.java:296)
at weblogic.ejb20.deployer.Deployer.compileEJB(Deployer.java:676)
at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:843)
at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:30)
at weblogic.j2ee.Application.addComponent(Application.java:160)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:329)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Dep
loymentTarget.java:279)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeploy
ments(DeploymentTarget.java:233)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(
DeploymentTarget.java:193)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy34.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeplo
yments(ServerMBean_CachingStub.java:2706)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManag
er(ApplicationManager.java:360)
at weblogic.management.mbeans.custom.ApplicationManager.start(Applicatio
nManager.java:152)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy48.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub
.start(ApplicationManagerMBean_CachingStub.java:479)
at weblogic.management.Admin.startApplicationManager(Admin.java:1138)
at weblogic.management.Admin.finish(Admin.java:561)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:501)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:198)
at weblogic.Server.main(Server.java:35)
>
<Jan 31, 2002 3:56:18 PM PST> <Error> <J2EE> <Error deploying application
Defaul
tVoiceApp: Could not load DefaultVoiceApp>
java.lang.reflect.UndeclaredThrowableException:
weblogic.xml.dom.DOMProcessingEx
ception: Could not setup environment for EJBReference or ResourceReference.
Can
not find WEB-INF/weblogic.xml in the Web application.
at weblogic.servlet.internal.WebAppServletContext.initFromDescriptors(We
bAppServletContext.java:1509)
at weblogic.servlet.internal.WebAppServletContext.init(WebAppServletCont
ext.java:871)
at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletCo
ntext.java:806)
at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:413)
at weblogic.j2ee.WebAppComponent.deploy(WebAppComponent.java:74)
at weblogic.j2ee.Application.addComponent(Application.java:160)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:329)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:144)
at weblogic.management.mbeans.custom.WebServer.addWebDeployment(WebServe
r.java:76)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy35.addWebDeployment(Unknown Source)
at weblogic.management.configuration.WebServerMBean_CachingStub.addWebDe
ployment(WebServerMBean_CachingStub.java:1093)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:315)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Dep
loymentTarget.java:279)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeploy
ments(DeploymentTarget.java:233)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(
DeploymentTarget.java:193)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy34.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeplo
yments(ServerMBean_CachingStub.java:2706)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManag
er(ApplicationManager.java:360)
at weblogic.management.mbeans.custom.ApplicationManager.start(Applicatio
nManager.java:152)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy48.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub
.start(ApplicationManagerMBean_CachingStub.java:479)
at weblogic.management.Admin.startApplicationManager(Admin.java:1138)
at weblogic.management.Admin.finish(Admin.java:561)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:501)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:198)
at weblogic.Server.main(Server.java:35)
--------------- nested within: ------------------
weblogic.j2ee.DeploymentException: Could not load DefaultVoiceApp - with
nested
exception:
[weblogic.xml.dom.DOMProcessingException: Could not setup environment for
EJBRef
erence or ResourceReference. Cannot find WEB-INF/weblogic.xml in the Web
applic
ation.]
at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:416)
at weblogic.j2ee.WebAppComponent.deploy(WebAppComponent.java:74)
at weblogic.j2ee.Application.addComponent(Application.java:160)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:329)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:144)
at weblogic.management.mbeans.custom.WebServer.addWebDeployment(WebServe
r.java:76)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy35.addWebDeployment(Unknown Source)
at weblogic.management.configuration.WebServerMBean_CachingStub.addWebDe
ployment(WebServerMBean_CachingStub.java:1093)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:315)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Dep
loymentTarget.java:279)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeploy
ments(DeploymentTarget.java:233)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(
DeploymentTarget.java:193)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy34.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeplo
yments(ServerMBean_CachingStub.java:2706)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManag
er(ApplicationManager.java:360)
at weblogic.management.mbeans.custom.ApplicationManager.start(Applicatio
nManager.java:152)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy48.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub
.start(ApplicationManagerMBean_CachingStub.java:479)
at weblogic.management.Admin.startApplicationManager(Admin.java:1138)
at weblogic.management.Admin.finish(Admin.java:561)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:501)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:198)
at weblogic.Server.main(Server.java:35)
Can someone help me on what to set in sequence please. Any help would highly
be appreciated.
Thanks in advance.
Regards
Aru

Aaru,
Verify the document structure @
http://e-docs.bea.com/wls/docs61/ejb/reference.html#1026457
jndi-name is of the ejb is missing in your WEJ.xml
and the jndi-name defined under
<reference-descriptor><ejb-reference-description>
</reference-descriptor></ejb-reference-description>
is the reference jndi-name(referenced by this bean)
For more info refere
the weblogic 6.x dtd
http://www.bea.com/servers/wls600/dtd/weblogic-ejb-jar.dtd
Venki..
Aru wrote:
As per the doc that you referred, the doc too says that the jndi-name should
be within the ejb-reference-description which in turn is inside the
reference-descriptor. I don't get what you tried to say. Am I missing
anything? Could you please make sure that for me.
Just with curiosity I even tried your suggestion but it gives me the
exception as expected,
The XML parser encountered an error in your deployment descriptor. Please
ensure
that your deployment descriptor corresponds to the format in the DTD. The
error
was:
org.xml.sax.SAXParseException: The content of element type
"ejb-reference-descr
iption" is incomplete, it must match "(ejb-ref-name,jndi-name)".
"Venki Seshaadri" <[email protected]> wrote in message
news:[email protected]...
Aaru,
<jndi-name> should be outside <reference-descriptor>
refer to http://e-docs.bea.com/wls/docs61/ejb/reference.html#1026457
<weblogic-enterprise-bean>
<reference-descriptor>...</reference-descriptor>
<jndi-name>ejb/ABCD</jndi-name>
</weblogic-enterprise-bean>
Hope this helps,
Venki
[email protected]
Aru wrote:
FYI, I am using Weblogic 6.1
"Aru" <[email protected]> wrote in message
news:[email protected]...
Could someone help me on how to configure an ejb-reference in the 3 xml
files.
ejb-jar.xml, weblogic-ejb-jar.xml and web.xml
These are the entries for my application, but I get some exception. Can
somebody help me pls?
ejb-jar.xml
<enterprise-beans>
<session id="Abcd">
<small-icon></small-icon>
<ejb-name>ABCD</ejb-name>
<home>AbcdHome</home>
<remote>AbcdRemote</remote>
<ejb-class>AbcdBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
</enterprise-beans>
web.xml contains the foll,
<ejb-ref>
<ejb-ref-name>ejb/abcd</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>AbcdHome</home>
<remote>AbcdRemote</remote>
<ejb-link>ABCD</ejb-link>
</ejb-ref>
weblogic.ejb-jar.xml contains,
<weblogic-enterprise-bean>
<ejb-name>ABCD</ejb-name>
<caching-descriptor>
<max-beans-in-free-pool>100</max-beans-in-free-pool>
</caching-descriptor>
<reference-descriptor>
<ejb-reference-description>
<ejb-ref-name>ejb/abcd</ejb-ref-name>
<jndi-name>ejb/ABCD</jndi-name>
</ejb-reference-description>
</reference-descriptor>
</weblogic-enterprise-bean>
But when i run the application, I get the foll exception,
In EJB RemotePlatform, a session or entity bean that has a remote home m
ust be given a JNDI name in the weblogic-ejb-jar.xml descriptor file.
at weblogic.ejb20.compliance.EJBComplianceChecker.check(EJBComplianceChe
cker.java:256)
at weblogic.ejb20.compliance.EJBComplianceChecker.checkDeploymentInfo(EJ
BComplianceChecker.java:220)
at weblogic.ejb20.ejbc.EJBCompiler.complianceCheckJar(EJBCompiler.java:4
52)
at weblogic.ejb20.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:409)
at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:202)
at weblogic.ejb20.deployer.Deployer.runEJBC(Deployer.java:296)
at weblogic.ejb20.deployer.Deployer.compileEJB(Deployer.java:676)
at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:843)
at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:30)
at weblogic.j2ee.Application.addComponent(Application.java:160)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:329)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Dep
loymentTarget.java:279)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeploy
ments(DeploymentTarget.java:233)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(
DeploymentTarget.java:193)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy34.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeplo
yments(ServerMBean_CachingStub.java:2706)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManag
er(ApplicationManager.java:360)
at weblogic.management.mbeans.custom.ApplicationManager.start(Applicatio
nManager.java:152)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy48.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub
.start(ApplicationManagerMBean_CachingStub.java:479)
at weblogic.management.Admin.startApplicationManager(Admin.java:1138)
at weblogic.management.Admin.finish(Admin.java:561)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:501)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:198)
at weblogic.Server.main(Server.java:35)
<Jan 31, 2002 3:56:18 PM PST> <Error> <J2EE> <Error deploying
application
Defaul
tVoiceApp: Could not load DefaultVoiceApp>
java.lang.reflect.UndeclaredThrowableException:
weblogic.xml.dom.DOMProcessingEx
ception: Could not setup environment for EJBReference or
ResourceReference.
Can
not find WEB-INF/weblogic.xml in the Web application.
at weblogic.servlet.internal.WebAppServletContext.initFromDescriptors(We
bAppServletContext.java:1509)
at weblogic.servlet.internal.WebAppServletContext.init(WebAppServletCont
ext.java:871)
at weblogic.servlet.internal.WebAppServletContext.<init>(WebAppServletCo
ntext.java:806)
at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:413)
at weblogic.j2ee.WebAppComponent.deploy(WebAppComponent.java:74)
at weblogic.j2ee.Application.addComponent(Application.java:160)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:329)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:144)
at weblogic.management.mbeans.custom.WebServer.addWebDeployment(WebServe
r.java:76)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy35.addWebDeployment(Unknown Source)
at weblogic.management.configuration.WebServerMBean_CachingStub.addWebDe
ployment(WebServerMBean_CachingStub.java:1093)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:315)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Dep
loymentTarget.java:279)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeploy
ments(DeploymentTarget.java:233)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(
DeploymentTarget.java:193)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy34.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeplo
yments(ServerMBean_CachingStub.java:2706)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManag
er(ApplicationManager.java:360)
at weblogic.management.mbeans.custom.ApplicationManager.start(Applicatio
nManager.java:152)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy48.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub
.start(ApplicationManagerMBean_CachingStub.java:479)
at weblogic.management.Admin.startApplicationManager(Admin.java:1138)
at weblogic.management.Admin.finish(Admin.java:561)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:501)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:198)
at weblogic.Server.main(Server.java:35)
--------------- nested within: ------------------
weblogic.j2ee.DeploymentException: Could not load DefaultVoiceApp - with
nested
exception:
[weblogic.xml.dom.DOMProcessingException: Could not setup environment
for> >>>>EJBRef>>>>erence or ResourceReference. Cannot find WEB-INF/weblogic.xml in the Web>>>>applic>>>>ation.
at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:416)
at weblogic.j2ee.WebAppComponent.deploy(WebAppComponent.java:74)
at weblogic.j2ee.Application.addComponent(Application.java:160)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:117)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:329)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:144)
at weblogic.management.mbeans.custom.WebServer.addWebDeployment(WebServe
r.java:76)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy35.addWebDeployment(Unknown Source)
at weblogic.management.configuration.WebServerMBean_CachingStub.addWebDe
ployment(WebServerMBean_CachingStub.java:1093)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(Depl
oymentTarget.java:315)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(Dep
loymentTarget.java:279)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeploy
ments(DeploymentTarget.java:233)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(
DeploymentTarget.java:193)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy34.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeplo
yments(ServerMBean_CachingStub.java:2706)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManag
er(ApplicationManager.java:360)
at weblogic.management.mbeans.custom.ApplicationManager.start(Applicatio
nManager.java:152)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMB
eanImpl.java:606)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl
.java:590)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(Configurat
ionMBeanImpl.java:350)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
55)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:15
23)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:444)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:185)
at $Proxy48.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub
.start(ApplicationManagerMBean_CachingStub.java:479)
at weblogic.management.Admin.startApplicationManager(Admin.java:1138)
at weblogic.management.Admin.finish(Admin.java:561)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:501)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:198)
at weblogic.Server.main(Server.java:35)
Can someone help me on what to set in sequence please. Any help would
highly
be appreciated.
Thanks in advance.
Regards
Aru

Similar Messages

  • Ejb accessing the deployment descriptor

    My ejb needs to be able to access the deployment descriptor to retrieve some user information needed to connect to a web service. What is the best way to do this? I know servletts can do this, and if necessary, I could have my servlet retrieve the info and pass it to the bean, but I was hoping to avoid this.
    Thanks
    Matt

    Well, sure I think that is easy. In your <entity> or <session> deployment descriptor you can have:
    <env-entry>
    <env-entry-name>WebServiceLogins</env-entry-name>
    <env-entry-type>java.lang.String</env-entry-type>
    <env-entry-value>su, dan, bob, steve, richard, suzie, carla</env-entry-value>
    </env-entry>
    <env-entry>
    <env-entry-name>WebServicePasswords</env-entry-name>
    <env-entry-type>java.lang.String</env-entry-type>
    <env-entry-value>drs100, vfdds2, ajk14, pass411, richard23, q4lty, uo738ww1</env-entry-value>
    </env-entry>
    Then in your intial-context in your session or entity ejb.....
    InitialContext ic = new InitialContext();
    String logins = (String) ic.lookup("java:comp/env/WebServiceLogins");
    String passwords = (String) ic.lookup("java:comp/env/WebServicePasswords");

  • Ejb-ref error when deploying a previously working ear on weblogic 8.1

    when deploying an ear module on weblogic 8.1 i get the following error:
    The ejb-link 'CustomessagingBrick.jar/CustomMessaginBrick' declared in ejb-ref
    or ejb-local-ref 'ejb/Service2' in the application module 'cmbrick.war' could
    not be resolved. The target EJB for the ejb ref could not be found.
    The ear is composed of two sub-modules:
    CustomMessaginBrick.jar
    cmbrick.war.
    The same ear was deployed on weblogic 6.1.
    Every reference in the ear seems in the right place so i am really clueless.
    Hereafter i include the relevant portions of the deployment descriptors.
    the web.xml for cmbrick.war contains the following data:
    <ejb-local-ref>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local-home>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocalHome</local-home>
    <local>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocal</local>
    <ejb-link>CustomMessagingBrick</ejb-link>
    </ejb-local-ref>
    its weblogic.xml file is the following:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN"
    "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
    <weblogic-web-app>
    <reference-descriptor>
    <ejb-reference-description>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <jndi-name>Service2</jndi-name>
    </ejb-reference-description>
    </reference-descriptor>
    </weblogic-web-app>
    while the weblogic-ejb-jar for CustomMessaging bricks contains the following:
    <weblogic-enterprise-bean>
    <ejb-name>CustomMessagingBrick</ejb-name>
    <stateless-session-descriptor>
    <pool>
    </pool>
    <stateless-clustering>
    </stateless-clustering>
    </stateless-session-descriptor>
    <transaction-descriptor>
    </transaction-descriptor>
    <enable-call-by-reference>True</enable-call-by-reference>
    <jndi-name>Service2</jndi-name>
    </weblogic-enterprise-bean>....

    when deploying an ear module on weblogic 8.1 i get the following error:
    The ejb-link 'CustomessagingBrick.jar/CustomMessaginBrick' declared in ejb-ref
    or ejb-local-ref 'ejb/Service2' in the application module 'cmbrick.war' could
    not be resolved. The target EJB for the ejb ref could not be found.
    The ear is composed of two sub-modules:
    CustomMessaginBrick.jar
    cmbrick.war.
    The same ear was deployed on weblogic 6.1.
    Every reference in the ear seems in the right place so i am really clueless.
    Hereafter i include the relevant portions of the deployment descriptors.
    the web.xml for cmbrick.war contains the following data:
    <ejb-local-ref>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local-home>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocalHome</local-home>
    <local>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocal</local>
    <ejb-link>CustomMessagingBrick</ejb-link>
    </ejb-local-ref>
    its weblogic.xml file is the following:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN"
    "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
    <weblogic-web-app>
    <reference-descriptor>
    <ejb-reference-description>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <jndi-name>Service2</jndi-name>
    </ejb-reference-description>
    </reference-descriptor>
    </weblogic-web-app>
    while the weblogic-ejb-jar for CustomMessaging bricks contains the following:
    <weblogic-enterprise-bean>
    <ejb-name>CustomMessagingBrick</ejb-name>
    <stateless-session-descriptor>
    <pool>
    </pool>
    <stateless-clustering>
    </stateless-clustering>
    </stateless-session-descriptor>
    <transaction-descriptor>
    </transaction-descriptor>
    <enable-call-by-reference>True</enable-call-by-reference>
    <jndi-name>Service2</jndi-name>
    </weblogic-enterprise-bean>....

  • Ejb-ref errore when deploying a previously working ear on weblogic 8.1

    when deploying an ear module on weblogic 8.1 i get the following error:
    The ejb-link 'CustomessagingBrick.jar/CustomMessaginBrick' declared in ejb-ref
    or ejb-local-ref 'ejb/Service2' in the application module 'cmbrick.war' could
    not be resolved. The target EJB for the ejb ref could not be found.
    The ear is composed of two sub-modules:
    CustomMessaginBrick.jar
    cmbrick.war.
    The same ear was deployed on weblogic 6.1.
    Every reference in the ear seems in the right place so i am really clueless.
    Hereafter i include the relevant portions of the deployment descriptors.
    Thanks in advance!
    Greets,
    Luca
    the web.xml for cmbrick.war contains the following data:
    <ejb-local-ref>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local-home>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocalHome</local-home>
    <local>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocal</local>
    <ejb-link>CustomMessagingBrick</ejb-link>
    </ejb-local-ref>
    its weblogic.xml file is the following:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN"
    "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
    <weblogic-web-app>
    <reference-descriptor>
    <ejb-reference-description>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <jndi-name>Service2</jndi-name>
    </ejb-reference-description>
    </reference-descriptor>
    </weblogic-web-app>
    while the weblogic-ejb-jar for CustomMessaging bricks contains the following:
    <weblogic-enterprise-bean>
    <ejb-name>CustomMessagingBrick</ejb-name>
    <stateless-session-descriptor>
    <pool>
    </pool>
    <stateless-clustering>
    </stateless-clustering>
    </stateless-session-descriptor>
    <transaction-descriptor>
    </transaction-descriptor>
    <enable-call-by-reference>True</enable-call-by-reference>
    <jndi-name>Service2</jndi-name>
    </weblogic-enterprise-bean>....

    The issue is that WLS 6.1 didn't really support ejb-links properly. An
    ejb-link should allow you to link a webapp or an ejb to another EJB
    without requiring additional information or a global JNDI name on the
    target EJB.
    WLS 8.1 is following your ejb-link and telling you there's not enough
    information.
    You have 2 options:
    1) Remove the <ejb-link>...</ejb-link> from your web.xml. You'll be
    using just an ejb-reference at that point, but you've already included
    the necessary information in the weblogic.xml that we can locate the EJB
    via its global jndi-name
    or
    2) Change the ejb-link to be
    <ejb-link>CustomMessaginBrick.jar#CustomMessagingBrick</ejb-link>
    If you wanted to, you could then remove the reference info from the
    weblogic.xml
    -- Rob
    luca wrote:
    when deploying an ear module on weblogic 8.1 i get the following error:
    The ejb-link 'CustomessagingBrick.jar/CustomMessaginBrick' declared in ejb-ref
    or ejb-local-ref 'ejb/Service2' in the application module 'cmbrick.war' could
    not be resolved. The target EJB for the ejb ref could not be found.
    The ear is composed of two sub-modules:
    CustomMessaginBrick.jar
    cmbrick.war.
    The same ear was deployed on weblogic 6.1.
    Every reference in the ear seems in the right place so i am really clueless.
    Hereafter i include the relevant portions of the deployment descriptors.
    Thanks in advance!
    Greets,
    Luca
    the web.xml for cmbrick.war contains the following data:
    <ejb-local-ref>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <local-home>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocalHome</local-home>
    <local>com.hutchison3g.core.brick.custom.messaging.CustomMessagingBrickLocal</local>
    <ejb-link>CustomMessagingBrick</ejb-link>
    </ejb-local-ref>
    its weblogic.xml file is the following:
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN"
    "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
    <weblogic-web-app>
    <reference-descriptor>
    <ejb-reference-description>
    <ejb-ref-name>ejb/Service2</ejb-ref-name>
    <jndi-name>Service2</jndi-name>
    </ejb-reference-description>
    </reference-descriptor>
    </weblogic-web-app>
    while the weblogic-ejb-jar for CustomMessaging bricks contains the following:
    <weblogic-enterprise-bean>
    <ejb-name>CustomMessagingBrick</ejb-name>
    <stateless-session-descriptor>
    <pool>
    </pool>
    <stateless-clustering>
    </stateless-clustering>
    </stateless-session-descriptor>
    <transaction-descriptor>
    </transaction-descriptor>
    <enable-call-by-reference>True</enable-call-by-reference>
    <jndi-name>Service2</jndi-name>
    </weblogic-enterprise-bean>....

  • Error while deploying an application on weblogic 12c. An error occurred while reading the deployment descriptor. The error was: Error processing annotations

    Anyone please help me solve this error. I am trying to deploy an application on weblogic 12c  i am getting an error but the same application gets successfully deployed on weblogic 11g. The error is
    An error occurred during activation of changes, please see the log for details.
    Exception preparing module: EJBModule(gsCallbackAdapterLGTX-ejb.jar) An error occurred while reading the deployment descriptor. The error was: Error processing annotations: .
    [EJB:015001]Unable to link class com.aep.gridsmart.adapters.lgtx.buslogic.deliver.xform.AdapterTransfomerDeliverSession in Jar /appl/oracle/middleware/WLS/12.1.1.0/user_projects/domains/Gridsmart/servers/ManagedServer1/tmp/_WL_user/gsCallbackAdapterLGTX/34vz4d/gsCallbackAdapterLGTX-ejb.jar : java.lang.NoClassDefFoundError: com/aep/gridsmart/adapter/deliver/CommonAdapterDeliverBean

    Cotton please let me know what is the mistake i am
    doingThe following path does not exist.
    C:\Sun\AppServer7\domains\domain1\server1\
    applications\j2ee-modules\task_1\WEB-INF\web.xml

  • Persistence provider declared in the deployment descriptor is not supported

    Hi,
    When I try to deploy an entity bean (using JDev 3.2 and Oracle 8.1.7) I got this message:
    "Persistence provider declared in the deployment descriptor is not supported".
    Should I change something in the "..._oracle.xml" file generated by JDev?
    Anyway the xlm part, regarding the persistence provider, is:
    <persistence-provider>
    <description> specifies a type of persistence manager </description>
    <persistence-name>BC4J</persistence-name>
    <persistence-deployer> bcdom.DomejbViewDeployer</persistence-deployer>
    </persistence-provider>
    Anybody knows what is this about?
    Thanks,
    Gabi Rosu

    Hi,
    I've already deployed the CMPRuntime library, and I followed the cmpdemo demo step by step and this xml file is the result of the Jdev wizard. But I still got the same error message.
    I even edit the ..._oracle.xml file, changing the persistance provider into "oracle.aurora.ejb.persistence.ocmp.OcmpEntityDeployer", the way is in the online documentation, but it keeps saying that this class (OcmpEntityDeployer) is not found.
    So, what should I do?
    Thanks in advance,
    Gabi

  • The deployment descriptor Error in EAR DC

    Hi,
    I am getting following build error in my EAR DC :-
    "The deployment descriptor of the module '<vendor>.com~repcharejb.jar' cannot be loaded."
    Other details : -
    NWDS = CE 7.1 SP03
    Java version selected while creating EJB and EAR DCs = java 1.4
    List of DCs
    1. External Library DC containing JARs with compilation public part
    2. EJB DC which is using above External Library DC (just one stateless session bean, no DTOs, no entity beans)
    3. EAR DC for EJB DC
    I am not able to figure out what is going wrong here.
    Please help.
    Thanks and regards,
    Amey

    I created EAR DC with java 5 version and added EJB project as referenced project.
    And that worked!

  • Is it mandatory to configure a primarykey in the deployment descriptor.

    Is it mandatory to configure a primarykey in the deployment descriptor.
    Not all the tables in the database contains a primarykey.
    Suppose i have created an entity bean which represents a table that do not have a primary key.
    Now my question is what can i put as a return type of 'ejbCreate' method in the above created entity bean & how do i configure the primarykey information in DeploymentDescriptor?

    Hello ,
    I'm afraid not , the program for the transaction is admitting only Sapscript format , even the BADI
    QG_INSP_RESULT_PRINT allow to switch to a SAPscript form
    Regards

  • How do I read  the Deployment descriptor throw my application?

    Hi
    There is a need for me to read attributes in the Deployment descriptor through my application.
    How may I do that? I don't want to use a Parsa to read the XML file and get the attributes..
    Is there any other way?
    thanks
    Sanesh

    All attributes or just the context parameters?
    For example:
    <context-param>
    <param-name>dbDriverName</param-name>
    <param-value>org.gjt.mm.mysql.Driver</param-value>
    <description>The database driver being used</description>
    </context-param>
    Could be read from your servlet with:
    String dbDriverName = servletContext.getInitParameter("dbDriverName");
    But if you'd like to get out the servlet mappings or anything else I guess you have to read and parse the file. There was a method called getServletNames() in the servlet context but that's deprecated now.

  • How To Define Security in the deployment descriptor for an ejb

    Hi All
    Pls help!
    I am trying to call a remote ejb running on JBOSS in a remote server. Typically inside my code I would include a System.setSecurityManager() = new RMISecurityManager () etc. and specify a security policy file to use when running my client.
    But since I am running inside the application server where many other applications are running, I cannot use system.abc() it breaks everyone's application.
    Can someone please refer me to how to specify security manager policy inside the ejb-jar.xml deployment descriptor or how I can resolve the above issue. O am using OC4J to run my ejbs.
    Thanks
    Yours in Java

    Hi All
    Pls help!
    I am trying to call a remote ejb running on JBOSS in a remote server. Typically inside my code I would include a System.setSecurityManager() = new RMISecurityManager () etc. and specify a security policy file to use when running my client.
    But since I am running inside the application server where many other applications are running, I cannot use system.abc() it breaks everyone's application.
    Can someone please refer me to how to specify security manager policy inside the ejb-jar.xml deployment descriptor or how I can resolve the above issue. O am using OC4J to run my ejbs.
    Thanks
    Yours in Java

  • How to create the deployment descriptor with the sun application server

    I have packaged my .war and ejb-jar files. I go to autodeploy and it says i need a deployment descriptor?

    this is actually an example .ear file that i am trying to run. When i create the client with the deploytool that comes with suns application server i get
    C:\appclient>appclient -client swe645-appClient.jar
    Caught an unexpected exception!
    javax.naming.NameNotFoundException: EditEmpBean not found
            at com.sun.enterprise.naming.TransientContext.doLookup(TransientContext.
    java:185)
            at com.sun.enterprise.naming.TransientContext.lookup(TransientContext.ja
    va:157)
            at com.sun.enterprise.naming.SerialContextProviderImpl.lookup(SerialCont
    extProviderImpl.java:101)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at com.sun.corba.ee.impl.presentation.rmi.ReflectiveTie._invoke(Reflecti
    veTie.java:123)
            at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispa
    tchToServant(CorbaServerRequestDispatcherImpl.java:648)
            at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispa
    tch(CorbaServerRequestDispatcherImpl.java:192)
            at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest
    Request(CorbaMessageMediatorImpl.java:1709)
            at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest
    (CorbaMessageMediatorImpl.java:1569)
            at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleInput(C
    orbaMessageMediatorImpl.java:951)
            at com.sun.corba.ee.impl.protocol.giopmsgheaders.RequestMessage_1_2.call
    back(RequestMessage_1_2.java:181)
            at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest
    (CorbaMessageMediatorImpl.java:721)
            at com.sun.corba.ee.impl.transport.SocketOrChannelConnectionImpl.dispatc
    h(SocketOrChannelConnectionImpl.java:473)
            at com.sun.corba.ee.impl.transport.SocketOrChannelConnectionImpl.doWork(
    SocketOrChannelConnectionImpl.java:1262)
            at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.
    run(ThreadPoolImpl.java:409)

  • How to configure implementation class in the deployment descriptor?

    i'm tring to add <listener> element to my web application. the web server is Apache plus Tomcat(3.2.3), and i add the following line to WEB.XML of Tomcat:
    <listener>
    <listener-class>
    com.listeners.MySessionListener
    </listener-class>
    </listener>
    <listener>
    <listener-class>
    com.listeners.ServletContextAttribListener
    </listener-class>
    </listener>
    <listener>
    <listener-class>
    com.listeners.MySessionListener
    </listener-class>
    </listener>
    (according to the direction of http://forum.java.sun.com/thread.jsp?forum=45&thread=150088. i have read the article in detail)
    but nothing happened. when i make changes in the jsp page, nothing was noted in the the tomcat output window. i've got the MySessionListener.class and put it in the proper folder.
    where should i add the <listener> element? can HttpSessionBindingListener or HttpSessionListener work without adding the elements to web application configuration?
    thanks for your help and previous discussion!
    best regards.

    Hi
    The Listener features are part of Servlet specification 2.3 which is supported by Tomcat 4.0 beta 7. Tomcat 3.2.3 supports Servlet specification 2.2.
    To use listeners use Tomcat 4.0 beta version 7.
    Good Luck!
    Eshwar Rao
    Developer Technical Support
    Sun microsystems inc
    http://www.sun.com/developers/support

  • EJB Refs ( coded name and JNDI name )

    Hi
    I am just starting to develop EJBs . I can't get to work the EJB refs as expected . In a session bean I have a lookup for an Entity bean . Both beans are in separate JAR files , but in the same ear .
    The lookup from session bean to entity bean only works when
    the coded name in EJB ref is defined exactly the same as JNDI name for enity bean , also the name in lookup method must be the same in session bean .
    To my surprise , the JNDI name for the target EJB , defined in EJB ref for session bean , does not mater at all . Even if I change it to a non existant name , the bean lookup works .
    Theoritacally I understand that EJB ref is there to provide a mapping between the name of bean mentioned in code to the actual JNDI name of another bean , at the time of deployment .
    The above is happening in J2EE 1.4 envoirment .
    Please let me know , what am I doing here that is wrong .
    ( All examples and tutorials , usually give coded name same as JNDI name ) .
    Thanks
    Tarun

    Hi Tarun,
    The ejb-ref-name lives in a different namespace than the global JNDI names. Any names of ejb-refs, ejb-local-refs, resource-refs, etc. are scoped within a particular component's private namespace. All environment references are accessed via the java:comp/env namespace at runtime. So, if your ejb-ref-name(a.k.a "coded name") is ejb/foo in the deployment descriptor, you would access it from the code as follows :
    initialContext.lookup("java:comp/env/ejb/foo");
    This way, neither the standard deployment descriptor nor the code has any dependency on the global JNDI name. That's a good thing since the decision about which target EJB should be linked to is often not made until deployment time rather than development time. Furthermore, it means if you want to change the linking you can always do it without recompiling your code.
    As for the global JNDI names, the first thing to note is that they are completely vendor-specific. That's why they don't appear in the standard deployment descriptor. In the J2EE SDK, each EJB that exposes a Remote view is assigned a global JNDI name in sun-ejb-jar.xml. This JNDI name is assigned from the global namespace of the application server. There's nothing stopping it from also being "ejb/foo", but it refers to a different thing than the "ejb/foo" above.
    Now we have an ejb-ref called ejb/foo and an ejb whose JNDI name is ejb/foo, but we haven't linked the two. When it comes to linking, you have two choices:
    1. If the target ejb is in the same .ear as the client component, you can use the ejb-link mechanism. This allows you to specify the target ejb by referring to its ejb-name. Since ejb-name is only guaranteed to be unique within an ejb-jar, the syntax allows for you to give the uri of the containing ejb-jar, followed by #, followed by ejb-name.
    2. Alternatively, you can specify the global JNDI name of the target ejb using sun-ejb-jar.xml Note that this will work whether the target ejb is in the same .ear or not. However, it's the only option if the target ejb is in a different .ear. In this case, you would create an ejb-ref entry for the client component within the sun-ejb-jar.xml. e.g. :
    <ejb>
    <ejb-name>MyClientBean</ejb-name>
    <ejb-ref>
    <ejb-ref-name>ejb/foo</ejb-ref-name>
    <jndi-name>ejb/foo</jndi-name>
    </ejb-ref>
    </ejb>
    Again, it's just a coincidence that both names happen to be ejb/foo. They refer to different things.
    When you do a global lookup from your code, initialContext.lookup('ejb/foo"), it will work in some environments because you're simply bypassing the level of indirection provided by your component environment and going straight to the global namespace. This is non-portable and not a good idea, since you've now tightly coupled the name of the target ejb to your client component. That means if it changes you need to recompile your code. Hope this helps.
    --ken

  • Deployment Descriptor - run time modification

    As EJB spec states that deployment descriptor is for dynamic modification of EJB properties.
    I don't understand that once we give these (EJBs) JAR files to customer, how customer can change deployment descriptors which are hidden inside JAR files.
    Is there any tool which will open these JARs and modify the deployment descriptors.
    Any other comments are appreciated.
    I am using BAS 4.5 and JBoss 2.4.4.

    Greetings,
    As EJB spec states that deployment descriptor is for
    dynamic modification of EJB properties.Actually, the deployment descriptor allows for "post compile-time customization" of beans by means of the "declarative deployment model"...
    IOW, the DD provides information that is to be made available to the bean by its runtime environment (container), which information is provided in between compile-time and runtime. Such information may provide customization data ("Environment References"), make resources available (reference links), and/or provide security information (role references). The bean ("component", actually, since web-tier components now also benefit from deployment descriptors ;), can then get access to this information during it's runtime as required. Typically, this means customization data - which, of course, allow the bean to initialize its state for the application/enterprise in which it runs - though, role-references may be used to fine-grain security authorizations; reference links, however, may be thought of as working in the opposite direction - they are handled transaparently by the container - since, in essence it is the bean that is providing link value.
    I don't understand that once we give these (EJBs) JAR
    files to customer, how customer can change deployment
    descriptors which are hidden inside JAR files.Technically, it is the "bean descriptor", possibly the "assembly (application) descriptor", that is given to the end user (either the application assembler or deployer...), since the deployment descriptor is not created until actual deployment. ;)
    Of course, the real issue here is "component customization": the customer does not modify the DD, but rather provides values for the lookups the component is making (which lookups -as well as other details about what's expected from them - are provided to the customer along with the component), during either the assembly and/or deployment phases (each of which may produce their own DD levels).
    Is there any tool which will open these JARs and
    modify the deployment descriptors.In a manner of speaking... the vendor's deployment tool provides the intended capability.
    Any other comments are appreciated.
    I am using BAS 4.5 and JBoss 2.4.4.Regards,
    Tony "Vee Schade" Cook

  • Referencing EJB on remote server AND using deployment descriptor

    We're using Weblogic 6.1sp2 under Windows 2000.
    We have a web application on server A and several EJBs running on server B -
    some of these may in the future be moved to different servers.
    We would like to ensure that this only requires reconfiguring the deployment
    descriptors.
    In our web app, we access the EJB's like this:
    AccountHome accHome = (AccountHome) (new
    InitialContext()).lookup("java:comp/env/ejb/AccountHome")
    - we then map ejb/AccountHome to the JNDI name in the weblogic.xml file in
    the web app - the JNDI name will usually (but not always) be the class name
    of the implementing class, e.g. system.billing.accounting.AccountHome
    However, to make this work when the EJB is on server B, we must put a
    jndi.properties file in the server A classpath containing
    java.naming.provider.url=t3://server_b:7001/
    to point to server B.
    Now, this makes ALL JNDI lookups on server A go to server B - this is not
    what we want. Especially not in the case where some EJB's move to server C -
    B and C may be in separate clusters and will not be clustering the JNDI
    tree. Also, other web applications on the server will need to go to
    different servers.
    Alternatively, we could specify a property set in the InitialContext
    constructor with a provider url. But in that case, the mapping from
    web.xml/weblogic.xml is apparently not applied - or rather, if we look up
    "java:comp/env/ejb/AccountHome", weblogic maps it to
    "system.billing.accounting.AccountHome" and then tries to look it up on the
    local machine, server A.
    If we look up "system.billing.accounting.AccountHome", it does correctly
    look it up on the server specified in the provider url and finds the entry.
    However, this would mean that we would have to specify the exact jndi name.
    In addition, we would have to hard-code the server name for each lookup.
    An alternative would be to "copy" the JNDI entries from server B to server A
    (or to some other shared, global JNDI registry). But these would need to be
    kept in sync - especially since server B is really a cluster, where
    different servers may come online at different times and register their EJBs
    as clusterable, so the stubs would need to be continously updated.
    My best idea is to bypass the whole web.xml/weblogic.xml mapping scheme and
    just add our own config file with stuff like
    <mappings>
    <map entry="java:comp/env/ejb/AccountHome">
    <jndi-properties>
    java.naming.provider.url=t3://server_b:7001/
    java.naming.security.principal=jndiuser
    java.naming.security.credentials=mysecretpassword
    </jndi.properties>
    <jndi-name>sysmte.billing.accounting.AccountHome</jndi-name>
    </map>
    </mappings>
    We then need to wrap all the lookups in our own lookup mechanism which first
    checks the config file to find any mappings.
    However, this seems like reinventing the wheel and will also confuse most
    deployment tools etc.
    Does anybody have any suggestions where we
    1. Don't put a jndi.properties file in the server classpath
    2. Lookup ejb's using "java:comp/env/ejb/SomeEJB" - not the JNDI name.
    3. Don't hardcode the server names in the application - but potentially
    in the deployment descriptor.
    4. Can look up different EJB's on different machines
    Niels Harremoës

    There is an article on dev2dev that may explain what you are seeing...
    http://dev2dev.bea.com/articlesnews/discussion/thread.jsp?thread=142
    HTH
    dwfa
    "Niels Ull Harremoës" <[email protected]> wrote in message
    news:[email protected]...
    It turns out that we can make it work by entering the url of the server in
    the weblogic.xml entry - e.g. instead of having
    <reference-descriptor>
    <ejb-reference-description>
    <ejb-ref-name>ejb/AccountHome</ejb-ref-name>
    <jndi-name>system.billing.accounting.AccountHome</jndi-name>
    </ejb-reference-description>
    </reference-descriptor>
    we enter
    <reference-descriptor>
    <ejb-reference-description>
    <ejb-ref-name>ejb/AccountHome</ejb-ref-name>
    <jndi-name>t3://server_b:7001/system.billing.accounting.AccountHome</jndi-na
    me>
    </ejb-reference-description>
    </reference-descriptor>
    However, we are unsure on whether this will establish a new JNDIconnection
    to server_b on every lookup? And it's not documented anywhere?
    Does anybody have any other suggestions?
    "Niels Ull Harremoës" <[email protected]> wrote in message
    news:[email protected]...
    We're using Weblogic 6.1sp2 under Windows 2000.
    We have a web application on server A and several EJBs running on serverB -
    some of these may in the future be moved to different servers.
    We would like to ensure that this only requires reconfiguring thedeployment
    descriptors.
    In our web app, we access the EJB's like this:
    AccountHome accHome = (AccountHome) (new
    InitialContext()).lookup("java:comp/env/ejb/AccountHome")
    - we then map ejb/AccountHome to the JNDI name in the weblogic.xml file
    in
    the web app - the JNDI name will usually (but not always) be the classname
    of the implementing class, e.g. system.billing.accounting.AccountHome
    However, to make this work when the EJB is on server B, we must put a
    jndi.properties file in the server A classpath containing
    java.naming.provider.url=t3://server_b:7001/
    to point to server B.
    Now, this makes ALL JNDI lookups on server A go to server B - this is
    not
    what we want. Especially not in the case where some EJB's move to serverC -
    B and C may be in separate clusters and will not be clustering the JNDI
    tree. Also, other web applications on the server will need to go to
    different servers.
    Alternatively, we could specify a property set in the InitialContext
    constructor with a provider url. But in that case, the mapping from
    web.xml/weblogic.xml is apparently not applied - or rather, if we look
    up
    "java:comp/env/ejb/AccountHome", weblogic maps it to
    "system.billing.accounting.AccountHome" and then tries to look it up onthe
    local machine, server A.
    If we look up "system.billing.accounting.AccountHome", it does correctly
    look it up on the server specified in the provider url and finds theentry.
    However, this would mean that we would have to specify the exact jndiname.
    In addition, we would have to hard-code the server name for each lookup.
    An alternative would be to "copy" the JNDI entries from server B to
    server
    A
    (or to some other shared, global JNDI registry). But these would need tobe
    kept in sync - especially since server B is really a cluster, where
    different servers may come online at different times and register theirEJBs
    as clusterable, so the stubs would need to be continously updated.
    My best idea is to bypass the whole web.xml/weblogic.xml mapping schemeand
    just add our own config file with stuff like
    <mappings>
    <map entry="java:comp/env/ejb/AccountHome">
    <jndi-properties>
    java.naming.provider.url=t3://server_b:7001/
    java.naming.security.principal=jndiuser
    java.naming.security.credentials=mysecretpassword
    </jndi.properties>
    <jndi-name>sysmte.billing.accounting.AccountHome</jndi-name>
    </map>
    </mappings>
    We then need to wrap all the lookups in our own lookup mechanism whichfirst
    checks the config file to find any mappings.
    However, this seems like reinventing the wheel and will also confuse
    most
    deployment tools etc.
    Does anybody have any suggestions where we
    1. Don't put a jndi.properties file in the server classpath
    2. Lookup ejb's using "java:comp/env/ejb/SomeEJB" - not the JNDIname.
    3. Don't hardcode the server names in the application - butpotentially
    in the deployment descriptor.
    4. Can look up different EJB's on different machines
    Niels Harremoës

Maybe you are looking for

  • LPX ALWAYS unexpectedly quits when I send song to iTunes.

    Got a new MacBook, installed Logic (previously a GarageBand user, was excited to upgrade once I got a computer that could handle it). Keeps crashing I've tried everything I could find in these forums, and every song I've made has unexpectedly quit ri

  • Using the JRC, RTF embedded in Crystal while exporting to PDF

    Are there enough acronyms for ya?  I donu2019t think so either.  I am wondering if anyone else has experienced the problem I am facing and what fix, if any, did they find.  I have RTF data stored in the database I am trying to read into a report.  I

  • Application not found asha 305

    Hey! Am back again. All my asha 305 pre-installed apps display "application not found" upon trying to launch anyone of them. Help me out coz I still regard those apps essential to me and am not about to change my phone.

  • No digital tv signal message

    When i switched my tv on i got a message saying that there is no digital tv signal found. It had another message undeneath which gave me 5 minutes before the tv switched off. I couldn't move from this screen which means I cannot access settings to tr

  • Nokia Suite 3.5 (Beta) is supporting N9 now

    Good news for N9 users: The latest version Nokia Suite 3.5 is supporting the N9 now. http://betalabs.nokia.com/apps/nokia-suite-beta See also article here: http://www.allboutn9.info/2012/06/nokia-suite-now-​compatible-with-nokia.html I haven't tested