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

recurrence in workflow xml accepts second as scale but event will not run

Details

    Description

      Description

      User can upload a workflow xml for kaleo, which has a recurrence event with second as scale.
      Portal parses the xml without any complaints and creates a cron-text for the event.

      Excerpt from the recurrence-minute.xml file

      <task-timer>
         <name>OKRecurrentTimer</name>
         <delay>
           <duration>7</duration>
           <scale>second</scale>
         </delay>
         <recurrence>
           <duration>1</duration>
           <scale>minute</scale>
         </recurrence>
         <blocking>false</blocking>
      

      Check the <scale> tags. The attached recurrence-second.xml contains
      <scale>second</scale> for <recurrence> and <duration>10</duration>

      steps to reproduce

      1. start Liferay portal
      2. add Blogs portlet to a page
      3. deploy Kaleo-web plugin
      4. upload the attached workflow xml file: "recurrence_minute.xml"
        1. admin -> control panel -> Workflow -> upload definition
        2. after upload, "RecurrenceMinute" should appear in the list
      5. set up workflow for blog entries
        1. control panel -> Sites -> Liferay -> Configuration -> Workflow configuration
        2. select "RecurrenceMinute" for "Blogs Entry"
      6. Add a blog entry with blogs portlet
      7. check the logs, it should work
        • After 7 seconds, the first "===OK!===" will be on the logs.
        • After every 1 minute, a new "===OK!===" will be on the logs.
      8. approve the tasks to stop write messages in the log
        1. My Account -> My Workflow Tasks
        2. click on Actions->ConnectorXXX for every item
      9. upload the attached workflow xml file: "recurrence_second.xml"
      10. "RecurrenceSecond" should appear in the workflow-list
      11. set up this new workflow for "Blogs entry"
      12. Add a blog entry with blogs portlet
      13. check the logs:
        • After 7 seconds, the first "===OK!===" will be on the logs.

      Experienced behaviour

      There will be no more "===OK!===" messages in the log

      Expected behaviour

      There should be a new "===OK!===" message in every 10 seconds in the log

      Possible cause

      CronText.java does not care about seconds (probably there is a bug about years also when creating crontexts)
      DurationScale.java->getIntegerValue does not care about "seconds".
      It also does not care about "week" in parse method.

      Attachments

        Issue Links

          Activity

            People

              linda.sui Linda Sui
              peter.borkuti Peter Borkuti (Inactive)
              Kiyoshi Lee Kiyoshi Lee
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                8 years, 50 weeks, 1 day ago

                Packages

                  Version Package
                  6.1.X EE
                  6.2.1 CE GA2
                  6.2.X EE