debian-forge-composer/internal/worker/json.go
Lars Karlitski ac40b0e73b jobqueue: rename to worker
This package does not contain an actual queue, but a server and client
implementation for osbuild's worker API. Name it accordingly.

The queue is in package `store` right now, but about to be split off.
This rename makes the `jobqueue` name free for that effort.
2020-04-16 01:02:16 +02:00

31 lines
717 B
Go

package worker
import (
"github.com/google/uuid"
"github.com/osbuild/osbuild-composer/internal/common"
"github.com/osbuild/osbuild-composer/internal/osbuild"
"github.com/osbuild/osbuild-composer/internal/target"
)
type errorResponse struct {
Message string `json:"message"`
}
type addJobRequest struct {
}
type addJobResponse struct {
ComposeID uuid.UUID `json:"compose_id"`
ImageBuildID int `json:"image_build_id"`
Manifest *osbuild.Manifest `json:"manifest"`
Targets []*target.Target `json:"targets"`
}
type updateJobRequest struct {
Status common.ImageBuildState `json:"status"`
Result *common.ComposeResult `json:"result"`
}
type updateJobResponse struct {
}