0
votes

I have a oozie coordinator which runs every 30 minutes.

But I want to run only one instance of it at a time.

(Say, if the workflow takes more than 30 minutes to complete, I don't want the next scheduled workflow to start running until the previous one finishes)

Is there a configuration property I can set in coordinator.xml to achieve this?

1

1 Answers

0
votes

You can specify concurrency option for you cooridinator, i.e. how many actions can work simultaneously for given coordinator. You can also specify execution strategy and timeout to control if actions should be skipped, when overlapping, and which.

   <coordinator-app name="[NAME]" frequency="[FREQUENCY]"
                    start="[DATETIME]" end="[DATETIME]" timezone="[TIMEZONE]"
                    xmlns="uri:oozie:coordinator:0.1">
      <controls>
        <timeout>[TIME_PERIOD]</timeout>
        <concurrency>[CONCURRENCY]</concurrency>
        <execution>[EXECUTION_STRATEGY]</execution>
      </controls>
      ...

But as far as I know this didn't work well in Oozie version 3.3. You can try it with newer version.

Further reading: https://oozie.apache.org/docs/4.3.0/CoordinatorFunctionalSpec.html#a6.1.6._Coordinator_Action_Execution_Policies