Event handlers that write stuff to the database
Event handlers that write stuff to the database
Interceptor that assigns a new index to the build
Interceptor that assigns a new index to the build
Updates build state to initializing
. Returns a consolidated build/updated
event.
Updates build state to `initializing`. Returns a consolidated `build/updated` event.
(check-credits ctx)
Checks if credits are available. Returns either a build/pending or a build/failed.
Checks if credits are available. Returns either a build/pending or a build/failed.
Creates jobs in the db, as found in the event
Creates jobs in the db, as found in the event
Interceptor that fetches available credits for the customer associated with the build. Assumes that the db is in the context.
Interceptor that fetches available credits for the customer associated with the build. Assumes that the db is in the context.
(queue-build ctx)
Adds the build to the build queue, where it will be picked up by a runner when capacity is available.
Adds the build to the build queue, where it will be picked up by a runner when capacity is available.
Interceptor that saves the build as found in the context result, but does not update the jobs.
Interceptor that saves the build as found in the context result, but does not update the jobs.
Assuming the result contains a build with credits, creates a credit consumption for the associated customer.
Assuming the result contains a build with credits, creates a credit consumption for the associated customer.
Saves the job found in the result build by id specified in the event.
Saves the job found in the result build by id specified in the event.
(use-db db)
Adds storage to the context as ::db
Adds storage to the context as ::db
Combines load-build
and save-build
interceptors. Note that this does not work
atomically.
Combines `load-build` and `save-build` interceptors. Note that this does not work atomically.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close