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.
This commit is contained in:
Lars Karlitski 2020-04-15 23:12:49 +02:00 committed by Tom Gundersen
parent 76bd5ab984
commit ac40b0e73b
6 changed files with 15 additions and 15 deletions

31
internal/worker/json.go Normal file
View file

@ -0,0 +1,31 @@
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 {
}