Parameterization of Coordinator jobs

These functions are used to control Datasets, which are used for processing or produced as part of Coordinator processing.

dateOffset(String baseDate, int instance, String timeUnit)

This function calculates the datestamp based on the following calculation:

newDateStamp = baseDateStamp + (instance*timeUnit)

It offsets the baseDateStamp value by the amount given by instance and timeUnit.

The timeUnit value can be one of the following:

  • YEAR
  • MONTH
  • DAY
  • HOUR
  • MINUTE

Consider the following example:

${coord:dateOffset(coord:nominalTime(), 2, 'DAY')}

If nominal time is 2015-08-22T23:00Z, then after the new calculation the output will be 2015- 08-24T23:00Z.

dateTzOffet(String baseDate, String timezone)

This function calculates ...

Get Apache Oozie Essentials now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.