-
Type: Improvement
-
Status: Open
-
Priority: Minor
-
Resolution: Unresolved
-
Affects Version/s: 5.8.0-HF18, 5.9.4
-
Fix Version/s: QualifiedToSchedule
-
Component/s: Elasticsearch, Workflow
-
Epic Link:
-
Tags:
Same than in NXP-14893: DocumentRoutingEscalationServiceImpl.queryForSuspendedNodesWithEscalation makes a very slow query and fetch.
2014-07-29 06:45:01,301 INFO [Quartz_Worker-1][org.nuxeo.ecm.core.storage.sql.SessionImpl] duration_ms: 1279.99 QueryFilter(principal=system, limit=0, offset=0) queryAndFetch Select DISTINCT ecm:uuid from RouteNode WHERE ecm:currentLifeCycleState = 'suspended' AND ( rnode:escalationRules/*1/executed = 0 OR rnode:escalationRules/*1/multipleExecution = 1 ){}
java.lang.Throwable: Slow query stack trace
at org.nuxeo.ecm.core.storage.sql.SessionImpl.queryAndFetch(SessionImpl.java:1295)
at org.nuxeo.ecm.core.storage.sql.ra.ConnectionImpl.queryAndFetch(ConnectionImpl.java:375)
at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession$SQLSessionQuery.executeAndFetch(SQLSession.java:629)
at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.queryAndFetch(SQLSession.java:546)
at org.nuxeo.ecm.core.api.AbstractSession.queryAndFetch(AbstractSession.java:1676)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.nuxeo.ecm.core.api.TransactionalCoreSessionWrapper.invoke(TransactionalCoreSessionWrapper.java:136)
at com.sun.proxy.$Proxy105.queryAndFetch(Unknown Source)
at org.nuxeo.ecm.platform.routing.core.impl.DocumentRoutingEscalationServiceImpl$1.run(DocumentRoutingEscalationServiceImpl.java:57)
at org.nuxeo.ecm.core.api.UnrestrictedSessionRunner.runUnrestricted(UnrestrictedSessionRunner.java:115)
at org.nuxeo.ecm.platform.routing.core.impl.DocumentRoutingEscalationServiceImpl.queryForSuspendedNodesWithEscalation(DocumentRoutingEscalationServiceImpl.java:54)
at org.nuxeo.ecm.platform.routing.core.listener.DocumentRoutingEscalationListener$1.run(DocumentRoutingEscalationListener.java:64)
at org.nuxeo.ecm.core.api.UnrestrictedSessionRunner.runUnrestricted(UnrestrictedSessionRunner.java:156)
at org.nuxeo.ecm.platform.routing.core.listener.DocumentRoutingEscalationListener.triggerEsclationRulesExecution(DocumentRoutingEscalationListener.java:59)
at org.nuxeo.ecm.platform.routing.core.listener.DocumentRoutingEscalationListener.handleEvent(DocumentRoutingEscalationListener.java:52)
at org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:215)
at org.nuxeo.ecm.core.scheduler.EventJob.execute(EventJob.java:116)
at org.nuxeo.ecm.core.scheduler.EventJob.execute(EventJob.java:59)
at org.quartz.core.JobRunShell.run(JobRunShell.java:223)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:549)
Note there is a clause on a complex property. When supported in Elasticsearch, it will need to be redefined in a page provider that it can be easily directed to ES.
- depends on
-
NXP-14893 Enable TagServiceImpl.UnrestrictedGetDocumentTags.run query alternative
- Resolved