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.
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.
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