Documentation ¶
Overview ¶
Package v1 Beanstalk API
Documentation of Beanstalk API.
Schemes: http, https BasePath: /api/system/v1 Version: 1
Consumes: - application/json
Produces: - application/json
SecurityDefinitions:
bearer: type: apiKey in: header name: authorization cookie: type: apiKey in: cookie name: access_token
swagger:meta
Index ¶
- func BuryJob() beanstalk.Handler
- func CreateJob() beanstalk.Handler
- func DeleteJob() beanstalk.Handler
- func GetEmbedFiles(fs http.FileSystem) http.Handler
- func GetJob() beanstalk.Handler
- func GetJobStats() beanstalk.Handler
- func GetServerStats() beanstalk.Handler
- func GetTubeStats() beanstalk.Handler
- func GetTubes() beanstalk.Handler
- func KickJob() beanstalk.Handler
- func ReleaseJob() beanstalk.Handler
- type BadRequestSwaggerResponse
- type BuryJobRequest
- type BuryJobSwaggerParameters
- type CreateJobRequest
- type CreateJobResponse
- type CreateJobSuccessSwaggerResponse
- type CreateJobSwaggerParameters
- type DeleteJobSwaggerParameters
- type Duration
- type ErrorData
- type GetJobSuccessSwaggerResponse
- type GetJobSwaggerParameters
- type JobResponse
- type JobStatsResponse
- type JobStatsSuccessSwaggerResponse
- type JobStatsSwaggerParameters
- type KickJobSwaggerParameters
- type NotFoundSwaggerResponse
- type ReleaseJobRequest
- type ReleaseJobSwaggerParameters
- type ServerStatsResponse
- type ServerStatsSuccessSwaggerResponse
- type SuccessSwaggerResponse
- type TubeStatsResponse
- type TubeStatsSuccessSwaggerResponse
- type TubeStatsSwaggerParameters
- type TubesResponse
- type TubesSuccessSwaggerResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuryJob ¶
func BuryJob() beanstalk.Handler
swagger:route POST /jobs/{id}/bury jobs bury-job
Bury the specified job ¶
Responses: 200: SuccessResponse 400: BadRequestResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
func CreateJob ¶
func CreateJob() beanstalk.Handler
swagger:route POST /jobs jobs create-job
Creates a new job ¶
Responses: 200: CreateJobSuccessResponse 400: BadRequestResponse
Security: - bearer: [] - cookie: []
func DeleteJob ¶
func DeleteJob() beanstalk.Handler
swagger:route POST /jobs/{id}/delete jobs delete-job
Delete the specified job ¶
Responses: 200: SuccessResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
func GetEmbedFiles ¶
func GetEmbedFiles(fs http.FileSystem) http.Handler
func GetJob ¶
func GetJob() beanstalk.Handler
swagger:route GET /jobs/{id} jobs get-job
Gets data of the specified job ¶
Responses: 200: GetJobSuccessResponse 400: BadRequestResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
func GetJobStats ¶
func GetJobStats() beanstalk.Handler
swagger:route GET /jobs/{id}/stats jobs job-stats
Statistics of specified job ¶
Responses: 200: JobStatsSuccessResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
func GetServerStats ¶
func GetServerStats() beanstalk.Handler
swagger:route GET /server/stats server server-stats
Beanstalk server statistics ¶
Responses: 200: ServerStatsSuccessResponse
Security: - bearer: [] - cookie: []
func GetTubeStats ¶
func GetTubeStats() beanstalk.Handler
swagger:route GET /tubes/{name}/stats tubes tube-stats
Gets statistics of specified tube ¶
Responses: 200: TubeStatsSuccessResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
func GetTubes ¶
func GetTubes() beanstalk.Handler
swagger:route GET /tubes tubes list-of-tubes
List of exists tubes ¶
Responses: 200: TubesSuccessResponse
Security: - bearer: [] - cookie: []
func KickJob ¶
func KickJob() beanstalk.Handler
swagger:route POST /jobs/{id}/kick jobs kick-job
Kick the specified job ¶
Responses: 200: SuccessResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
func ReleaseJob ¶
func ReleaseJob() beanstalk.Handler
swagger:route POST /jobs/{id}/release jobs release-job
Release the specified job ¶
Responses: 200: SuccessResponse 400: BadRequestResponse 404: NotFoundResponse
Security: - bearer: [] - cookie: []
Types ¶
type BadRequestSwaggerResponse ¶
type BadRequestSwaggerResponse struct { // in: body Response struct { // default: failure Status string `json:"status"` // default: Bad Request Message string `json:"message"` Data ErrorData `json:"data"` } }
swagger:response BadRequestResponse
type BuryJobRequest ¶
type BuryJobRequest struct {
Priority uint32 `json:"priority"`
}
Request types
type BuryJobSwaggerParameters ¶
type BuryJobSwaggerParameters struct { // Job identifier // // in: path // example: 1 ID int `json:"id"` // in: body Body BuryJobRequest }
swagger:parameters bury-job
type CreateJobRequest ¶
type CreateJobRequest struct { Tube string `json:"tube"` Priority uint32 `json:"priority"` Delay Duration `json:"delay"` TTR Duration `json:"ttr"` Data string `json:"data"` }
Request types
type CreateJobResponse ¶
Response types
type CreateJobSuccessSwaggerResponse ¶
type CreateJobSuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` Data CreateJobResponse `json:"data"` } }
swagger:response CreateJobSuccessResponse
type CreateJobSwaggerParameters ¶
type CreateJobSwaggerParameters struct { // in: body Body CreateJobRequest }
swagger:parameters create-job
type DeleteJobSwaggerParameters ¶
type DeleteJobSwaggerParameters struct { // Job identifier // // in: path // example: 1 ID int `json:"id"` }
swagger:parameters delete-job
type GetJobSuccessSwaggerResponse ¶
type GetJobSuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` Data JobResponse `json:"data"` } }
swagger:response GetJobSuccessResponse
type GetJobSwaggerParameters ¶
type GetJobSwaggerParameters struct { // Job identifier // // in: path // example: 1 ID int `json:"id"` }
swagger:parameters get-job
type JobStatsResponse ¶
type JobStatsResponse struct {
Stats *beanstalk.StatsJob `json:"stats"`
}
Response types
type JobStatsSuccessSwaggerResponse ¶
type JobStatsSuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` Data JobStatsResponse `json:"data"` } }
swagger:response JobStatsSuccessResponse
type JobStatsSwaggerParameters ¶
type JobStatsSwaggerParameters struct { // Job identifier // // in: path // example: 1 ID int `json:"id"` }
swagger:parameters job-stats
type KickJobSwaggerParameters ¶
type KickJobSwaggerParameters struct { // Job identifier // // in: path // example: 1 ID int `json:"id"` }
swagger:parameters kick-job
type NotFoundSwaggerResponse ¶
type NotFoundSwaggerResponse struct { // in: body Response struct { // default: failure Status string `json:"status"` // default: Not Found Message string `json:"message"` } }
swagger:response NotFoundResponse
type ReleaseJobRequest ¶
Request types
type ReleaseJobSwaggerParameters ¶
type ReleaseJobSwaggerParameters struct { // Job identifier // // in: path // example: 1 ID int `json:"id"` // in: body Body ReleaseJobRequest }
swagger:parameters release-job
type ServerStatsResponse ¶
type ServerStatsResponse struct {
Stats *beanstalk.Stats `json:"stats"`
}
Response types
type ServerStatsSuccessSwaggerResponse ¶
type ServerStatsSuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` Data ServerStatsResponse `json:"data"` } }
swagger:response ServerStatsSuccessResponse
type SuccessSwaggerResponse ¶
type SuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` } }
swagger:response SuccessResponse
type TubeStatsResponse ¶
type TubeStatsResponse struct {
Stats *beanstalk.StatsTube `json:"stats"`
}
Response types
type TubeStatsSuccessSwaggerResponse ¶
type TubeStatsSuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` Data TubeStatsResponse `json:"data"` } }
swagger:response TubeStatsSuccessResponse
type TubeStatsSwaggerParameters ¶
type TubeStatsSwaggerParameters struct { // Tube name // // in: path // example: default Name string `json:"name"` }
swagger:parameters tube-stats
type TubesSuccessSwaggerResponse ¶
type TubesSuccessSwaggerResponse struct { // in: body Response struct { // default: success Status string `json:"status"` Data TubesResponse `json:"data"` } }
swagger:response TubesSuccessResponse