Is Quarkus+Quartz Worth It for Scheduling Tasks Over Plain Quartz?

0
2
Asked By TechieTurtle92 On

Hey everyone! I have a few scheduled jobs that I kick off using cron expressions in a standalone Java application with Quartz. I've heard that Quartz integrates with Quarkus, and I'm curious if switching to Quarkus is a smart move compared to sticking with plain Quartz.

From what I've gathered, Quarkus is great for fast restarts, but it doesn't restart for every request, so it still functions as a long-running process. What are the advantages of using Quarkus with Quartz? Is it primarily about native images? And if I'm not using native images, how does it stack up?

Also, I'd like to expand this question out to Quartz vs. frameworks like Spring Boot or Javalin. What benefits do you all see with Quartz in environments where long-running processes are a concern? Thanks!

5 Answers

Answered By DevDynamo88 On

If you don't plan to leverage what Quarkus offers as an application framework, you might not need to switch. But if your project already uses features like dependency injection, Hibernate, or REST clients, then integrating Quartz with Quarkus can enhance your app since it's just another feature you can utilize as needed.

Answered By QuartzGuru21 On

I’m currently working on a Quarkus/Quartz project and it’s been fantastic! I'm not only using Scheduled annotations but also dynamically building jobs and triggers stored with JDBC. The developer services Quarkus offers make development a breeze, so I'd definitely recommend it over other options.

Answered By CodeNinja77 On

Honestly, it depends on where you're deploying. If you're on Kubernetes, I'd recommend using Kubernetes cron jobs instead of relying on a long-running Java application. Managing cron jobs inside Java should be a last resort, given you'd have to keep the JVM running continuously and track previous job runs carefully.

Answered By SpringAdvocate99 On

Have you considered using Spring Boot instead of Quarkus with Quartz? The standard `@Scheduled` annotation is simple and effective. However, if you need dynamic scheduling, Quartz allows you to manage triggers programmatically, which is a feature I find lacking in Spring’s basic scheduling.

Answered By SchedulerWizard45 On

Quartz uses your database to manage job consistency and prevent concurrent jobs from running across multiple instances. This is a big plus if your service runs in a clustered environment. On the other hand, Quarkus's built-in scheduler is tied to the instance it runs on, which can limit its effectiveness.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.