commonMain.zakadabar.lib.schedule.data.JobFail.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of schedule-jvm Show documentation
Show all versions of schedule-jvm Show documentation
Kotlin/Ktor based full-stack platform
/*
* Copyright © 2020-2021, Simplexion, Hungary and contributors. Use of this source code is governed by the Apache 2.0 license.
*/
package zakadabar.lib.schedule.data
import kotlinx.datetime.Instant
import kotlinx.serialization.Serializable
import zakadabar.core.data.ActionBo
import zakadabar.core.data.ActionBoCompanion
import zakadabar.core.data.ActionStatus
import zakadabar.core.data.EntityId
import zakadabar.core.schema.BoSchema
@Serializable
class JobFail(
var jobId: EntityId,
var lastFailMessage: String?,
var lastFailData: String?,
var retryAt: Instant?,
) : ActionBo {
companion object : ActionBoCompanion(Job.boNamespace)
override suspend fun execute() = comm.action(this, serializer(), ActionStatus.serializer())
override fun schema() = BoSchema {
+ ::jobId
+ ::lastFailMessage
+ ::lastFailData
+ ::retryAt
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy