cron-to-quartz

WebJar for cron-to-quartz

License

License

MIT
Categories

Categories

Ant Build Tools Quartz Application Layer Libs Job Scheduling
GroupId

GroupId

org.webjars.bowergithub.lirantal
ArtifactId

ArtifactId

cron-to-quartz
Last Version

Last Version

1.4.6
Release Date

Release Date

Type

Type

jar
Description

Description

cron-to-quartz
WebJar for cron-to-quartz
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/lirantal/cron-to-quartz

Download cron-to-quartz

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.bowergithub.lirantal/cron-to-quartz/ -->
<dependency>
    <groupId>org.webjars.bowergithub.lirantal</groupId>
    <artifactId>cron-to-quartz</artifactId>
    <version>1.4.6</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.bowergithub.lirantal/cron-to-quartz/
implementation 'org.webjars.bowergithub.lirantal:cron-to-quartz:1.4.6'
// https://jarcasting.com/artifacts/org.webjars.bowergithub.lirantal/cron-to-quartz/
implementation ("org.webjars.bowergithub.lirantal:cron-to-quartz:1.4.6")
'org.webjars.bowergithub.lirantal:cron-to-quartz:jar:1.4.6'
<dependency org="org.webjars.bowergithub.lirantal" name="cron-to-quartz" rev="1.4.6">
  <artifact name="cron-to-quartz" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.bowergithub.lirantal', module='cron-to-quartz', version='1.4.6')
)
libraryDependencies += "org.webjars.bowergithub.lirantal" % "cron-to-quartz" % "1.4.6"
[org.webjars.bowergithub.lirantal/cron-to-quartz "1.4.6"]

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

view on npm view on npm npm module downloads Build Coverage Status Known Vulnerabilities Security Responsible Disclosure

cron-to-quartz

cron-to-quartz

Node.js JavaScript library to convert unix or linux CRON syntax to Quartz Scheduler

Install

Pre-requisite

  • Node.js

As a dependency of another project

Install the module as a dependency in your project so you can easily require it and use it as a library

yarn add cron-to-quartz

As a library to use

To use the cron-to-quartz as a library to work with and explore, you should clone the repository and install required modules.

  • Note: the node.js grunt task runner is required as a build tool for the library
git clone https://github.com/lirantal/cron-to-quartz.git
cd cron-to-quartz
yarn install

You can then run the test suite:

yarn run test

Usage

In your NodeJS projects, simply require this library:

var C2Q = require("../index.js");

Then you can just query the C2Q object with any cron notation as seen in the following examples:

var quartz = C2Q.getQuartz("@hourly");
var quartz = C2Q.getQuartz("0 0,12 1 */2 *");
var quartz = C2Q.getQuartz("00 11,13 * * *");

Special cases

The Quartz Scheduler isn't fully compatible with the CRON notation, so while CRON allows logical OR expressions, Quartz doesn't do that. For this reason, if you provide such CRON syntax, then the C2Q object will yield an array of 2 values:

var quartz = C2Q.getQuartz("0 4 15-21 * 1");

Resources

CronMaker is an online web-based utility to help build and test expressions that are compatible with the Quartz open source schedule. cron.guru is an online web-based utility to translate a valid Linux CRON expression to an actual human readable schedule Quartz Scheduler Developer Guide

Author

Liran Tal [email protected]

Versions

Version
1.4.6