When a thread tries to access a version that's been deleted by another thread, the following may happen:
2015-06-25 14:43:33,004 ERROR [Nuxeo-Work-audit-1] [org.nuxeo.ecm.core.work.AbstractWork] Exception during work: ListenerWork(Listener auditLoggerListener [documentCreated/94d3f91c-5907-4f80-a81c-f1e52129a5f3, documentCheckedIn/94d3f91c-5907-4f80-a81c-f1e52129a5f3, documentCreated/fc9a9a14-e8e3-4df3-9d78-ab7b7f4f328a], Progress(?%, ?/0), null) java.lang.IllegalArgumentException: Illegal null id at org.nuxeo.ecm.core.storage.sql.SessionImpl.getNodeById(SessionImpl.java:603) at org.nuxeo.ecm.core.storage.sql.ra.ConnectionImpl.getNodeById(ConnectionImpl.java:184) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.getNodeById(SQLSession.java:830) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLDocumentVersion.<init>(SQLDocumentVersion.java:47) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.newDocument(SQLSession.java:581) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.newDocument(SQLSession.java:545) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.getDocumentById(SQLSession.java:591) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.getDocumentByUUID(SQLSession.java:209) at org.nuxeo.ecm.core.api.AbstractSession.resolveReference(AbstractSession.java:341) at org.nuxeo.ecm.core.api.AbstractSession.exists(AbstractSession.java:847) at org.nuxeo.ecm.core.event.impl.ReconnectedEventBundleImpl.getReconnectedEvents(ReconnectedEventBundleImpl.java:119) at org.nuxeo.ecm.core.event.impl.ReconnectedEventBundleImpl.iterator(ReconnectedEventBundleImpl.java:220) at org.nuxeo.ecm.platform.audit.service.AbstractAuditBackend.logEvents(AbstractAuditBackend.java:371) at org.nuxeo.ecm.platform.audit.listener.AuditEventLogger.handleEvent(AuditEventLogger.java:56) at org.nuxeo.ecm.core.event.impl.AsyncEventExecutor$ListenerWork.work(AsyncEventExecutor.java:170) at org.nuxeo.ecm.core.work.AbstractWork.runWorkWithTransaction(AbstractWork.java:343) at org.nuxeo.ecm.core.work.AbstractWork.runWorkWithTransactionAndCheckExceptions(AbstractWork.java:304) at org.nuxeo.ecm.core.work.AbstractWork.run(AbstractWork.java:273) at org.nuxeo.ecm.core.work.WorkHolder.run(WorkHolder.java:52) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
This is due to the fact that the thread reads the versions table and gets a NULL entry for the versionableid because it's been deleted and is therefore marked ABSENT in the cache.