Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-136599

Workflow Metrics - Stopwatch is stopped error

    Details

    • Flagged:
      Impediment
    • Fix Priority:
      4

      Description

      Steps to reproduce

      1. Go to Control Panel > Workflow > Metrics
      2. Select the Single Approver process
      3. Add a SLA (you can go to ⋮> SLA Settings then the + button)
      4. Give the SLA a name X
      5. Choose "Process Begins" as Start;
      6. Choose "Enters Task: Review" as Stop
      7. Fill the Hours field with 00:01 (one minute)
      8. Go to Control Panel > Workflow > Process Builder
      9. Click on the Configuration tab
      10. Edit the Blogs Entry row, choose Single Approver and Save
      11. Go to Site menu > Content & Data > Blogs
      12. Author a blog entry named B1 and submit for publication
      13. In your personal menu (top right of the screen, with the user icon), go to My Workflow Tasks
      14. Choose the "Assigned to My Roles" tab
      15. Find the blog post submission B1 and use the ⋮menu to click on "Assign to Me"
        1. Leave the comment blank on the popup that appears and click Done
      16. Wait 1 minute

      Expected result

      Nothing happens in the logs 

      Actual result

      The following stacktrace can be seen in the logs:

      2021-07-29 18:39:27.244 ERROR [liferay/background_task-1][BackgroundTaskMessageListener:182] Unable to execute background task
       java.lang.IllegalStateException: Stopwatch is stopped
       at com.liferay.portal.workflow.metrics.internal.sla.processor.WorkflowMetricsSLAStopwatch.run(WorkflowMetricsSLAStopwatch.java:80)
       at com.liferay.portal.workflow.metrics.internal.sla.processor.WorkflowMetricsSLAProcessor._createWorkflowMetricsSLAStopwatch(WorkflowMetricsSLAProcessor.java:458)
       at com.liferay.portal.workflow.metrics.internal.sla.processor.WorkflowMetricsSLAProcessor.process(WorkflowMetricsSLAProcessor.java:111)
       at com.liferay.portal.workflow.metrics.internal.background.task.WorkflowMetricsSLAProcessBackgroundTaskExecutor.lambda$_processRunningInstances$11(WorkflowMetricsSLAProcessBackgroundTaskExecutor.java:437)
       at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
       at java.util.HashMap$EntrySpliterator.forEachRemaining(HashMap.java:1699)
       at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
       at java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290)
       at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731)
       at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
       at java.util.concurrent.ForkJoinTask.doInvoke(ForkJoinTask.java:401)
       at java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:734)
       at java.util.stream.ForEachOps$ForEachOp.evaluateParallel(ForEachOps.java:159)
       at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateParallel(ForEachOps.java:173)
       at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233)
       at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:485)
       at com.liferay.portal.workflow.metrics.internal.background.task.WorkflowMetricsSLAProcessBackgroundTaskExecutor._processRunningInstances(WorkflowMetricsSLAProcessBackgroundTaskExecutor.java:445)
       at com.liferay.portal.workflow.metrics.internal.background.task.WorkflowMetricsSLAProcessBackgroundTaskExecutor.execute(WorkflowMetricsSLAProcessBackgroundTaskExecutor.java:125)
       at com.liferay.portal.kernel.backgroundtask.DelegatingBackgroundTaskExecutor.execute(DelegatingBackgroundTaskExecutor.java:41)
       at com.liferay.portal.background.task.internal.ThreadLocalAwareBackgroundTaskExecutor.execute(ThreadLocalAwareBackgroundTaskExecutor.java:72)
       at com.liferay.portal.background.task.internal.messaging.BackgroundTaskMessageListener.doReceive(BackgroundTaskMessageListener.java:136)
       at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
       at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:74)
       at com.liferay.portal.messaging.internal.ParallelDestination$1.run(ParallelDestination.java:56)
       at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExecutor.java:753)
       at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor.java:665)
       at java.lang.Thread.run(Thread.java:748)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              support-lep@liferay.com SE Support
              Reporter:
              cleydyr.albuquerque Cleydyr Albuquerque (Inactive)
              Participants of an Issue:
              Recent user:
              Rafael Praxedes
              Engineering Assignee:
              Cleydyr Albuquerque (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Days since last comment:
                45 weeks, 4 days ago

                  Packages

                  Version Package