*
The moose likes EJB and other Java EE Technologies and the fly likes Entity EJB & env-entry problem with WebLogic7 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Entity EJB & env-entry problem with WebLogic7" Watch "Entity EJB & env-entry problem with WebLogic7" New topic
Author

Entity EJB & env-entry problem with WebLogic7

Franck Tranchant
Ranch Hand

Joined: Aug 07, 2003
Posts: 75
Hi there
This is my first post here
I've got some problems with the environment entries of an entity EJB.
Actually, i coudn't find the way to set them up right into the description file (ejb-jar.xml)
According to the "EJB deployment descriptor reference", <env-entry> can be used in both Entity & Session EJB but when i try to deploy with the following ejb-jar.xml :

WebLogic7.0 throw a parsing error and says that is not a valid tag according to the DTD....
As a consequence, i'm forced to edit by hand the descriptor using the WebLogic Console
This is working fine but this is pretty time consuming since my EJB is currently under development and i have to deploy/re-deploy quite often....
Any idea ?
Many thanx in advance


Franck<p>--------------------
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
security-identity should come after env-entry according to the ejb-jar.xml's DTD document...


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Karthik Guru
Ranch Hand

Joined: Mar 06, 2001
Posts: 1209
Originally posted by Lasse Koskela:
security-identity should come after env-entry according to the ejb-jar.xml's DTD document...

are you sure? it kind of sounds strange that an env-entry *must* be accompanied/followed by a security-identity element. I mean am kind of wondering as to how c'd they be linked. Is'nt it optional?
Pradeep bhatt
Ranch Hand

Joined: Feb 27, 2002
Posts: 8919

Lasse is right.
<!ELEMENT entity (description?, display-name?, small-icon?,
large-icon?, ejb-name, home?, remote?, local-home?,
local?, ejb-class, persistence-type, prim-key-class,
reentrant, cmp-version?, abstract-schema-name?,
cmp-field*, primkey-field?, env-entry*, ejb-ref*,
ejb-local-ref*, security-role-ref*, security-identity?,
resource-ref*, resource-env-ref*, query*)>

Env entry is optional.


Groovy
Franck Tranchant
Ranch Hand

Joined: Aug 07, 2003
Posts: 75
Right !
Putting the <env-entry> between <primkey-field> and <security-identity> works perfectly.
Thank you guys
Karthik Guru
Ranch Hand

Joined: Mar 06, 2001
Posts: 1209
Originally posted by Franck Tranchant:
Right !
Putting the <env-entry> between <primkey-field> and <security-identity> works perfectly.
Thank you guys

oops! am sorry. I did'nt notice that you are using a security-indentity element as well. Otherwise, I guess, even the security-indentity element is optional.
 
wood burning stoves
 
subject: Entity EJB & env-entry problem with WebLogic7