Skip to content

Commit

Permalink
Merge pull request #143 from nickdnk/schema
Browse files Browse the repository at this point in the history
Add schema
  • Loading branch information
nickdnk authored Oct 23, 2024
2 parents bc05219 + 72e8d21 commit 0fb03bc
Showing 1 changed file with 73 additions and 0 deletions.
73 changes: 73 additions & 0 deletions schema.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"$id": "https://raw.githubusercontent.com/roadrunner-server/beanstalk/refs/heads/master/schema.json",
"$schema": "https://json-schema.org/draft/2019-09/schema",
"title": "roadrunner-beanstalk",
"description": "The schema contains all the valid configuration parameters for the Beanstalk plugin for the roadrunner job system.",
"definitions": {
"pipeline": {
"type": "object",
"required": [
"driver"
],
"additionalProperties": false,
"properties": {
"driver": {
"type": "string",
"enum": [
"beanstalk"
]
},
"config": {
"type": "object",
"description": "Configuration options for the Beanstalk pipeline.",
"additionalProperties": false,
"properties": {
"priority": {
"$ref": "https://raw.githubusercontent.com/roadrunner-server/jobs/refs/heads/master/schema.json#/definitions/PipelineProperties/priority"
},
"prefetch": {
"$ref": "https://raw.githubusercontent.com/roadrunner-server/jobs/refs/heads/master/schema.json#/definitions/PipelineProperties/prefetch"
},
"consume_all": {
"$ref": "https://raw.githubusercontent.com/roadrunner-server/jobs/refs/heads/master/schema.json#/definitions/PipelineProperties/consume_all"
},
"tube_priority": {
"description": "Beanstalk internal tube priority",
"type": "integer",
"default": 1
},
"tube": {
"description": "Tube name",
"type": "string",
"default": "default"
},
"reserve_timeout": {
"description": "If no job is available before this timeout has passed, Reserve returns a ConnError recording ErrTimeout",
"$ref": "https://raw.githubusercontent.com/roadrunner-server/roadrunner/refs/heads/master/schemas/config/3.0.schema.json#/definitions/Duration",
"default": "5s"
}
}
}
}
},
"driver": {
"type": "object",
"additionalProperties": false,
"description": "Configuration options for the Beanstalk driver.",
"properties": {
"addr": {
"title": "Beanstalk Server Address",
"description": "The address of the Beanstalk server.",
"type": "string",
"default": "tcp://127.0.0.1:11300"
},
"timeout": {
"title": "Connection Timeout",
"description": "Connection timeout for the Beanstalk server.",
"$ref": "https://raw.githubusercontent.com/roadrunner-server/roadrunner/refs/heads/master/schemas/config/3.0.schema.json#/definitions/Duration",
"default": "30s"
}
}
}
}
}

0 comments on commit 0fb03bc

Please sign in to comment.