Skip to content

Commit a09b284

Browse files
Copilotgeirsagberg
andcommitted
Add Ktor support documentation to README
Co-authored-by: geirsagberg <594564+geirsagberg@users.noreply.github.com>
1 parent 31199f7 commit a09b284

1 file changed

Lines changed: 24 additions & 0 deletions

File tree

README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ dashboard for monitoring and basic administration of tasks.
2121
## Table of contents
2222

2323
* [Getting started](#getting-started)
24+
* [Using with Ktor (non-Spring applications)](#using-with-ktor-non-spring-applications)
2425
* [Prerequisites](#prerequisites)
2526
* [How it works](#how-it-works)
2627
* [Configuration](#configuration)
@@ -59,6 +60,29 @@ dashboard for monitoring and basic administration of tasks.
5960
You do not need to add db-scheduler as a dependency.
6061
3. Start your application. The db-scheduler UI can be reached at `<your-app-url>/db-scheduler`
6162

63+
## Using with Ktor (non-Spring applications)
64+
65+
If you want to use db-scheduler-ui without Spring dependencies, you can use the Ktor plugin provided by [db-scheduler-additions](https://github.com/osoykan/db-scheduler-additions).
66+
67+
Add the dependency:
68+
69+
```kotlin
70+
implementation("io.github.osoykan:db-scheduler-ui-ktor:$version")
71+
```
72+
73+
Install the plugin in your Ktor application:
74+
75+
```kotlin
76+
install(DbSchedulerUI) {
77+
routePath = "/db-scheduler"
78+
scheduler = { get<Scheduler>() } // provide your Scheduler instance
79+
enabled = true
80+
taskData = true
81+
}
82+
```
83+
84+
For more details and advanced configuration (including execution history support), see the [db-scheduler-additions repository](https://github.com/osoykan/db-scheduler-additions).
85+
6286
## Optional: task history
6387

6488
If you want to add task history to your UI you need to add the following dependency:

0 commit comments

Comments
 (0)