There seems to be some debate about whether or not that is really the
case.  At least it has Richard Monson-Haefel (the author of the O'Reilly
EJB book) and Floyd Marinescu (from TheServerSide.com) confused, from
this post to ejb-interest a couple months ago:
http://www.mail-archive.com/[email protected]/msg19000.html

My take:

While section 10.5.2 maked it look like you can leave the PK unset in
ejbCreate and the container will automatically generate a key for you,
the spec doesn't (that I could find) explicitly specify anywhere that
this is in fact the case.  The wording of section 10.5.2 could be
explained by the use of deferred key types, which could conceivably
provide an akward way of making autogenerated PKs, but only in wholly
container-dependent manner.  In the 1.1 spec, it was necessary to set
the PK explicitly in ejbCreate, so some explanation would seem to be in
order... blah.

Jeff Schnitzer
[EMAIL PROTECTED]

> -----Original Message-----
> From: Richard Kirby [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 05, 2001 11:54 PM
> To: Jakarta General List
> Subject: RE: commentary by Linus Torvalds
> 
> 
> EJB2 does allow for automatic generation of "freaking primary 
> keys" - unless
> I misunderstood you. Thats one of the points of having ejbCreate and
> ejbPostCreate. Mind you, I personally feel that Torque offers 
> far more than
> EJB, if you are building from scratch and don't have legacy systems.
> 
> Richard
> [EMAIL PROTECTED]
> 
> > -----Original Message-----
> > From: Jeff Schnitzer [mailto:[EMAIL PROTECTED]]
> > Sent: 06 December 2001 07:28
> > To: Jakarta General List
> > Subject: RE: commentary by Linus Torvalds
> >
> <cut>
> > As a case in point, I would like to point out EJB CMP as an 
> example of
> > "design-driven" technology which may very well look really stupid in
> > another few years, especially given its atrociously slow 
> mutation rate.
> > If anyone who was writing this crap (the spec) was actually 
> *using* it,
> > it would probably allow for automatic generation of freaking primary
> > keys...
> >
> > Jeff Schnitzer
> > [EMAIL PROTECTED]
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: 
> <mailto:[EMAIL PROTECTED]>
> 
> 

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to