Documentation ¶
Overview ¶
GENERATED DO NOT EDIT GENERATOR: scripts/gencode/gencode.go ARGUMENTS: --component server --config ../../../../config/api.job.yml --package jobserver --out-dir . --out ./jobserver.gen.go --model-package github.com/adamlouis/squirrelbyte/server/pkg/model/jobmodel
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterRouter ¶
func RegisterRouter(apiHandler APIHandler, r *mux.Router, c ErrorCoder)
Types ¶
type APIHandler ¶
type APIHandler interface { ListJobs(ctx context.Context, queryParams *jobmodel.ListJobsQueryParams) (*jobmodel.ListJobsResponse, error) GetJob(ctx context.Context, pathParams *jobmodel.GetJobPathParams) (*jobmodel.Job, error) DeleteJob(ctx context.Context, pathParams *jobmodel.DeleteJobPathParams) error QueueJob(ctx context.Context, body *jobmodel.Job) (*jobmodel.Job, error) ClaimSomeJob(ctx context.Context, body *jobmodel.ClaimSomeJobRequest) (*jobmodel.Job, error) ClaimJob(ctx context.Context, pathParams *jobmodel.ClaimJobPathParams) (*jobmodel.Job, error) ReleaseJob(ctx context.Context, pathParams *jobmodel.ReleaseJobPathParams) (*jobmodel.Job, error) SetJobSuccess(ctx context.Context, pathParams *jobmodel.SetJobSuccessPathParams) (*jobmodel.Job, error) SetJobError(ctx context.Context, pathParams *jobmodel.SetJobErrorPathParams) (*jobmodel.Job, error) }
func NewAPIHandler ¶
func NewAPIHandler(db *sqlx.DB) APIHandler
type ErrorCoder ¶
type HTTPHandler ¶
type HTTPHandler interface { ListJobs(w http.ResponseWriter, req *http.Request) GetJob(w http.ResponseWriter, req *http.Request) DeleteJob(w http.ResponseWriter, req *http.Request) QueueJob(w http.ResponseWriter, req *http.Request) ClaimSomeJob(w http.ResponseWriter, req *http.Request) ClaimJob(w http.ResponseWriter, req *http.Request) ReleaseJob(w http.ResponseWriter, req *http.Request) SetJobSuccess(w http.ResponseWriter, req *http.Request) SetJobError(w http.ResponseWriter, req *http.Request) }
type RollbackFn ¶
type RollbackFn func() error
Click to show internal directories.
Click to hide internal directories.