Will weblogic-ejb-jar.xml dtd 6.0 working fine on server 8.1?
Hi guys,
I have problem when use weblogic-ejb-jar.xml on server 8.1. JNDI compalain can not find local-home.
Thanks!
The interfaces and ejb-jar.xml, weblogic-ejb-jar.xml were generated by Xdoclet. I just copy the .ear file to the deployment directory. Is there anything more I need to do? Thanks!
Here is the error message:
javax.naming.LinkException: . Root exception is javax.naming.NameNotFoundException: remaining name: java:app/ejb/sims_hta.jar#HierarchyAdminSession/local-home
at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:35)
at weblogic.j2eeclient.SimpleContext.resolve(SimpleContext.java:39)
at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:57)
at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:62)
at javax.naming.InitialContext.lookup(InitialContext.java:347)
at weblogic.jndi.internal.WLNamingManager.getObjectInstance(WLNamingManager.java:96)
at weblogic.jndi.internal.ServerNamingNode.resolveObject(ServerNamingNode.java:265)
at weblogic.jndi.internal.BasicNamingNode.resolveObject(BasicNamingNode.java:732)
at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:191)
at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196)
at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196)
at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196)
at weblogic.jndi.internal.BasicNamingNode.lookup(BasicNamingNode.java:196)
at weblogic.jndi.internal.WLEventContextImpl.lookup(WLEventContextImpl.java:237)
at weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:336)
at javax.naming.InitialContext.lookup(InitialContext.java:347)
at com.hta.servlet.HTAUtil.getHierarchyAdminSessionLocal(HTAUtil.java:622)
at com.hta.servlet.HTAUtil.getPropertyDictionaryValues(HTAUtil.java:745)
at com.hta.servlet.jsp.bean.Admin.getPropertyDictinaryValues(Admin.java:870)
at com.hta.servlet.jsp.bean.Admin.getRunLevelDisplayParameters(Admin.java:819)
at jsp_servlet._sims_jsp._app._hta.__incell_import._jspService(__incell_import.java:463)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:33)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:971)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:402)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:305)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6350)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3635)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2585)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
Similar Messages
-
Discrepancy between weblogic-ejb-jar.xml DTD and documentation
There seems to be a discrepancy between the DTD for the weblogic-ejb-jar.xml file
and the WLS7 documentation: Which source of information should I treat as
For example, the WLS7 documentation contains no information on the <idempotent-methods>
element (and its child elements)
(There is also a (larger) discrepancy between the weblogic-application.xml DTD and
the docs - I will post that Q under application deployment)
Regards,
NickYep, I noticed it too. I used DTD, of course.
"Nick Minutello" <[email protected]> wrote
in message news:[email protected]..
>
>
There seems to be a discrepancy between the DTD for theweblogic-ejb-jar.xml file
and the WLS7 documentation: Which source of information should I treat as
For example, the WLS7 documentation contains no information on the<idempotent-methods>
element (and its child elements)
(There is also a (larger) discrepancy between the weblogic-application.xmlDTD and
the docs - I will post that Q under application deployment)
Regards,
Nick -
Weblogic-ejb-jar.xml ---- persistence-type
Hi all,
How does wls6.1determine the "type-identifier" (weblogic-ejb-jar.xml) of a
JDBC-Datastore? Which method will be called to get that information? My
vendor does not provide the correct type-identifier!!
I can´t believe that this is all about the weblogic-ejb-jar.xml --
type-identifier I found at
http://e-docs.bea.com/wls/docs61/////ejb/reference.html#1071588.
It writes:
"..if you use a different persistence vendor, consult the vendor's
documentation for information on the correct type-identifier."
Part of a weblogic-ejb-jar.xml:
<persistence-type>
<type-identifier>JDataStore</type-identifier>
<type-version>3.0</type-version>
<type-storage>meta-inf/weblogic-cmp-rdbms-jar.xml</type-storage>
</persistence-type>
Thanks!!!
Thomasthanks a lot!!
Rob Woollen <[email protected]> wrote:
The 7.0 DTD is not entirely upward compatible from the 6.x DTD. There
is a DDConverter tool which will convert 6.x DTDs to 7.0.
In this case, they were trying to make your life simpler by no longer
making there be so many entries just to use WebLogic's CMP implementation.
-- Rob
dayFly wrote:
thanks for your help
I have replaced the dtd with 6.0's
that is to say the 7.0 dtd is not compatible with 6.0 dtd?
I am a rookie
Rob Woollen <[email protected]> wrote:
The error message is a bit confusing. It means that persistence-type
is
not an element in the DTD.
In other words, your descriptor does not conform to the 7.0 DTD that
you
reference.
-- Rob
dayFly wrote:
when execute java weblogic.ejbc,The console show the wrong messages:
ERROR: Error from ejbc: Error parsing 'META-INF/weblogic-ejb-jar.xml'
line 12:Element type "persistence-type" must be declared
but in my weblogic-ejb-jar.xml,persistence-type had been declared.
weblogic-ejb-jar:
<?xml version="1.0"?>
"-//BEA Systems, Inc.//DTD WebLogic 7.0.0 EJB//EN"
"http://www.bea.com/servers/wls700/dtd/weblogic-ejb-jar.dtd">
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>StudentEJB</ejb-name>
<entity-descriptor>
<persistence>
<persistence-type>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>7.0</type-version>
<type-storage>META-INF/weblogic-cmp-rdbms.xml</type-storage>
</persistence-type>
<persistence-use>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>7.0</type-version>
</persistence-use>
</persistence>
</entity-descriptor>
<jndi-name>StudentEJB</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
waiting for your help,thanks -
Weblogic-ejb-jar.xml tags
can anybody tell me if the jndi name tag can come before the ejbtype-descriptor tag
like instead of the usual
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>MyTestSessionBean</ejb-name>
<stateless-session-descriptor>
<pool>
</pool>
<stateless-clustering>
</stateless-clustering>
</stateless-session-descriptor>
<transaction-descriptor>
</transaction-descriptor>
<jndi-name>MyTestSessionBean</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
can it be like
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>MyTestSessionBean</ejb-name>
<jndi-name>MyTestSessionBean</jndi-name>
<stateless-session-descriptor>
<pool>
</pool>
<stateless-clustering>
</stateless-clustering>
</stateless-session-descriptor>
<transaction-descriptor>
</transaction-descriptor>
<jndi-name>MyTestSessionBean</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
i think it should not be a problem as long as its within the <weblogic-enterprise-bean>: i am generating DDs for weblogic and ejbs and its a big applictaion i dont know if it will work or not. thanks in advance
Message was edited by sarmahdi at Sep 3, 2004 7:45 AMit seems that unfortunately i cannot but i really appreciate your answer:
ejbname should follow descriptor then jndi name i gues as i am having errors
<!ELEMENT weblogic-enterprise-bean (
ejb-name,
(entity-descriptor|
stateless-session-descriptor|
stateful-session-descriptor|
message-driven-descriptor
transaction-descriptor?,
iiop-security-descriptor?,
reference-descriptor?,
enable-call-by-reference?,
clients-on-same-server?,
(run-as-identity-principal|
run-as-principal-name
create-as-principal-name?,
remove-as-principal-name?,
passivate-as-principal-name?,
jndi-name?,
local-jndi-name?,
dispatch-policy?)
>
i am having this error: Module: core_ejb_sb.jar Error: [EJB:011024]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:
Error parsing file 'META-INF/weblogic-ejb-jar.xml' at line: 9 column: 29. The content of element
type "weblogic-enterprise-bean" must match "
(ejb-name,
(entity-descriptor|stateless-session-descriptor|stateful-session-descriptor|message-driven-descriptor)?,
transaction-descriptor?,iiop-security-descriptor?,reference-descriptor?,enable-call-by-reference?,clients-on-same-server?,(run-as-identity-principal|
run-as-principal-name)?,create-as-principal-name?,remove-as-principal-name?,passivate-as-principal-name?,jndi-name?,local-jndi-name?,dispatch-policy?)"
i guess i have to change the format now. -
Dynamic jndi-name in weblogic-ejb-jar.xml
Is there a way to create dynamic (i.e. runtime) jndi-names for EJBs instead of
(or in addition to) "hard coding" them in the weblogic-ejb-jar.xml file? What
I'm trying to do is have one WebLogic instance (JVM) host multiple environments
(our Beta and Training environments) and I simply want to deploy the same .ear
file twice but have each environment (application - .ear) reference a different
database schema (jdbc connection pool). I have everything working just fine for
this scenario except when I define jndi-names for our ejbs. The problem is that
I am really deploying the same ejbs (jndi-names and actually code base) in each
applicatoin instance and I get an exception when the WebLogic is trying to deploy
the second application (.ear) because the jndi-names in it have already been deployed
by the first application instance. I recieve a jndi error stating that the name
is already deployed.
Or is there a better path to go down for what I am trying to do to have one WebLogic
instance support our beta and training environments? Usually (but not always)
our code base is the for same for both of these environments, I simply need to
have each environment use a different database schema.
ThanksA little birdie tells me that BEA does this very thing. Looking at the
descriptors for WebLogic Portal I see:
<weblogic-enterprise-bean>
<ejb-name>LoaderEJB</ejb-name>
<enable-call-by-reference>True</enable-call-by-reference>
<jndi-name>${APPNAME}.BEA_content.LoaderHome</jndi-name>
</weblogic-enterprise-bean>
Yes, the ${APPNAME} token really is expanded into the J2EE application
name at deployment time!
Sincerely,
Daniel Selman
Bryan Dixon wrote:
Rewriting our build process isn't really much of an option for me. Our current
build process is too complex and time consuming right now to convert to Ant (we
eventually will do this but not for a while). So are there any other ideas that
aren't build related?
Thanks
"Eric Ma" <[email protected]> wrote:
You don't need run-time dynamism in JDNI names and it can't be done anyways.
You
need token substitution in XML configuration files when building the
app. If
you are using Ant for building, then it is a breeze. If not, first convert
your
build process to use Ant.
Also, a single WLS instance hosting multiple environments sounds really
INTRIGUING
to me.
Eric Ma
"Bryan Dixon" <[email protected]> wrote:
Is there a way to create dynamic (i.e. runtime) jndi-names for EJBsinstead
of
(or in addition to) "hard coding" them in the weblogic-ejb-jar.xml file?
What
I'm trying to do is have one WebLogic instance (JVM) host multiple environments
(our Beta and Training environments) and I simply want to deploy the
same .ear
file twice but have each environment (application - .ear) referencea
different
database schema (jdbc connection pool). I have everything working just
fine for
this scenario except when I define jndi-names for our ejbs. The problem
is that
I am really deploying the same ejbs (jndi-names and actually code base)
in each
applicatoin instance and I get an exception when the WebLogic is trying
to deploy
the second application (.ear) because the jndi-names in it have already
been deployed
by the first application instance. I recieve a jndi error stating that
the name
is already deployed.
Or is there a better path to go down for what I am trying to do to have
one WebLogic
instance support our beta and training environments? Usually (but not
always)
our code base is the for same for both of these environments, I simply
need to
have each environment use a different database schema.
Thanks -
Use of externally-defined/ in weblogic-ejb-jar.xml
I am trying to use Global Roles defined via the Weblogic console to control access to EJB methods.
I am using the <externally-defined/> tag in security role assignments, however when I deploy to Weblogic I get the following error :
<8/09/2004 04:21:42 PM GMT+10:00> <Error> <Deployer> <BEA-149205> <Failed to initialize the application appsdirmars-marketdata_ear due to error weblogic.manag
ement.ApplicationException: Prepare failed. Task Id = null
Module Name: ejb-marketdata.jar, Error: [EJB:011024]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:
Error parsing file 'META-INF/weblogic-ejb-jar.xml' at line: 51 column: 26. Element type "externally-defined" must be declared..
at weblogic.j2ee.J2EEApplicationContainer.checkForErrors(J2EEApplication
Container.java:1612)
at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContain
er.java:1207)
at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContain
er.java:1051)
at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContain
er.java:823)
at weblogic.management.deploy.slave.SlaveDeployer$Application.prepare(Sl
aveDeployer.java:2925)
at weblogic.management.deploy.slave.SlaveDeployer.prepareAllApplications
(SlaveDeployer.java:967)
at weblogic.management.deploy.slave.SlaveDeployer.resume(SlaveDeployer.j
ava:349)
at weblogic.management.deploy.DeploymentManagerServerLifeCycleImpl.resum
e(DeploymentManagerServerLifeCycleImpl.java:229)
at weblogic.t3.srvr.SubsystemManager.resume(SubsystemManager.java:131)
at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:966)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:361)
at weblogic.Server.main(Server.java:32)
I am running Weblogic 8.1 SP3 on Windows XP Pro.
The XML is valid for the specified DTD according to my XML editor.
The relevevant fragment from weblogic-ejb-jar.xml is included below.
Any help much appreciated.
Gavin.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN" "http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd">
<weblogic-ejb-jar>
<security-role-assignment>
<role-name>MarsAdmin</role-name>
<externally-defined/>
</security-role-assignment>
<security-role-assignment>
<role-name>MarsViewer</role-name>
<externally-defined/>
</security-role-assignment>
</weblogic-ejb-jar>I tried using the <global-role/> tag instead - this does deploy without any errors - but when I call the secure EJB method I get the Security Violation error below.
The DTD says using the <global-role/> tag is fine, albeit deprecated, but the Weblogic 8.1 manual says this has been replaced by <externally-defined/>, so I'm not sure if this should work or not.
[EJB:010160]Security Violation: User: 'ghughes' has insufficient permission to access EJB: type=<ejb>, application=_appsdir_mars-marketdata_ear, module=ejb-marketdata.jar, ejb=marketdata.MarketDataManager, method=getEnergyOverview, methodInterface=Remote, signature={java.util.Date}.
So on the whole I'd prefer to work out why Weblogic isn't recognising <externally-defined/> - I've included the full deployment descriptor below - I'm generating it using the latest snapshot of XDoclet - is the DTD specified correct for Weblogic 8.1 SP3 ? (It matches the one specified in http://e-docs.bea.com/wls/docs81/ejb/DDreference-ejb-jar.html - but I can't think of anything else that could be wrong).
Any tips much appreciated as I need to enable an administrator to customise these roles at runtime rather than hard-coding the role - group mappings into the deployment descriptors.
Thanks,
Gavin.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN" "http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd">
<weblogic-ejb-jar>
<description><![CDATA[Generated by XDoclet]]></description>
<weblogic-enterprise-bean>
<ejb-name>marketdata.MarketDataManager</ejb-name>
<stateless-session-descriptor>
</stateless-session-descriptor>
<reference-descriptor>
</reference-descriptor>
<jndi-name>marketdata.MarketDataManager</jndi-name>
<local-jndi-name>marketdata.MarketDataManagerLocal</local-jndi-name>
</weblogic-enterprise-bean>
<weblogic-enterprise-bean>
<ejb-name>marketdata.MessageManager</ejb-name>
<message-driven-descriptor>
<pool>
<max-beans-in-free-pool>5</max-beans-in-free-pool>
<initial-beans-in-free-pool>1</initial-beans-in-free-pool>
</pool>
<destination-jndi-name>FileTopic</destination-jndi-name>
<connection-factory-jndi-name>JMSConnectionFactory</connection-factory-jndi-name>
<jms-polling-interval-seconds>10</jms-polling-interval-seconds>
<jms-client-id>1</jms-client-id>
</message-driven-descriptor>
<transaction-descriptor>
<trans-timeout-seconds>10</trans-timeout-seconds>
</transaction-descriptor>
<reference-descriptor>
</reference-descriptor>
<enable-call-by-reference>True</enable-call-by-reference>
</weblogic-enterprise-bean>
<!--
To add enterprise beans that you have deployment descriptor info for, add
a file to your XDoclet merge directory called weblogic-enterprise-beans.xml that contains
the <weblogic-enterprise-bean></weblogic-enterprise-bean> markup for those beans.
-->
<!-- xdoclet merge file -> weblogic-ejb-jar.xml -->
<security-role-assignment>
<role-name>MarsAdmin</role-name>
<externally-defined/>
</security-role-assignment>
<security-role-assignment>
<role-name>MarsViewer</role-name>
<externally-defined/>
</security-role-assignment>
<idempotent-methods>
</idempotent-methods>
</weblogic-ejb-jar>
Message was edited by [email protected] at Sep 8, 2004 8:45 PM -
ERROR: Error parsing 'META-INF/weblogic-ejb-jar.xml'
I have this error while compiling session bean (Stateful). my weblogic-ejb-jar.xml
file looks like this. Could anyone tell me what I'm doing wrong.
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>TransactionAgent</ejb-name>
<stateless-session-descriptor>
<pool>10</pool>
<stateless-clustering>false</stateless-clustering>
</stateless-session-descriptor>
<ejb-ref-name>ejb/Transaction</ejb-ref-name>
<jndi-name>Transaction</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar><pool> should not have any value. Instead it shud have the child nodes
<max-beans-in-free-pool> and/or <initial-beans-in-free-pool>
it will look like
<pool>
<max-beans-in-free-pool> 500 </max-beans-in-free-pool>
<initial-beans-in-free-pool>100 </initial-beans-in-free-pool>
</pool>
Also, <ejb-ref-name> and <jndi-name> goes under <ejb-reference-descriptor>
which is under <reference-descriptor>
So it would look like
<reference-descriptor>
<ejb-reference-description>
<ejb-ref-name> .. </ejb-ref-name>
<jndi-name> .. </jndi-name>
<ejb-reference-description>
</reference-descriptor>
The jndi name should also be defined for the bean. Also note that ejb-refs
are defined under a bean which is referring other beans. Like Transaction
should not refer to itself. Rather if it is referring to Customer, then
ejb-ref will be defined for CustomerBean.
Hope it helps.
Rupesh.
Owen <[email protected]> wrote in message
news:3c614fb0$[email protected]..
>
I have this error while compiling session bean (Stateful). myweblogic-ejb-jar.xml
file looks like this. Could anyone tell me what I'm doing wrong.
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>TransactionAgent</ejb-name>
<stateless-session-descriptor>
<pool>10</pool>
<stateless-clustering>false</stateless-clustering>
</stateless-session-descriptor>
<ejb-ref-name>ejb/Transaction</ejb-ref-name>
<jndi-name>Transaction</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar> -
Disable-warning statement in weblogic-ejb-jar.xml
I'm having problems with the <disable-warning> statement in the weblogic-ejb-jar.xml file. I havn't been able to find documentation on exactly where the statment is supposed to be placed, as all sites just say to include the statement in your weblogic-ejb-jar.xml file. I found a working solution where I placed the statement after declaring all the weblogic-enterprise-bean and right before the closing </weblogic-ejb-jar> statment.
Now the problem is that I have included a <transaction-isolation> block and weblogic complains about my disable warning statment.
Does anyone know the proper location for the <disable-warning> statement?
here is the format that was working before:
</weblogic-enterprise-bean>
<disable-warning>BEA-010054</disable-warning>
</weblogic-ejb-jar> now I have:
</weblogic-enterprise-bean>
<transaction-isolation>
<isolation-level>TRANSACTION_READ_COMMITTED</isolation-level>
<method>
</method>
</transaction-isolation>
<disable-warning>BEA-010054</disable-warning>
</weblogic-ejb-jar>I have tried putting the disable warning before the transaction-isolation and after and weblogic complains about both.
Any Ideas?
Thanks for your time.I have tried putting the disable warning beforethe
transaction-isolation and after and weblogic
complains about both.
Any Ideas?It would be a good idea to post the message weblogic
is displaying. There are a couple of things you could
check:
* As per the documentation, the <disable-warning> tag
was added in 8.1. Check if you are using the correct
DTD for Weblogic 8.1 (and the version of Weblogic
is 8.1 or higher
* As per the DTD, the <disable-warning> comes after
the <transaction-isolation>
<!ELEMENT weblogic-ejb-jar (description?,
weblogic-enterprise-bean*,
security-role-assignment*,
run-as-role-assignment*,
security-permission?,
transaction-isolation*,
idempotent-methods?,
enable-bean-class-redeploy?,
disable-warning*)
ke sure you maintain this order of elements within
<weblogic-ejb-jar>
Refer to
http://e-docs.bea.com/wls/docs81/ejb/DDreference-ejb-j
ar.htmlYep, it was pointing to an older dtd. Thank you! -
Weblogic-ejb-jar.xml generation and editing question with JEE5 / EJB3
Since EJBGen only works with EJB 2.1, is there a way to auto-generate weblogic-ejb-jar.xml when using a JEE5 ejb module?
In the tooling like OEPE 11g, an EJB3 project will generate an empty deployment descriptor weblogic-ejb-jar.xml file if you mark it that way in the wizard, but it doesn't populate it with any values.
Is the weblogic-ejb-jar.xml file is created/edited by hand, do the settings like this example still work or even make sense given the changes in the spec between 2.1 and 3.0?
<weblogic-enterprise-bean>
<ejb-name>HelloUser</ejb-name>
<stateless-session-descriptor>
<pool>
<max-beans-in-free-pool>50</max-beans-in-free-pool>
<initial-beans-in-free-pool>10</initial-beans-in-free-pool>
</pool>
<stateless-clustering>
<home-is-clusterable>True</home-is-clusterable>
<home-load-algorithm>round-robin</home-load-algorithm>
<stateless-bean-is-clusterable>True</stateless-bean-is-clusterable>
<stateless-bean-load-algorithm>round-robin</stateless-bean-load-algorithm>
</stateless-clustering>
</stateless-session-descriptor>
<enable-call-by-reference>true</enable-call-by-reference>
</weblogic-enterprise-bean>
........Hi,
For a JEE5 EJB module, rather than using EJBGen, you can use WLS specific annotations for configuring common settings. If you follow the link below, you can see a list of supported EJB annotations. Disregard the fact that the documentation section title is WebLogic Kodo Annotations. That is incorrect and I've filed a bug for it.
http://edocs.bea.com/wls/docs103/ejb30/annotations.html#wp1438036.
Unfortunately, we don't yet support setting all weblogic-ejb-jar.xml configuration values via annoations so in some cases a weblogic-ejb-jar.xml is still required.
You can hand edit your weblogic-ejb-jar.xml and the example you posted below should work fine.
- Matt -
Application deployment order with weblogic-ejb-jar.xml and jndi-name
I have two applicatation working on Weblogic server v. 10.3.6.
First of them creating one ejb stateless bean and creates JNDI maping for it (in weblogic-ejb-jar.xml file):
<weblogic-enterprise-bean>
<ejb-name>ConfigMenegerBean</ejb-name>
<stateless-session-descriptor>
<stateless-session-descriptor>
<business-interface-jndi-name-map>
<business-remote>package.ConfigurationSessionRemote</business-remote>
<jndi-name>ConfigMeneger</jndi-name>
</business-interface-jndi-name-map>
</stateless-session-descriptor>
<enable-call-by-reference>true</enable-call-by-reference>
<jndi-name>ConfigMeneger</jndi-name>
</weblogic-enterprise-bean>
Second appication have to refer for this bean by JNDI using spring been lookup :
<jee:jndi-lookup id="configManager" jndi-name="ConfigMeneger"/>
I changed deployment order parameter for both apllication(first=100 and second=500) in order to first app start first and share bean by jndi to another application. Unfortuantelly I got an error :
javax.naming.NameNotFoundException: Unable to resolve 'ConfigMeneger'. Resolved ''; remaining name 'ConfigMeneger'
How can I configure deployment order that first application make jndi mapping for bean, before the second application will use it ?Ok in a way I have solved my problem (even if I am not completely satisfied by the way on how to proceed...). So thanks to message "JBuilder7.0 and Weblogic6.1" on EJB sun forum :
http://forum.java.sun.com/thread.jsp?thread=285735&forum=13&message=1255488
I have tried the following actions (mentionned in the other forum messages):
- To preserve changes to weblogic*.xml, the safest way is to change the ejb-borland.xml.
(I am not sure that I have applied this advice correctly, because I suppose that syntax is not similar in weblogic file or borland file).
And you can MANUALLY update the weblogic file in your JAR archive.
1. Open the EJB JAR file in Winzip and extract the weblogic-ejb-jar.xml file, so that a copy exists in your
project directory.
2. Open this file (in Notepad), add the WebLogic specific information, and then save the file.
3. Now, when you are finished with the build cycle and are ready to deploy, you may open the EJB jar file
and swap in the weblogic-ejb-jar.xml file."
Good Luck. -
Toplink-ejb-jar.xml config with weblogic-ejb-jar.xml
Hello,
To use toplink with EJB's deployed in Weblogic.
I changed weblogic-ejb-jar.xml :
(Because, it does not allow me to change <type-identifier> and <type-version> elements)
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>7.0</type-version>
<type-storage>META-INF/toplink-ejb-jar.xml</type-storage>
Here, is the toplink-ejb-jar.xml:
(Because, I am asked to give PUBLIC value for Weblogic 8.1.0....)
<!DOCTYPE toplink-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB RDBMS Persistence//EN" "file://D:/Toplink10g/toplink/config/dtds/toplink-wls-ejb-jar_10_0_3.dtd">
<toplink-ejb-jar>
<session>
<name>myUniqueSession</name>
<project-xml>META-INF/project.xml</project-xml>
<login>
<connection-pool>demoPool</connection-pool>
</login>
</session>
</toplink-ejb-jar>
1. I have also given full path to the "toplink-wls-ejb-jar_10_0_3.dtd", but I still get parsing error:
"myBeans.jar": [EJB:011019]While reading META-INF/toplink-ejb-jar.xml, the persistence layer of the Entity EJB failed to deploy. The error was:
"myBeans.jar": Error in descriptor line 5: Error parsing file at line: 5 column: 18. Element type "toplink-ejb-jar" must be declared..
2. Also, How I can avoid the full path to the DTD???
Thanks for your help in this regard!You are not properly configured to use TopLink with Weblogic. You need to place the TopLink_CMP_Descriptor.xml install file in your Weblogic lib/persistence directory. Add "TopLink_CMP_Descriptor.xml" to your persistence.install file and then update weblogic-ejb-jar.xml to reference the correct TopLink persistence type and versions, ie,
<type-identifier>TopLink_CMP_2_0</type-identifier>
<type-version>10</type-version>
<type-storage>META-INF/toplink-ejb-jar.xml</type-storage>
See the TopLink developer guide for more information and configuration details.
http://download-east.oracle.com/docs/cd/B10464_05/web.904/b10313/pkg_depl.htm#1124524
Cheers,
Guy -
Deploy ejb on wls7.0 weblogic.ejb.jar.xml ! help
Morning !
i'm try to deploy a EJB on wls7.0
my descriptor is like this and i don't really undestand what's go wrong.
thanks you to help
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 7.0.0
EJB//EN" "http://www.bea.com/servers/wls700/dtd/weblogic700-ejb-jar.dtd" >
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<entity>
<ejb-name>Compte</ejb-name>
<bean-home-name>Compte</bean-home-name>
<resource-ref>
<res-ref-name>jdbc/DataSource</res-ref-name>
<jndi-name>DataSource</jndi-name>
</resource-ref>
<cmp-info>
<database-map>
<table>"Compte"</table>
<column-map>
<field-name>id</field-name>
<column-name>"id"</column-name>
</column-map>
<column-map>
<field-name>nomSte</field-name>
<column-name>"nomSte"</column-name>
</column-map>
<column-map>
<field-name>dateCreation</field-name>
<column-name>"dateCreation"</column-name>
</column-map>
<column-map>
<field-name>nbEmployes</field-name>
<column-name>"nbEmployes"</column-name>
</column-map>
<column-map>
<field-name>caSte</field-name>
<column-name>"caSte"</column-name>
</column-map>
<column-map>
<field-name>descSte</field-name>
<column-name>"descSte"</column-name>
</column-map>
<column-map>
<field-name>logo</field-name>
<column-name>"logo"</column-name>
</column-map>
<column-map>
<field-name>id_commercial</field-name>
<column-name>"id_commercial"</column-name>
</column-map>
</database-map>
<finder>
<method-signature>findAll()</method-signature>
<where-clause />
<load-state>True</load-state>
</finder>
</cmp-info>
</entity>
<datasource-definitions>
<datasource>
<jndi-name>DataSource</jndi-name>
<url>jdbc:odbc:dev_java</url>
<username>sa</username>
<password>lnx.sully</password>
<driver-class-name>sun.jdbc.odbc.JdbcOdbcDriver</driver-class-name>
</datasource>
</datasource-definitions>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
the EXception is !
Exception
weblogic.management.ApplicationException: No deployment found at
E:\bea70\weblogic700\server\bin\GRPEJB.jar.
at
weblogic.j2ee.J2EEApplicationContainerFactory.initializeDeployment(J2EEAppli
cationContainerFactory.java:350)
at
weblogic.management.deploy.DeployerRuntime.unprotectedActivate(DeployerRunti
me.java:350)
at
weblogic.management.deploy.DeployerRuntime.access$0(DeployerRuntime.java:282
at
weblogic.management.deploy.DeployerRuntime$1.run(DeployerRuntime.java:947)
at
weblogic.security.service.SecurityServiceManager.runAs(SecurityServiceManage
r.java:721)
at
weblogic.management.deploy.DeployerRuntime.checkAndPerformDeployerActions(De
ployerRuntime.java:941)
at
weblogic.management.deploy.DeployerRuntime.activate(DeployerRuntime.java:279
at java.lang.reflect.Method.invoke(Native Method)
at
weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl
.java:717)
at
weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:6
99)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1555)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
at
weblogic.management.internal.RemoteMBeanServerImpl.invoke(RemoteMBeanServerI
mpl.java:921)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:470)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:198)
at $Proxy48.activate(Unknown Source)
at
weblogic.management.console.actions.mbean.ConfigureAppWizardAction.commit(Co
nfigureAppWizardAction.java:248)
at
weblogic.management.console.actions.mbean.ConfigureAppWizardAction.perform(C
onfigureAppWizardAction.java:100)
at
weblogic.management.console.actions.internal.ActionServlet.doAction(ActionSe
rvlet.java:171)
at
weblogic.management.console.actions.internal.ActionServlet.doPost(ActionServ
let.java:85)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(Servle
tStubImpl.java:945)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:332)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:242)
at
weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(W
ebAppServletContext.java:5360)
at
weblogic.security.service.SecurityServiceManager.runAs(SecurityServiceManage
r.java:721)
at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo
ntext.java:3043)
at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java
:2468)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:152)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:133)
tahnks you !
Unimon Thierry
CGBI- CET-E-services
69, Blvd Galliéni
91 Issy les Mlx
tele :01/55/95/54/22 Poste:5422
Port :06/61/81/78/59
Prof : mailto:[email protected]
Pers : mailto:[email protected]oops! Pls ignore my previous mail. It was for a different problem.
FOr the original problem of "couldn ot locate the bean with the ejb-name XZY in weblogic-ejb-jar.xml":
This happens if you don't have the below files defined
for a JAR/EAR file:
weblogic-ejb-jar.xml and weblogic-cmp-rdbms-jar.xml (needed if you have any Datasource mapped)
These two are basic files required for any JAR/EAR file.
If you dont' have it already you can generate them using
$WLS_HOME/bin/startWLBuilder.sh GUI tool bundled along
with WLS (I used 8.1 SP4) to generate these files ! This tool is really helpful.
- Mouli -
Error defining transaction-isolation at weblogic-ejb-jar.xml
Hi,
.. from WebLogic 5.1 reference:
(...) the top level elements in weblogic-ejb-jar.xml are as follows:
. description
. weblogic-version
. weblogic-enterprise-bean
. ejb-name
. caching-descriptor
. presistence-descriptor
. clustering-descriptor
. transaction-descriptor
. reference-descriptor
. enable-call-by-reference
. jndi-name
. TRANSACTION-ISOLATION
. security-role-assignment
this way i've appended a transaction isolation section immediatly after the jndi-name section
from my weblogic-ejb-jar.xml file to specify that all methods of my container-managed ejb
should use read-committed accesses to the database. But i've gotten the error message:
org.xml.sax.SAXParseException: Element "weblogic-enterprise-bean" allows no further input; "transaction-isolation" is not allowed.
during compilation time at parsing. Nowhere else in the weblogic-ejb-jar.xml i can put the
isolation transaction section without receiving some related parsing error. The same happens
trying to include such transaction section at ejb-jar.xml. I'm attaching both xml files. Should
anybody help me saying where that section should be described? And if it should be placed in
another file, why the documentation states for describing it at the weblogic-ejb-jar.xml?
[weblogic-ejb-jar.xml]That means that you do not have the SP6 in the service pack and it is using
the old DTD.
Peace,
Cameron Purdy
Tangosol, Inc.
http://www.tangosol.com
+1.617.623.5782
WebLogic Consulting Available
"Ana Benites" <[email protected]> wrote in message
news:[email protected]...
>
Cameron,
hello.
When you say "<enterprise-bean>" block, you mean"<weblogic-enterprise-bean>"block, isn't it?
>
Because you recommend in your response exactly what i was doing in myweblogic-ejb-jar.xml,
>
that i had attached to my message when openning this discussion. I copyit again here:
>
My weblogic-ejb-jar.xml:
<?xml version="1.0"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic5.1.0 EJB//EN' 'http://www.bea.com/servers/wls510/dtd/weblogic-ejb-jar.dtd'>
>
>
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>cluster.ejb.TellerHome</ejb-name>
<caching-descriptor>
</caching-descriptor>
<enable-call-by-reference>False</enable-call-by-reference>
<jndi-name>cluster.ejb.TellerHome</jndi-name>
<transaction-isolation>
<isolation-level>TRANSACTION_READ_COMMITTED</isolation-level>
>
<method>
<ejb-name>cluster.ejb.TellerHome</ejb-name>
<method-name>*</method-name>
</method>
</transaction-isolation>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
...and this is resulting in the following parsing error during compiletime:
>
>
org.xml.sax.SAXParseException: Element "weblogic-enterprise-bean" allowsno further input; "transaction-isolation" is not allowed.
at com.sun.xml.parser.Parser.error(Parser.java:2775)
atcom.sun.xml.parser.ValidatingParser$ChildrenValidator.consume(ValidatingPars
er.java:306)
at com.sun.xml.parser.Parser.maybeElement(Parser.java:1280)
at com.sun.xml.parser.Parser.content(Parser.java:1498)
at com.sun.xml.parser.Parser.maybeElement(Parser.java:1399)
at com.sun.xml.parser.Parser.content(Parser.java:1498)
at com.sun.xml.parser.Parser.maybeElement(Parser.java:1399)
at com.sun.xml.parser.Parser.parseInternal(Parser.java:491)
at com.sun.xml.parser.Parser.parse(Parser.java:283)
at weblogic.xml.dom.SunDOMParser.getDocument(SunDOMParser.java:69)
at weblogic.xml.dom.DOMParser.getDocument(DOMParser.java:102)
atweblogic.ejb.deployment.dd.DescriptorLoader.<init>(DescriptorLoader.java:157
at weblogic.ejbc.runBody(ejbc.java, Compiled Code)
at weblogic.utils.compiler.Tool.run(Tool.java:80)
at weblogic.ejbc.main(ejbc.java:353)
Am i forgetting anything?
Thanks for your help
Ana.
"Cameron Purdy" <[email protected]> wrote:
Hi Ana,
Add to weblogic-ejb-jar.xml:
Inside each <enterprise-bean> block, add the following immediately before
the block closes:
<transaction-isolation>
<isolation-level>TRANSACTION_READ_COMMITTED</isolation-level>
<method>
<ejb-name></ejb-name>
<method-name>*</method-name>
</method>
</transaction-isolation>
The <ejb-name> value of the <method> block of the <transaction-isolation>
block must match the <ejb-name> value of the <enterprise-bean> block.
Please note the case sensitive nature of the values.
Peace,
Cameron Purdy
Tangosol, Inc.
http://www.tangosol.com
+1.617.623.5782
WebLogic Consulting Available
"Ana Benites" <[email protected]> wrote in message
news:[email protected]...
Thanks for your attention Cameron,
from my WebLogic Console one can read
"WebLogic Build 5.1.0 Service Pack 6 09/20/2000 21:03:19#84511"
...because i was suspecting the problem was due to a lack of
applying
the service pack 6. But even
after that upgrade the parsing errors remain.
regards
Ana
"Cameron Purdy" <[email protected]> wrote:
Ana,
The 5.1 release did NOT support transaction isolation in the
weblogic-ejb-jar.xml file.
That feature was introduced in a service pack. What SP are you using?
Peace,
Cameron Purdy
Tangosol, Inc.
http://www.tangosol.com
+1.617.623.5782
WebLogic Consulting Available
"Ana Benites" <[email protected]> wrote in message
news:[email protected]...
Hi,
.. from WebLogic 5.1 reference:
(...) the top level elements in weblogic-ejb-jar.xml are as follows:
description
weblogic-version
weblogic-enterprise-bean
. ejb-name
. caching-descriptor
. presistence-descriptor
. clustering-descriptor
. transaction-descriptor
. reference-descriptor
. enable-call-by-reference
. jndi-name
. TRANSACTION-ISOLATION
security-role-assignment
this way i've appended a transaction isolation section immediatly
after
the jndi-name section
from my weblogic-ejb-jar.xml file to specify that all methods of mycontainer-managed ejb
should use read-committed accesses to the database. But i've gotten
the
error message:
org.xml.sax.SAXParseException: Element "weblogic-enterprise-bean"
allows
no further input; "transaction-isolation" is not allowed.
during compilation time at parsing. Nowhere else in theweblogic-ejb-jar.xml i can put the
isolation transaction section without receiving some related parsingerror. The same happens
trying to include such transaction section at ejb-jar.xml. I'm
attaching
both xml files. Should
anybody help me saying where that section should be described? And
if
it
should be placed in
another file, why the documentation states for describing it at theweblogic-ejb-jar.xml? -
Invalid weblogic-ejb-jar.xml ??
I have a question about weblogic-ejb-jar.xml file entries.
weblogic 9.1 server says it is invalid while deploying my file
my file is as under,
<?xml version="1.0"?><!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems,
Inc.//DTD WebLogic 8.1.0 EJB//EN'
'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
<weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/910"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/910
http://www.bea.com/ns/weblogic/910/weblogic-ejb-jar.xsd">
<weblogic-enterprise-bean>
<ejb-name>MessageAccess</ejb-name>
<message-driven-descriptor>
<resource-adapter-jndi-name>SystemModule-test</resource-adapter-jndi-name>
</message-driven-descriptor>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
can anybody help what is wrong with it?I used Korean language in comment.
But the charset of XML was iso-8859-1.
Sorry.
"mariah" <[email protected]> wrote:
>
Hi, I am migrating to WebLogic Server 6.1 from 5.1.
And for the weblogic-ejb-jar.xml,
the following error occurs:
ERROR: Error parsing 'META-INF/weblogic-ejb-jar.xml' line 14: An invalid
XML character
(Unicode: 0xb8) was found in the comment.
ERROR: ejbc found errors
The errorneous line is the following comment. (it's fine in 5.1)
<!-- if false, ... -->
Must I remove this comment?
Thanks in advance. -
Weblogic-ejb-jar.xml issues
We here in my development group with FedEX are moving from
Weblogic 8.1.0 to 9.2.1. I am having issues with the weblogic-ejb-jar.xml file as follows:
In the header or whatr ever it is called (I am not a WL admin)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 9.2.0 EJB//EN" "http://www.bea.com/servers/wls921/dtd/weblogic-ejb-jar.dtd">
I have changed the:
//DTD WebLogic 8.1.0 EJB//EN" TO
//DTD WebLogic 9.2.1 EJB//EN"
AND
"http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd"
TO
"http://www.bea.com/servers/wls921/dtd/weblogic-ejb-jar.dtd"
The deployment likes or doesn't grip about:
"http://www.bea.com/servers/wls921/dtd/weblogic-ejb-jar.dtd"
BUT
does not like:
//DTD WebLogic 9.2.1 EJB//EN" says it has to be 8.1.0 or earlier.
I have not been able to find any info on how to solve this problem.
I need 9.2.1 for the : "max-messages-in-transaction" element.
I could really need some help on this.
Thanks
SteveWe here in my development group with FedEX are moving from
Weblogic 8.1.0 to 9.2.1. I am having issues with the weblogic-ejb-jar.xml file as follows:
In the header or whatr ever it is called (I am not a WL admin)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 9.2.0 EJB//EN" "http://www.bea.com/servers/wls921/dtd/weblogic-ejb-jar.dtd">
I have changed the:
//DTD WebLogic 8.1.0 EJB//EN" TO
//DTD WebLogic 9.2.1 EJB//EN"
AND
"http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd"
TO
"http://www.bea.com/servers/wls921/dtd/weblogic-ejb-jar.dtd"
The deployment likes or doesn't grip about:
"http://www.bea.com/servers/wls921/dtd/weblogic-ejb-jar.dtd"
BUT
does not like:
//DTD WebLogic 9.2.1 EJB//EN" says it has to be 8.1.0 or earlier.
I have not been able to find any info on how to solve this problem.
I need 9.2.1 for the : "max-messages-in-transaction" element.
I could really need some help on this.
Thanks
Steve
Maybe you are looking for
-
Generating table of contents by chapter number and title in reports
Hi all, how can i generate a table of contents in reports? I will definitely need the chapter numbers and their respective titles to do that. Are there specific templates to follow in order to do that? Thanks.
-
How to use Sharepoint Modal Popup loader in Sharepoint-Hosted Apps
Hi, I have a requirement to use a modal popup as loader in SharePoint-Hosted Apps. I have used this like following- SP.UI.ModalDialog.showWaitScreenWithNoClose( 'Please Wait', 'while we retrieve...', '400', '600'); But it does not work if we have "SP
-
Simon, why do I get an OrdImage.setProperties() exception ORA-22288
Hi Simon; I've debugged a problem with the ImageExample to the point where I'm convinced one cannot call setProperties indirectly as the example code shows. SetProperties can only be called during a load - for example imgObj.LoadFromFile The example
-
ADF application Deployment error:
Hi I am trying to deploy a working version of our ADF application on to SQA 10.1.3.4 using Jdeveloper 10.1.3.3 the connection for application server is connected successfully with setting: opmn port:6003, host: hofo3sop02ab.domain.com the type of ser
-
How to proportionally scale one side of a photo more than the other?
Does anyone have any suggestions as to how to scale one side of an image more than the other? I've tried Content-Aware scale but it always yields ugly results. Any help is greatly appreciated. Peter