Documentation ¶
Index ¶
- func Handler(ctx context.Context, request *events.APIGatewayV2HTTPRequest) (*events.APIGatewayV2HTTPResponse, error)
- func MarshalResponse(results JobResults) (*events.APIGatewayV2HTTPResponse, error)
- func ProcessJob(_ context.Context, body string) (string, error)
- type JobIDs
- type JobResults
- type Jobs
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Handler ¶
func Handler( ctx context.Context, request *events.APIGatewayV2HTTPRequest, ) (*events.APIGatewayV2HTTPResponse, error)
func MarshalResponse ¶
func MarshalResponse(results JobResults) (*events.APIGatewayV2HTTPResponse, error)
Types ¶
type JobResults ¶
func ProcessJobs ¶
func ProcessJobs(ctx context.Context, jobs Jobs) (JobResults, error)
ProcessJobs processes a batch of jobs.
This function is called by the lambda function.
The function returns a list of results, each result corresponds to a job in the input list. If the job was processed successfully, the result will contain the result of the job. If the job failed, the result will contain an error message.
type Jobs ¶
func UnmarshalBody ¶
func UnmarshalBody(request *events.APIGatewayV2HTTPRequest) (Jobs, error)
Click to show internal directories.
Click to hide internal directories.