org.hibernate.AssertionFailure

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • The interaction with a hibernate session and sessions created within a validator do not work together. For example, here is a test case: {code} @Test public void jobSeekersCanSaveAPreviousResumeWithTheSameName() { JobSeekerResume resume = ( JobSeekerResume ) resumeDao.find( 1 ); resume.setDescription( "new desc." ); resumeDao.save( resume ); flush(); jdbcMap = simpleJdbcTemplate.queryForMap( "select * from resume where resume_id = ?", resume.getId() ); assertEquals( resume.getDescription(), jdbcMap.get( "DESCRIPTION" ) ); } {code} the flush() method creates an exception: {code} ERROR AssertionFailure:45 - an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection [jawbs.domain.jobseeker.JobSeeker.categories] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1028) at jawbs.DatabaseTests.flush(DatabaseTests.java:113) {code} Obviously hibernate core is saying this could be a bug, or it could be unsafe. Now, the reason this happens is because JobSeekerResume has a contraint that accesses the hibernate session. Now, I have many, many constraints that use this constraint and they work fine. This is the only test that is causing problems for me, and I don't have a clue why. Nonetheless, I'm going to give you a lot of code. Here is the constraint annotation on JobSeekerResume: {code} @QueryConstraint( hql = "select count(*) from JobSeekerResume where name = :name and id != :id and jobSeeker.id = :jobSeeker.id", message = "{jobSeekerResume.name.unique}", enabled = true ) {code} And here is the code for the validator implementation: {code} public class QueryConstraintValidator extends ValidatorSupport<QueryConstraint,DomainObject> { /* Fields */ private String hql; private boolean enabled; /* Services */ public void initialize( QueryConstraint queryConstraint ) { this.hql = queryConstraint.hql(); this.enabled = queryConstraint.enabled(); } public boolean isValid( DomainObject domainObject ) { return isValid( domainObject, null ); } @Override protected boolean preValidate() { return !enabled; } protected boolean testQuery( Session session, DomainObject domainObject ) { logger.debug( "Enabled - Validating constraint with: " ); logger.debug( hql ); Query query = session.createQuery( HqlParser.removePeriodsFromParameterNames( hql ) ); BeanWrapper beanWrapper = new BeanWrapperImpl( domainObject ); for( String parameterName : HqlParser.getParameterNames( hql ) ) { query.setParameter( HqlParser.removePeriodsFromParameterName( parameterName ), beanWrapper.getPropertyValue( parameterName ) ); } boolean result = (Long) query.uniqueResult() == 0; logger.debug( "isValid is returning: " + result ); return result; } ... } {code} The support constraint (the important one most likely) is as follows: {code} public abstract class ValidatorSupport<T extends Annotation,U> implements ConstraintValidator<T,U> { /* Fields */ protected static Logger logger = LoggerFactory.getLogger( QueryConstraintValidator.class ); /* Services */ public boolean isValid( U object, ConstraintValidatorContext constraintValidatorContext ) { if( preValidate() ) { return true; } SessionFactory sessionFactory = ( SessionFactory ) ApplicationContextProvider.getBean( "sessionFactory" ); if( sessionFactory != null ) { Session session = sessionFactory.openSession(); Transaction tx = session.beginTransaction(); boolean result = testQuery( session, object ); tx.commit(); session.close(); return result; } return true; } protected boolean preValidate() { return false; } protected abstract boolean testQuery( Session session, U object ); } {code} Lastly, here is the mapping of the JobSeeker subclass: {code} <subclass name="jawbs.domain.jobseeker.JobSeeker" discriminator-value="ROLE_JOBSEEKER"> <property name="isPrivate" column="is_private" /> <bag name="categories" table="job_seeker_to_category" cascade="all-delete-orphan" inverse="true"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.Category" column="category_id"/> </bag> <bag name="watchedJobs" table="job_seeker_to_watched_job" cascade="all-delete-orphan" inverse="true"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.job.Job" column="watched_job_id"/> </bag> <bag name="applications" table="candidate" cascade="all-delete-orphan" inverse="true"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.candidate.Candidate" column="candidate_id"/> </bag> <bag name="blacklistedEmployers" table="job_seeker_to_blacklisted_employer"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.employer.Employer" column="blacklisted_employer_id"/> </bag> <bag name="resumes" table="resume" inverse="true" cascade="all-delete-orphan"> <key column="job_seeker_id"/> <one-to-many class="jawbs.domain.resume.Resume" /> </bag> </subclass> {code} And here is the mapping of the subclass of resume: {code} <subclass name="jawbs.domain.resume.JobSeekerResume" discriminator-value="JOBSEEKER"> <many-to-one name="jobSeeker" class="jawbs.domain.jobseeker.JobSeeker" column="job_seeker_id" /> </subclass> {code} If you need any more assistance, please let me know. This is a critical blocker to getting a test to pass, this is most likely 100% fine. Thanks
    via by Ken Egervari,
  • The interaction with a hibernate session and sessions created within a validator do not work together. For example, here is a test case: {code} @Test public void jobSeekersCanSaveAPreviousResumeWithTheSameName() { JobSeekerResume resume = ( JobSeekerResume ) resumeDao.find( 1 ); resume.setDescription( "new desc." ); resumeDao.save( resume ); flush(); jdbcMap = simpleJdbcTemplate.queryForMap( "select * from resume where resume_id = ?", resume.getId() ); assertEquals( resume.getDescription(), jdbcMap.get( "DESCRIPTION" ) ); } {code} the flush() method creates an exception: {code} ERROR AssertionFailure:45 - an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection [jawbs.domain.jobseeker.JobSeeker.categories] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1028) at jawbs.DatabaseTests.flush(DatabaseTests.java:113) {code} Obviously hibernate core is saying this could be a bug, or it could be unsafe. Now, the reason this happens is because JobSeekerResume has a contraint that accesses the hibernate session. Now, I have many, many constraints that use this constraint and they work fine. This is the only test that is causing problems for me, and I don't have a clue why. Nonetheless, I'm going to give you a lot of code. Here is the constraint annotation on JobSeekerResume: {code} @QueryConstraint( hql = "select count(*) from JobSeekerResume where name = :name and id != :id and jobSeeker.id = :jobSeeker.id", message = "{jobSeekerResume.name.unique}", enabled = true ) {code} And here is the code for the validator implementation: {code} public class QueryConstraintValidator extends ValidatorSupport<QueryConstraint,DomainObject> { /* Fields */ private String hql; private boolean enabled; /* Services */ public void initialize( QueryConstraint queryConstraint ) { this.hql = queryConstraint.hql(); this.enabled = queryConstraint.enabled(); } public boolean isValid( DomainObject domainObject ) { return isValid( domainObject, null ); } @Override protected boolean preValidate() { return !enabled; } protected boolean testQuery( Session session, DomainObject domainObject ) { logger.debug( "Enabled - Validating constraint with: " ); logger.debug( hql ); Query query = session.createQuery( HqlParser.removePeriodsFromParameterNames( hql ) ); BeanWrapper beanWrapper = new BeanWrapperImpl( domainObject ); for( String parameterName : HqlParser.getParameterNames( hql ) ) { query.setParameter( HqlParser.removePeriodsFromParameterName( parameterName ), beanWrapper.getPropertyValue( parameterName ) ); } boolean result = (Long) query.uniqueResult() == 0; logger.debug( "isValid is returning: " + result ); return result; } ... } {code} The support constraint (the important one most likely) is as follows: {code} public abstract class ValidatorSupport<T extends Annotation,U> implements ConstraintValidator<T,U> { /* Fields */ protected static Logger logger = LoggerFactory.getLogger( QueryConstraintValidator.class ); /* Services */ public boolean isValid( U object, ConstraintValidatorContext constraintValidatorContext ) { if( preValidate() ) { return true; } SessionFactory sessionFactory = ( SessionFactory ) ApplicationContextProvider.getBean( "sessionFactory" ); if( sessionFactory != null ) { Session session = sessionFactory.openSession(); Transaction tx = session.beginTransaction(); boolean result = testQuery( session, object ); tx.commit(); session.close(); return result; } return true; } protected boolean preValidate() { return false; } protected abstract boolean testQuery( Session session, U object ); } {code} Lastly, here is the mapping of the JobSeeker subclass: {code} <subclass name="jawbs.domain.jobseeker.JobSeeker" discriminator-value="ROLE_JOBSEEKER"> <property name="isPrivate" column="is_private" /> <bag name="categories" table="job_seeker_to_category" cascade="all-delete-orphan" inverse="true"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.Category" column="category_id"/> </bag> <bag name="watchedJobs" table="job_seeker_to_watched_job" cascade="all-delete-orphan" inverse="true"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.job.Job" column="watched_job_id"/> </bag> <bag name="applications" table="candidate" cascade="all-delete-orphan" inverse="true"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.candidate.Candidate" column="candidate_id"/> </bag> <bag name="blacklistedEmployers" table="job_seeker_to_blacklisted_employer"> <key column="job_seeker_id"/> <many-to-many class="jawbs.domain.employer.Employer" column="blacklisted_employer_id"/> </bag> <bag name="resumes" table="resume" inverse="true" cascade="all-delete-orphan"> <key column="job_seeker_id"/> <one-to-many class="jawbs.domain.resume.Resume" /> </bag> </subclass> {code} And here is the mapping of the subclass of resume: {code} <subclass name="jawbs.domain.resume.JobSeekerResume" discriminator-value="JOBSEEKER"> <many-to-one name="jobSeeker" class="jawbs.domain.jobseeker.JobSeeker" column="job_seeker_id" /> </subclass> {code} If you need any more assistance, please let me know. This is a critical blocker to getting a test to pass, this is most likely 100% fine. Thanks
    via by Ken Egervari,
  • I'm getting a weird error that only occurs when the bean validation event listener is being activated. If I remove the constraint annotation, I don't have a problem - the test passes. This is the exception I get: ERROR AssertionFailure:45 - an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection [jawbs.domain.jobseeker.JobSeeker.watchedJobs] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1028) at jawbs.DatabaseTests.flush(DatabaseTests.java:89) Here is the code that causes the exception - at the call to sessionFactory.getCurrentSession().flush() (which just happens to be flush() in this test method). @Test public void jobSeekersCanSaveAPreviousResumeWithTheSameName() { JobSeekerResume resume = ( JobSeekerResume ) resumeDao.find( 1 ); resume.setDescription( "new desc." ); resumeDao.save( resume ); flush(); jdbcMap = simpleJdbcTemplate.queryForMap( "select * from resume where resume_id = ?", resume.getId() ); assertEquals( resume.getDescription(), jdbcMap.get( "DESCRIPTION" ) ); } I don't think the mappings are really that important. Basically, "JobSeekerResume" contains a "JobSeeker", and JobSeeker contains many collections. Every time I run the test, I randomly get this error for any of the collections within the JobSeeker object. In the exception above, it just happened to be the "watchedJobs" collection property. It changes every time I run the test. Now, the reason this problem is happening is that my constraint also hits the database. The constraint asks the sessionFactory to open a session, start a transaction, execute a query, close the transaction and then finally close the session. I've also tried it with a StatelessSession instead, but the same problem persists. Here is the query: select count(*) from JobSeekerResume where name = :name and id != :id and jobSeeker.id = :jobSeekerId Here is the constraint code: public boolean isValid( DomainObject domainObject, ConstraintValidatorContext context ) { BeanWrapper beanWrapper = new BeanWrapperImpl( domainObject ); SessionFactory sessionFactory = ( SessionFactory ) ApplicationContextProvider.getBean( "sessionFactory" ); if( enabled && sessionFactory != null ) { logger.debug( "Enabled - Validating constraint with: " ); logger.debug( hql ); StatelessSession session = sessionFactory.openStatelessSession(); Transaction tx = session.beginTransaction(); Query query = session.createQuery( HqlParser.removePeriodsFromParameterNames( hql ) ); for( String parameterName : HqlParser.getParameterNames( hql ) ) { query.setParameter( HqlParser.removePeriodsFromParameterName( parameterName ), beanWrapper.getPropertyValue( parameterName ) ); } boolean result = (Long) query.uniqueResult() == 0; logger.debug( "isValid is returning: " + result ); tx.commit(); session.close(); return result; } return true; } Now, this query is 100% fine in isolation... and by using logging information, everything is working - the query, the sessions are getting closed, etc. as well. It is curious though that if I disable this constraint, the test passes. With this constraint... it does not. Is this a problem with my constraint? With the bean validation event listener? I'd appreciate any help... and if it is a bug, that it gets fixed. Thank you.
    via by Ken Egervari,
  • I'm getting a weird error that only occurs when the bean validation event listener is being activated. If I remove the constraint annotation, I don't have a problem - the test passes. This is the exception I get: ERROR AssertionFailure:45 - an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection [jawbs.domain.jobseeker.JobSeeker.watchedJobs] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1028) at jawbs.DatabaseTests.flush(DatabaseTests.java:89) Here is the code that causes the exception - at the call to sessionFactory.getCurrentSession().flush() (which just happens to be flush() in this test method). @Test public void jobSeekersCanSaveAPreviousResumeWithTheSameName() { JobSeekerResume resume = ( JobSeekerResume ) resumeDao.find( 1 ); resume.setDescription( "new desc." ); resumeDao.save( resume ); flush(); jdbcMap = simpleJdbcTemplate.queryForMap( "select * from resume where resume_id = ?", resume.getId() ); assertEquals( resume.getDescription(), jdbcMap.get( "DESCRIPTION" ) ); } I don't think the mappings are really that important. Basically, "JobSeekerResume" contains a "JobSeeker", and JobSeeker contains many collections. Every time I run the test, I randomly get this error for any of the collections within the JobSeeker object. In the exception above, it just happened to be the "watchedJobs" collection property. It changes every time I run the test. Now, the reason this problem is happening is that my constraint also hits the database. The constraint asks the sessionFactory to open a session, start a transaction, execute a query, close the transaction and then finally close the session. I've also tried it with a StatelessSession instead, but the same problem persists. Here is the query: select count(*) from JobSeekerResume where name = :name and id != :id and jobSeeker.id = :jobSeekerId Here is the constraint code: public boolean isValid( DomainObject domainObject, ConstraintValidatorContext context ) { BeanWrapper beanWrapper = new BeanWrapperImpl( domainObject ); SessionFactory sessionFactory = ( SessionFactory ) ApplicationContextProvider.getBean( "sessionFactory" ); if( enabled && sessionFactory != null ) { logger.debug( "Enabled - Validating constraint with: " ); logger.debug( hql ); StatelessSession session = sessionFactory.openStatelessSession(); Transaction tx = session.beginTransaction(); Query query = session.createQuery( HqlParser.removePeriodsFromParameterNames( hql ) ); for( String parameterName : HqlParser.getParameterNames( hql ) ) { query.setParameter( HqlParser.removePeriodsFromParameterName( parameterName ), beanWrapper.getPropertyValue( parameterName ) ); } boolean result = (Long) query.uniqueResult() == 0; logger.debug( "isValid is returning: " + result ); tx.commit(); session.close(); return result; } return true; } Now, this query is 100% fine in isolation... and by using logging information, everything is working - the query, the sessions are getting closed, etc. as well. It is curious though that if I disable this constraint, the test passes. With this constraint... it does not. Is this a problem with my constraint? With the bean validation event listener? I'd appreciate any help... and if it is a bug, that it gets fixed. Thank you.
    via by Ken Egervari,
  • The problem occurs when insert or update listener is created on hibernate session on model with many-to-many collection and listener is making some queries with this model. The listener is needed for checking data integrity , so I need to make some select clauses within this listener. That is my code from PreInsertEventListener.onPreInsert() method (some lines were removed for clearance) : //I set this on FlushMode.NEVER because StackOverflowError is thrown event.getSession().setFlushMode(FlushMode.NEVER); // Function below makes database query using criteria API String o = listener.validate(event.getEntity(),event.getSession()); if (o != null) { // I don't know if this is correct, but why not?? I don't catch this exception in my code and I have auto_close_session and auto_flush_session on true throw new ConstraintViolationException(o,null,null); } // set to default settings event.getSession().setFlushMode(FlushMode.AUTO); That's exception from my WebLogic 8.1 server <2005-05-05 18:05:15 CEST> <Error> <org.hibernate.AssertionFailure> <000000> <an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:144) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:305) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:678) at pl.softbank.cepik.modris.common.client.util.DefaultModrisClient.updateObject(DefaultModrisClient.java:196) at pl.softbank.cepik.modris.dict.common.client.CommonDictModrisClient.insert(CommonDictModrisClient.java:71)
    via by Tom Kucharski,
  • The problem occurs when insert or update listener is created on hibernate session on model with many-to-many collection and listener is making some queries with this model. The listener is needed for checking data integrity , so I need to make some select clauses within this listener. That is my code from PreInsertEventListener.onPreInsert() method (some lines were removed for clearance) : //I set this on FlushMode.NEVER because StackOverflowError is thrown event.getSession().setFlushMode(FlushMode.NEVER); // Function below makes database query using criteria API String o = listener.validate(event.getEntity(),event.getSession()); if (o != null) { // I don't know if this is correct, but why not?? I don't catch this exception in my code and I have auto_close_session and auto_flush_session on true throw new ConstraintViolationException(o,null,null); } // set to default settings event.getSession().setFlushMode(FlushMode.AUTO); That's exception from my WebLogic 8.1 server <2005-05-05 18:05:15 CEST> <Error> <org.hibernate.AssertionFailure> <000000> <an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:144) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:305) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:678) at pl.softbank.cepik.modris.common.client.util.DefaultModrisClient.updateObject(DefaultModrisClient.java:196) at pl.softbank.cepik.modris.dict.common.client.CommonDictModrisClient.insert(CommonDictModrisClient.java:71)
    via by Tom Kucharski,
  • We've started to notice the following exceptions being triggered from Hibernate 3.5.0-SNAPSHOT (built locally), but only under certain circumstances (editing a specific user, whilst being logged into the application as a specific user). After stepping through both our application and hibernate through the whole update/commit process being run, I can't find anything that would be causing this problem. During processing, I see calls to org.hibernate.engine.Collections#prepareCollectionForUpdate for CollectionEntry[smx3.schema.PartyRole.agreementsFrom#2006094] (and other elements in the same collection) which is listed in the trace below. The collection which triggers the exception isn't consistently the same one, but seems to be localized to 4-5 different collections, I've also noticed that if I single-stepping through the process, if sometimes completes fine, which may indicate some race conditions somewhere. As I'm not entirely sure why the exception is being thrown, I'm not sure if this is a problem with Hibernate, or something wrong in our application somewhere. Is there anyway I can identify why a collection entry wouldn't have been processed (and what does "processed" actually mean?). 24.04.2009 15:57:33.180 *ERROR* [btpool0-1] org.hibernate.AssertionFailure an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session) org.hibernate.AssertionFailure: collection [smx3.schema.PartyRole.agreementsFrom] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1031) at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:369) at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:88) at com.atomikos.icatch.jta.Sync2Sync.beforeCompletion(Sync2Sync.java:73) at com.atomikos.icatch.imp.TransactionStateHandler.commit(TransactionStateHandler.java:253) at com.atomikos.icatch.imp.CompositeTransactionImp.doCommit(CompositeTransactionImp.java:509) at com.atomikos.icatch.imp.CompositeTerminatorImp.commit(CompositeTerminatorImp.java:138) at com.atomikos.icatch.jta.TransactionImp.commit(TransactionImp.java:297) at com.atomikos.icatch.jta.TransactionManagerImp.commit(TransactionManagerImp.java:608) at com.atomikos.icatch.jta.UserTransactionManager.commit(UserTransactionManager.java:148) at smx3.envers.TransactionFilter.afterHandle(TransactionFilter.java:242) at org.restlet.Filter.handle(Filter.java:197) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at com.noelios.restlet.StatusFilter.doHandle(StatusFilter.java:130) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at com.noelios.restlet.application.ApplicationHelper.handle(ApplicationHelper.java:112) at org.restlet.Application.handle(Application.java:341) at org.restlet.ext.wadl.WadlApplication.handle(WadlApplication.java:705) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at org.restlet.Component.handle(Component.java:673) at org.restlet.Server.handle(Server.java:331) at com.noelios.restlet.ServerHelper.handle(ServerHelper.java:68) at com.noelios.restlet.http.HttpServerHelper.handle(HttpServerHelper.java:147) at com.noelios.restlet.ext.servlet.ServerServlet.service(ServerServlet.java:881) at nz.co.smx.rest.RestActivator$RestActivatorClassLoaderServlet.service(RestActivator.java:182) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:362) at org.ops4j.pax.web.service.internal.HttpServiceServletHandler.handle(HttpServiceServletHandler.java:51) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:722) at org.ops4j.pax.web.service.internal.HttpServiceContext.handle(HttpServiceContext.java:87) at org.ops4j.pax.web.service.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:63) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:324) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:842) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:648) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380) at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:450) 24.04.2009 15:57:33.183 *WARN* [btpool0-1] atomikos Unexpected error in beforeCompletion: org.hibernate.AssertionFailure: collection [smx3.schema.PartyRole.agreementsFrom] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1031) at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:369) at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:88) at com.atomikos.icatch.jta.Sync2Sync.beforeCompletion(Sync2Sync.java:73) at com.atomikos.icatch.imp.TransactionStateHandler.commit(TransactionStateHandler.java:253) at com.atomikos.icatch.imp.CompositeTransactionImp.doCommit(CompositeTransactionImp.java:509) at com.atomikos.icatch.imp.CompositeTerminatorImp.commit(CompositeTerminatorImp.java:138) at com.atomikos.icatch.jta.TransactionImp.commit(TransactionImp.java:297) at com.atomikos.icatch.jta.TransactionManagerImp.commit(TransactionManagerImp.java:608) at com.atomikos.icatch.jta.UserTransactionManager.commit(UserTransactionManager.java:148) at smx3.envers.TransactionFilter.afterHandle(TransactionFilter.java:242) at org.restlet.Filter.handle(Filter.java:197) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at com.noelios.restlet.StatusFilter.doHandle(StatusFilter.java:130) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at com.noelios.restlet.application.ApplicationHelper.handle(ApplicationHelper.java:112) at org.restlet.Application.handle(Application.java:341) at org.restlet.ext.wadl.WadlApplication.handle(WadlApplication.java:705) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at org.restlet.Component.handle(Component.java:673) at org.restlet.Server.handle(Server.java:331) at com.noelios.restlet.ServerHelper.handle(ServerHelper.java:68) at com.noelios.restlet.http.HttpServerHelper.handle(HttpServerHelper.java:147) at com.noelios.restlet.ext.servlet.ServerServlet.service(ServerServlet.java:881) at nz.co.smx.rest.RestActivator$RestActivatorClassLoaderServlet.service(RestActivator.java:182) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:362) at org.ops4j.pax.web.service.internal.HttpServiceServletHandler.handle(HttpServiceServletHandler.java:51) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:722) at org.ops4j.pax.web.service.internal.HttpServiceContext.handle(HttpServiceContext.java:87) at org.ops4j.pax.web.service.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:63) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:324) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:842) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:648) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380) at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:450)
    via by Mark Derricutt,
    • org.hibernate.AssertionFailure: collection [jawbs.domain.jobseeker.JobSeeker.categories] was not processed by flush() at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:228) at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:356) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1028) at jawbs.DatabaseTests.flush(DatabaseTests.java:113)

    Users with the same issue

    musketyr
    4 times, last one,