Well, more complicated plus it won't work to specify "no
transaction." :-)

I'm one of the "some people" who complained about the hard-coded
special behavior for methods named getXXX. It's just not that much
of a stretch to imagine a getter method with side-effects. A flag
works for me, as does isModified.

What works best, of course, is an EJB 2.0 persistence manager.
I'm curious if anyone's done some thinking or prototyping.

-Dan

On 9 Oct 00, at 10:59, marc fleury wrote:

> ease of use Aaron,
>
> going and specifying "no transaction" for every getter is more complicated
>
> ease of use + doco >> no ease of use + spec
>
> amrc
>
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]]On Behalf Of Aaron Mulder
> > Sent: Sunday, October 08, 2000 7:45 AM
> > To: jBoss
> > Subject: Re: [jBoss-User] Possible BUG - ejbStore getting called too
> > often?
> >
> >
> >     Well, you could always specify no transaction for your
> > "getters" to avoid this...
> >
> > Aaron
> >
> > On Sun, 8 Oct 2000, Rickard [iso-8859-1] �berg wrote:
> > > Hey
> > >
> > > [EMAIL PROTECTED] wrote:
> > > > For testing, I have a JSP that calls a findAll method on a CMP entity
> > > > bean.  (This will later be moved to a facade pattern for performance)
> > > >  As each object is iterated through, a 'getBulkAccessor' method is
> > > > executed on the entity (it puts together a 'scratchpad' class to hand
> > > > the variables back to the webpage).  The JSP then prints the contents
> > > > of the bulk accessor class.  To track edits in the entities, I have
> > > > added code to ejbStore that updates a 'lastEdited' field with a
> > > > java.sql.Timestamp.  I've noticed that everytime I run this page, that
> > > > ejbStore is getting called (I tested by having it print out to the
> > > > conole whenever it was called), thus the database is getting updated
> > > > everytime I attempt to list the contents.  Can this possibly be the
> > > > correct behavior?
> > >
> > > I had coded special treatment of "get*" methods before which didn't call
> > > store. Some people thought it was unpure, so I removed it :-) Perhaps it
> > > should be put back but with a flag or something. Oh, and we need to add
> > > isModified() support, which would also fix this.
> > >
> > > /Rickard
> > >
> > >
> >
> >
> >
> > --
> > --------------------------------------------------------------
> > To subscribe:        [EMAIL PROTECTED]
> > To unsubscribe:      [EMAIL PROTECTED]
> > Problems?:           [EMAIL PROTECTED]
> >
> >
>
>
>
> --
> --------------------------------------------------------------
> To subscribe:        [EMAIL PROTECTED]
> To unsubscribe:      [EMAIL PROTECTED]
> Problems?:           [EMAIL PROTECTED]
>




--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to