RE: Insert/Update pages and Hibernate

2006-05-04 Thread Jim Steinberger
eally appeciate everyone's help and advice, Jim -Original Message- From: James Carman [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 11:29 AM To: 'Tapestry users' Subject: RE: Insert/Update pages and Hibernate Well, I just posted it to the forum too. ---

RE: Insert/Update pages and Hibernate

2006-05-03 Thread James Carman
Well, I just posted it to the forum too. -Original Message- From: Konstantin Ignatyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 11:27 AM To: Tapestry users Subject: RE: Insert/Update pages and Hibernate HIbernate community practice is to submit issues for filtering in the

RE: Insert/Update pages and Hibernate

2006-05-03 Thread Konstantin Ignatyev
he issue. Thanks. -Original Message- From: Paul Cantrell [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 11:16 AM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate Konstantin's idea of using the domain object itself as an edit buffer is exactly what I'm s

RE: Insert/Update pages and Hibernate

2006-05-03 Thread James Carman
jects/hibernate/browse/HHH-1716 If anyone else would like them to look at it, please vote for the issue. Thanks. -Original Message- From: Paul Cantrell [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 11:16 AM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate Ko

RE: Insert/Update pages and Hibernate

2006-05-03 Thread Konstantin Ignatyev
tyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 10:56 AM To: Tapestry users Subject: RE: Insert/Update pages and Hibernate Do not think this is a 'bug'. SaveOrUpdate is a 'convenience' feature and if different strategy is necessary then it can be implemented /easily/ in

Re: Insert/Update pages and Hibernate

2006-05-03 Thread Paul Cantrell
k/src/test/ com/carm anconsulting/tapernate/util/SessionFactoryFactory.java It prints out "The id is 1." -Original Message- From: Konstantin Ignatyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 10:56 AM To: Tapestry users Subject: RE: Insert/Update pages and Hibernate Do not think this

RE: Insert/Update pages and Hibernate

2006-05-03 Thread James Carman
rnate/util/SessionFactoryFactory.java It prints out "The id is 1." -Original Message- From: Konstantin Ignatyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 10:56 AM To: Tapestry users Subject: RE: Insert/Update pages and Hibernate Do not think this is a 

RE: Insert/Update pages and Hibernate

2006-05-03 Thread Konstantin Ignatyev
ugh all of the scenarios as I'm sure they did. Has anyone filed a Jira issue with the Hibernate folks about this to get some clarification? -Original Message- From: Konstantin Ignatyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 10:45 AM To: Tapestry users Subject: RE: Inse

RE: Insert/Update pages and Hibernate

2006-05-03 Thread James Carman
ssue with the Hibernate folks about this to get some clarification? -Original Message- From: Konstantin Ignatyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 10:45 AM To: Tapestry users Subject: RE: Insert/Update pages and Hibernate Object itself could be such a buffer (or ra

RE: Insert/Update pages and Hibernate

2006-05-03 Thread Konstantin Ignatyev
AM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate FYI: there is no need to 'maintain' ActionForm in Struts unless you need to, this is the common mistake. Business object can be placed in the ActionForm as one field and its properties accessed and set in OGNL like fashion

RE: Insert/Update pages and Hibernate

2006-05-03 Thread James Carman
ally in the database). So, they're trying to come up with a "buffer" to avoid such a situation. -Original Message- From: Konstantin Iignatyev [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 03, 2006 1:38 AM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate

Re: Insert/Update pages and Hibernate

2006-05-02 Thread Konstantin Iignatyev
ealing with a persistence mechanism that can potentially leave objects in an indeterminate state. Thanks again, Jim -Original Message- From: Paul Cantrell [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 02, 2006 10:09 PM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate Ji

Re: Insert/Update pages and Hibernate

2006-05-02 Thread Paul Cantrell
ROTECTED] Sent: Tuesday, May 02, 2006 10:09 PM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate Jim -- My suggestion would be to keep all the user-entered values around in an object that's not the manufacturer, but is solely a value object that is very specific to th

RE: Insert/Update pages and Hibernate

2006-05-02 Thread Jim Steinberger
dealing with a persistence mechanism that can potentially leave objects in an indeterminate state. Thanks again, Jim -Original Message- From: Paul Cantrell [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 02, 2006 10:09 PM To: Tapestry users Subject: Re: Insert/Update pages and Hibern

Re: Insert/Update pages and Hibernate

2006-05-02 Thread Paul Cantrell
an API that could potentially mutate them, since I need to keep the original data around (the user input). But I've never seen anyone doing this, so I'm asking about this situation here because either I'm missing something or a lot of other people are. Jim -----Original

RE: Insert/Update pages and Hibernate

2006-05-02 Thread Jim Steinberger
I should add that I'm using Hibernate 3.1.3 and the service method is ultimately calling Spring's (v 1.2.7) HibernateTemplate.save(...) to perform the insert. Jim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional comman

RE: Insert/Update pages and Hibernate

2006-05-02 Thread Jim Steinberger
101 [EMAIL PROTECTED] -Original Message- From: James Carman [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 02, 2006 8:18 PM To: 'Tapestry users' Subject: RE: Insert/Update pages and Hibernate Jim, Oooh! That's nasty and I was unaware of the issue (assigning a primary key

RE: Insert/Update pages and Hibernate

2006-05-02 Thread James Carman
action and maybe try to figure out how to code around it)? Thanks, James -Original Message- From: Jim Steinberger [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 02, 2006 8:16 PM To: Tapestry users Subject: RE: Insert/Update pages and Hibernate Paul, Thanks much -- I take your points w

RE: Insert/Update pages and Hibernate

2006-05-02 Thread James Carman
an be helpful to you. -Original Message- From: Paul Cantrell [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 02, 2006 7:12 PM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate There are several practices you can use to avoid painting yourself into this corner: (1) Probably t

RE: Insert/Update pages and Hibernate

2006-05-02 Thread Jim Steinberger
al Message- From: Paul Cantrell [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 02, 2006 7:12 PM To: Tapestry users Subject: Re: Insert/Update pages and Hibernate There are several practices you can use to avoid painting yourself into this corner: (1) Probably the best and simplest: Use a str

Re: Insert/Update pages and Hibernate

2006-05-02 Thread Paul Cantrell
There are several practices you can use to avoid painting yourself into this corner: (1) Probably the best and simplest: Use a straightforward transaction- per-request model, and don't ever hold on to persistent objects between requests.* Instead, hold on to the IDs of your persistent obj

Insert/Update pages and Hibernate

2006-05-02 Thread Jim Steinberger
In Tapestry, we use model objects as the data-buffer. If we're editing an entity, and something goes wrong, we can set an errorMessage property, "return this;", and expect the user to see the form still filled-out with what they'd just typed with an explanation of what went wrong. If you're u