OxygenInstance API

MINDFul.Server.OxygenInstance.dynamicfilesFunction
dynamicfiles(folder::String, mountdir::String; headers::Vector{Pair{String,String}}=[], loadfile::Union{Function,Nothing}=nothing)

Mount all files inside the /static folder (or user defined mount point), but files are re-read on each request. The headers array will get applied to all mounted files

source
MINDFul.Server.OxygenInstance.internalrequestFunction
internalrequest(req::HTTP.Request; middleware::Vector=[], serialize::Bool=true, catch_errors::Bool=true)

Directly call one of our other endpoints registered with the router, using your own middleware and bypassing any globally defined middleware

source
MINDFul.Server.OxygenInstance.serveFunction
serve(; middleware::Vector=[], handler=stream_handler, host="127.0.0.1", port=8080, async=false, parallel=false, serialize=true, catch_errors=true, docs=true, metrics=true, show_errors=true, show_banner=true, docs_path="/docs", schema_path="/schema", external_url=nothing, revise, kwargs...)

Start the webserver with your own custom request handler

source
MINDFul.Server.OxygenInstance.staticfilesFunction
staticfiles(folder::String, mountdir::String; headers::Vector{Pair{String,String}}=[], loadfile::Union{Function,Nothing}=nothing)

Mount all files inside the /static folder (or user defined mount point). The headers array will get applied to all mounted files

source
MINDFul.Server.OxygenInstance.@cronMacro
@cron(expression::String, name::String, func::Function)

This variation provides way manually "name" a registered function. This information is used by the server on startup to log out all cron jobs.

source
MINDFul.Server.OxygenInstance.@cronMacro
@cron(expression::String, func::Function)

Registers a function with a cron expression. This will extract either the function name or the random Id julia assigns to each lambda function.

source
MINDFul.Server.OxygenInstance.@dynamicfilesMacro
@dynamicfiles(folder::String, mountdir::String, headers::Vector{Pair{String,String}}=[])

Mount all files inside the /static folder (or user defined mount point), but files are re-read on each request

source
MINDFul.Server.OxygenInstance.@repeatMacro

@repeat(interval::Real, name::String, func::Function)

This variation provides way manually "name" a registered repeat task. This information is used by the server on startup to log out all cron jobs.

source
MINDFul.Server.OxygenInstance.@repeatMacro
@repeat(interval::Real, func::Function)

Registers a repeat task. This will extract either the function name or the random Id julia assigns to each lambda function.

source