README.adoc

June 23, 2026 ยท View on GitHub

image:https://github.com/NoEnv/vertx-cronutils/actions/workflows/ci.yml/badge.svg["Build Status",link="https://github.com/NoEnv/vertx-cronutils/actions/workflows/ci.yml"] image:https://codecov.io/gh/NoEnv/vertx-cronutils/branch/main/graph/badge.svg["Code Coverage",link="https://codecov.io/gh/NoEnv/vertx-cronutils"] image:https://badgen.net/maven/v/maven-central/com.noenv/vertx-cronutils["Maven Central",link="https://search.maven.org/artifact/com.noenv/vertx-cronutils"] image:https://badgen.net/discord/online-members/mZAjkQfYSj["Discord",link="https://discord.gg/mZAjkQfYSj"]

= Vert.x-CronUtils

Vert.x-CronUtils is an implementation of the cron-utils library for Vert.x.

This module allows scheduling tasks with unix cron expressions.

== Using Vert.x-CronUtils

To use the Vert.x Cron-Utils, add the following dependency to the dependencies section of your build descriptor:

  • Maven (in your pom.xml):

[source,xml,subs="+attributes"]

com.noenv vertx-cronutils 5.1.3 ----
  • Gradle (in your build.gradle file):

[source,groovy,subs="+attributes"]

compile 'com.noenv:vertx-cronutils:5.1.3'

== Creating a cron scheduler

You can create cron schedulers using the following flavours Unix, Cron4j and Quartz

[source,java]

CronScheduler .create(vertx, "0/1 * * * * ?", CronType.QUARTZ) //trigger every second .schedule(s -> System.out.println("timer triggered") );

[source,java]

CronScheduler .create(vertx, "0 * * * * ?") //trigger every minute .schedule(s -> { s.cancel(); System.out.println("timer triggered and canceled"); });