Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 453186 - CRUD operations in GenericHibernateDAO should not flush, clear, commit the session
Summary: CRUD operations in GenericHibernateDAO should not flush, clear, commit the se...
Alias: None
Product: JBoss Customer Support Portal
Classification: Retired
Component: Web-General
Version: 1.3.9
Hardware: All
OS: All
Target Milestone: ---
: ---
Assignee: Nathan Lugert
QA Contact: David Spalding
Depends On:
Blocks: HibernateIssues
TreeView+ depends on / blocked
Reported: 2008-06-27 18:45 UTC by John Sanda
Modified: 2015-01-20 00:10 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2011-01-05 18:34:44 UTC
Type: ---

Attachments (Terms of Use)

Description John Sanda 2008-06-27 18:45:36 UTC
Description of problem:
We have methods in GenericHibernateDAO that flush the session and commit the
transaction. It has explained to me that this was implemented to deal with
NonUniqueObjectExceptions that were getting thrown. I was told that this was (at
least in part) a problem because of the DTOs used with the SalesForces web services.

The Hibernate Session provides a merge operation to address exactly these types
of situations that result in NonUniqueObjectExceptions. In fact, merge() should
be preferred over saveOrUpdate().

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
Actual results:

Expected results:

Additional info:

Comment 1 David Spalding 2011-01-05 18:34:44 UTC
Superceded by Avalon. This component is no longer valid.

Note You need to log in before you can comment on or make changes to this bug.