Hi,
I'm not sure, if this is a hibernate search problem or a resin server related problem (or my code :o). But currently I'm getting exception "Access a Sealed WorkQueue which has not been sealed", when commiting the transaction. This exception occurs in "PostTransactionWorkQueueSynchronization.afterCompletion", which subsequently calls "queueingProcessor.performWorks", but as the "queueingProcessor.prepareWorks" has never been called, it throws an exception. It seems, that hibernate search registers a new synchronization during "callBeforeCompletion" and it expects, that this synchronization will be called after this "callBeforeCompletion" is finished. At least my version of Resin does not allow this. It does call the "callAfterCompletion", but not the "callBeforeCompletion". The reason is, that Resin uses an ArrayList to store the synchronizations and as it is already traversing the list, it does not call the newly added synchronization. Here is the code from Resin:
private void callBeforeCompletion() throws RollbackException { int length = _syncList == null ? 0 : _syncList.size();
for (int i = 0; i < length; i++) { Synchronization sync = _syncList.get(i);
try { sync.beforeCompletion(); } catch (RuntimeException e) { throw new RollbackException(e); } catch (Throwable e) { log.log(Level.FINE, e.toString(), e); } }
And this is the stack trace:
TransactionImpl.registerSynchronization(Synchronization) line: 513 JTATransaction.registerSynchronization(Synchronization) line: 313 EventSourceTransactionContext.registerSynchronization(Synchronization) line: 56 TransactionalWorker.performWork(Work, TransactionContext) line: 47 FullTextIndexEventListener.processWork(T, Serializable, WorkType, AbstractEvent) line: 128 FullTextIndexEventListener.onPostUpdate(PostUpdateEvent) line: 120 EntityUpdateAction.postUpdate() line: 200 EntityUpdateAction.execute() line: 179 ActionQueue.execute(Executable) line: 279 ActionQueue.executeActions(List) line: 263 ActionQueue.executeActions() line: 168 DefaultFlushEventListener(AbstractFlushingEventListener).performExecutions(EventSource) line: 321 DefaultFlushEventListener.onFlush(FlushEvent) line: 50 SessionImpl.flush() line: 1027 SessionImpl.managedFlush() line: 365 CacheSynchronization.beforeCompletion() line: 88 TransactionImpl.callBeforeCompletion() line: 832 TransactionImpl.commit() line: 564 TransactionManagerImpl.commit() line: 261 UserTransactionImpl.commit() line: 407 UserTransactionProxy.commit() line: 138 JTASupport.commit() line: 73
Is it problem of hibernate search or Resin server? I'm not sure what the specs say... or is it just my code?
|