{"id":18792115,"url":"https://github.com/sterlp/spring-persistent-tasks","last_synced_at":"2026-02-09T01:32:17.278Z","repository":{"id":241618206,"uuid":"807255908","full_name":"sterlp/spring-persistent-tasks","owner":"sterlp","description":"Persistent and user-friendly task management framework for Spring Boot with JPA support, enabling asynchronous task queuing, execution, and scheduling.","archived":false,"fork":false,"pushed_at":"2026-01-11T16:15:29.000Z","size":15826,"stargazers_count":3,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-01-11T18:03:37.981Z","etag":null,"topics":["dashboard","framework","java","job","jobs","jpa","outbound-pattern","persistent","quartz","quartz-scheduler","scheduled","scheduled-jobs","scheduled-task","scheduled-tasks","spring","spring-boot","task","task-scheduling","trigger"],"latest_commit_sha":null,"homepage":"https://spring-persistent-task.sterl.org/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sterlp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-05-28T18:47:40.000Z","updated_at":"2026-01-11T14:44:05.000Z","dependencies_parsed_at":"2024-06-01T17:19:47.619Z","dependency_job_id":"f445b9c0-c071-431c-9ff7-3f780fc55ace","html_url":"https://github.com/sterlp/spring-persistent-tasks","commit_stats":null,"previous_names":["sterlp/spring-persistent-tasks"],"tags_count":42,"template":false,"template_full_name":null,"purl":"pkg:github/sterlp/spring-persistent-tasks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sterlp%2Fspring-persistent-tasks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sterlp%2Fspring-persistent-tasks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sterlp%2Fspring-persistent-tasks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sterlp%2Fspring-persistent-tasks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sterlp","download_url":"https://codeload.github.com/sterlp/spring-persistent-tasks/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sterlp%2Fspring-persistent-tasks/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29252978,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-08T22:49:53.206Z","status":"ssl_error","status_checked_at":"2026-02-08T22:49:51.384Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dashboard","framework","java","job","jobs","jpa","outbound-pattern","persistent","quartz","quartz-scheduler","scheduled","scheduled-jobs","scheduled-task","scheduled-tasks","spring","spring-boot","task","task-scheduling","trigger"],"created_at":"2024-11-07T21:18:24.581Z","updated_at":"2026-02-09T01:32:17.256Z","avatar_url":"https://github.com/sterlp.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Java CI with Maven](https://github.com/sterlp/spring-persistent-tasks/actions/workflows/build.yml/badge.svg)](https://github.com/sterlp/spring-persistent-tasks/actions/workflows/build.yml)\n[![Spring Boot](https://img.shields.io/badge/Spring%20Boot-3.x-brightgreen.svg)](https://spring.io/projects/spring-boot)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)\n\n# Spring Persistent Tasks\n\nA simple task management framework designed to queue and execute asynchronous tasks with support for database persistence and a user-friendly interface. It can be used to implement scheduling patterns or outbound patterns.\n\nFocus is the usage with spring boot and JPA.\n\nSecondary goal is to support [Poor mans Workflow](https://github.com/sterlp/pmw)\n\n# Key Features ✨\n\n1. **JPA-Powered Persistence** - Automatically persists tasks to your database\n1. **Spring Boot Auto-Configuration** - Simple setup with @EnableSpringPersistentTasks\n1. **Clustering Support for tasks** - Built-in lock management for distributed environments and tasks\n1. **Clustering Support for cron tasks** - Support for cron tasks in a cluster - run on just one node\n1. **Type-Safe Tasks** - Generic task definitions with state objects\n1. **Retry Mechanisms** - Automatic retry policies for failed executions\n1. **Transactional Integration** - Works with Spring's transaction management\n1. **Queue Management** - Intelligent task queuing and prioritization\n1. **Different DB Supports** - MySQL, azure-sql-edge, PostgreSQL, and H2\n\n# Documentation\n\nUse [the doc](https://spring-persistent-task.sterl.org/) for more advanced examples.\nThe README contains a shorter how to use.\n\n# Known issues\n\n-   spring-boot-devtools: cause java.lang.ClassCastException exceptions during the state serialization - this is a java/spring issue\n\n# Known limitations\n\n## DBMS have missing bad row lock implementation\n\nThe framework briefly locks a row or trigger to ensure that each trigger is started only on a single node when a cluster is in use. However, some databases still do not support proper row locking and instead lock the entire table. This is not a critical issue but can slow down task selection in very large clusters.\n\n-   mySQL\n-   Azure SQL Edge (maybe also MSSQL)\n\n# DBs for storage\n\n## Tested in the pipeline\n\n-   [![H2](https://img.shields.io/badge/H2-Database-green.svg)](https://www.h2database.com)\n-   [![Azure SQL Edge](https://img.shields.io/badge/Azure_SQL_Edge-2022-0078D4?logo=microsoftsqlserver)](https://azure.microsoft.com/en-us/products/azure-sql/edge/)\n-   [![PostgreSQL](https://img.shields.io/badge/PostgreSQL-16-336791?logo=postgresql)](https://www.postgresql.org)\n-   [![MariaDB](https://img.shields.io/badge/MariaDB-11.1-003545?logo=mariadb)](https://mariadb.org)\n\n![History](screenshots/supported-dbs.png)\n\n## Supported in theory\n\n-   MSSQL, as azure-sql-edge is tested\n\n## Not supported\n\n-   mySQL: sequences are not supported\n\n# JavaDoc\n\n-   [JavaDoc](https://sterlp.github.io/spring-persistent-tasks/javadoc-core/org/sterl/spring/persistent_tasks/PersistentTaskService.html)\n\n# Quickstart\n\n-   [Maven Central spring-persistent-tasks-core](https://central.sonatype.com/artifact/org.sterl.spring/spring-persistent-tasks-core/versions)\n\n## Setup with Maven\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003eorg.sterl.spring\u003c/groupId\u003e\n    \u003cartifactId\u003espring-persistent-tasks-core\u003c/artifactId\u003e\n    \u003cversion\u003e2.x.x\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n## Setup Spring\n\n```java\n@SpringBootApplication\n@EnableSpringPersistentTasks\npublic class ExampleApplication {\n```\n\n## Create a Task\n\n```java\n@Bean\nPersistentTask\u003cVehicle\u003e task1(VehicleHttpConnector vehicleHttpConnector) {\n    return v -\u003e vehicleHttpConnector.send(v);\n}\n```\n\n## Trigger a task\n\n```java\n@Autowired\nPersistentTaskService persistentTaskService;\n\npublic void triggerTask1(Vehicle vehicle) {\n    persistentTaskService.runOrQueue(\n        TriggerBuilder.newTrigger(\"task1\").state(vehicle).build());\n}\n```\n\n### JUnit Tests\n\n-   [Persistent Task and Testing](https://github.com/sterlp/spring-persistent-tasks/wiki/Triggers-and-Tasks-in-JUnit-Tests)\n\n# Setup DB with Liquibase\n\nLiquibase is supported. Either import all or just the required versions.\n\n## Maven\n\n-   [Maven Central spring-persistent-tasks-db](https://central.sonatype.com/artifact/org.sterl.spring/spring-persistent-tasks-db/versions)\n\n## Option 1: Just include the master file\n\n```xml\n\u003cinclude file=\"spring-persistent-tasks/db.changelog-master.xml\" /\u003e\n```\n\n## Option 2: import changesets on by one\n\n```xml\n\u003cinclude file=\"spring-persistent-tasks/db/pt-changelog-v1.xml\" /\u003e\n```\n\n# Setup UI\n\n## Maven\n\n-   [Maven Central spring-persistent-tasks-ui](https://central.sonatype.com/artifact/org.sterl.spring/spring-persistent-tasks-ui/versions)\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003eorg.sterl.spring\u003c/groupId\u003e\n    \u003cartifactId\u003espring-persistent-tasks-ui\u003c/artifactId\u003e\n    \u003cversion\u003ex.x.x\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n## Setup Spring\n\n```java\n@SpringBootApplication\n@EnableSpringPersistentTasks\n@EnableSpringPersistentTasksUI\npublic class ExampleApplication {\n```\n\n## Open the UI\n\n-   http://localhost:8080/task-ui\n\n## Schedulers\n\n![Schedulers](doc/docs/assets/dashboard.png)\n\n## Triggers\n\n![Triggers](doc/docs/assets/triggers.png)\n\n## History\n\n![Triggers](doc/docs/assets/history-page.png)\n\n# Alternatives\n\n-   quartz\n-   db-scheduler\n-   jobrunr\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsterlp%2Fspring-persistent-tasks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsterlp%2Fspring-persistent-tasks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsterlp%2Fspring-persistent-tasks/lists"}