server

package
v0.41.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 11, 2023 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BulkCollectionPath added in v0.26.0

func BulkCollectionPath() string

BulkCollectionPath returns the URL path to the collection service bulk HTTP endpoint.

func BulkStatusCollectionPath added in v0.26.0

func BulkStatusCollectionPath() string

BulkStatusCollectionPath returns the URL path to the collection service bulk_status HTTP endpoint.

func CancelCollectionPath

func CancelCollectionPath(id uint) string

CancelCollectionPath returns the URL path to the collection service cancel HTTP endpoint.

func DecideCollectionPath added in v0.22.0

func DecideCollectionPath(id uint) string

DecideCollectionPath returns the URL path to the collection service decide HTTP endpoint.

func DecodeBulkRequest added in v0.26.0

func DecodeBulkRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeBulkRequest returns a decoder for requests sent to the collection bulk endpoint.

func DecodeCancelRequest

func DecodeCancelRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeCancelRequest returns a decoder for requests sent to the collection cancel endpoint.

func DecodeDecideRequest added in v0.22.0

func DecodeDecideRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeDecideRequest returns a decoder for requests sent to the collection decide endpoint.

func DecodeDeleteRequest

func DecodeDeleteRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeDeleteRequest returns a decoder for requests sent to the collection delete endpoint.

func DecodeDownloadRequest added in v0.14.0

func DecodeDownloadRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeDownloadRequest returns a decoder for requests sent to the collection download endpoint.

func DecodeListRequest

func DecodeListRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeListRequest returns a decoder for requests sent to the collection list endpoint.

func DecodeRetryRequest

func DecodeRetryRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeRetryRequest returns a decoder for requests sent to the collection retry endpoint.

func DecodeShowRequest

func DecodeShowRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeShowRequest returns a decoder for requests sent to the collection show endpoint.

func DecodeWorkflowRequest

func DecodeWorkflowRequest(mux goahttp.Muxer, decoder func(*http.Request) goahttp.Decoder) func(*http.Request) (any, error)

DecodeWorkflowRequest returns a decoder for requests sent to the collection workflow endpoint.

func DeleteCollectionPath

func DeleteCollectionPath(id uint) string

DeleteCollectionPath returns the URL path to the collection service delete HTTP endpoint.

func DownloadCollectionPath added in v0.14.0

func DownloadCollectionPath(id uint) string

DownloadCollectionPath returns the URL path to the collection service download HTTP endpoint.

func EncodeBulkError added in v0.26.0

func EncodeBulkError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeBulkError returns an encoder for errors returned by the bulk collection endpoint.

func EncodeBulkResponse added in v0.26.0

func EncodeBulkResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeBulkResponse returns an encoder for responses returned by the collection bulk endpoint.

func EncodeBulkStatusResponse added in v0.26.0

func EncodeBulkStatusResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeBulkStatusResponse returns an encoder for responses returned by the collection bulk_status endpoint.

func EncodeCancelError

func EncodeCancelError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeCancelError returns an encoder for errors returned by the cancel collection endpoint.

func EncodeCancelResponse

func EncodeCancelResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeCancelResponse returns an encoder for responses returned by the collection cancel endpoint.

func EncodeDecideError added in v0.22.0

func EncodeDecideError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeDecideError returns an encoder for errors returned by the decide collection endpoint.

func EncodeDecideResponse added in v0.22.0

func EncodeDecideResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeDecideResponse returns an encoder for responses returned by the collection decide endpoint.

func EncodeDeleteError

func EncodeDeleteError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeDeleteError returns an encoder for errors returned by the delete collection endpoint.

func EncodeDeleteResponse

func EncodeDeleteResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeDeleteResponse returns an encoder for responses returned by the collection delete endpoint.

func EncodeDownloadError added in v0.14.0

func EncodeDownloadError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeDownloadError returns an encoder for errors returned by the download collection endpoint.

func EncodeDownloadResponse added in v0.14.0

func EncodeDownloadResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeDownloadResponse returns an encoder for responses returned by the collection download endpoint.

func EncodeListResponse

func EncodeListResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeListResponse returns an encoder for responses returned by the collection list endpoint.

func EncodeRetryError

func EncodeRetryError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeRetryError returns an encoder for errors returned by the retry collection endpoint.

func EncodeRetryResponse

func EncodeRetryResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeRetryResponse returns an encoder for responses returned by the collection retry endpoint.

func EncodeShowError

func EncodeShowError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeShowError returns an encoder for errors returned by the show collection endpoint.

func EncodeShowResponse

func EncodeShowResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeShowResponse returns an encoder for responses returned by the collection show endpoint.

func EncodeWorkflowError

func EncodeWorkflowError(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder, formatter func(ctx context.Context, err error) goahttp.Statuser) func(context.Context, http.ResponseWriter, error) error

EncodeWorkflowError returns an encoder for errors returned by the workflow collection endpoint.

func EncodeWorkflowResponse

func EncodeWorkflowResponse(encoder func(context.Context, http.ResponseWriter) goahttp.Encoder) func(context.Context, http.ResponseWriter, any) error

EncodeWorkflowResponse returns an encoder for responses returned by the collection workflow endpoint.

func HandleCollectionOrigin added in v0.31.0

func HandleCollectionOrigin(h http.Handler) http.Handler

HandleCollectionOrigin applies the CORS response headers corresponding to the origin for the service collection.

func ListCollectionPath

func ListCollectionPath() string

ListCollectionPath returns the URL path to the collection service list HTTP endpoint.

func MonitorCollectionPath added in v0.34.0

func MonitorCollectionPath() string

MonitorCollectionPath returns the URL path to the collection service monitor HTTP endpoint.

func Mount

func Mount(mux goahttp.Muxer, h *Server)

Mount configures the mux to serve the collection endpoints.

func MountBulkHandler added in v0.26.0

func MountBulkHandler(mux goahttp.Muxer, h http.Handler)

MountBulkHandler configures the mux to serve the "collection" service "bulk" endpoint.

func MountBulkStatusHandler added in v0.26.0

func MountBulkStatusHandler(mux goahttp.Muxer, h http.Handler)

MountBulkStatusHandler configures the mux to serve the "collection" service "bulk_status" endpoint.

func MountCORSHandler

func MountCORSHandler(mux goahttp.Muxer, h http.Handler)

MountCORSHandler configures the mux to serve the CORS endpoints for the service collection.

func MountCancelHandler

func MountCancelHandler(mux goahttp.Muxer, h http.Handler)

MountCancelHandler configures the mux to serve the "collection" service "cancel" endpoint.

func MountDecideHandler added in v0.22.0

func MountDecideHandler(mux goahttp.Muxer, h http.Handler)

MountDecideHandler configures the mux to serve the "collection" service "decide" endpoint.

func MountDeleteHandler

func MountDeleteHandler(mux goahttp.Muxer, h http.Handler)

MountDeleteHandler configures the mux to serve the "collection" service "delete" endpoint.

func MountDownloadHandler added in v0.14.0

func MountDownloadHandler(mux goahttp.Muxer, h http.Handler)

MountDownloadHandler configures the mux to serve the "collection" service "download" endpoint.

func MountListHandler

func MountListHandler(mux goahttp.Muxer, h http.Handler)

MountListHandler configures the mux to serve the "collection" service "list" endpoint.

func MountMonitorHandler added in v0.34.0

func MountMonitorHandler(mux goahttp.Muxer, h http.Handler)

MountMonitorHandler configures the mux to serve the "collection" service "monitor" endpoint.

func MountRetryHandler

func MountRetryHandler(mux goahttp.Muxer, h http.Handler)

MountRetryHandler configures the mux to serve the "collection" service "retry" endpoint.

func MountShowHandler

func MountShowHandler(mux goahttp.Muxer, h http.Handler)

MountShowHandler configures the mux to serve the "collection" service "show" endpoint.

func MountWorkflowHandler

func MountWorkflowHandler(mux goahttp.Muxer, h http.Handler)

MountWorkflowHandler configures the mux to serve the "collection" service "workflow" endpoint.

func NewBulkHandler added in v0.26.0

func NewBulkHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewBulkHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "bulk" endpoint.

func NewBulkPayload added in v0.26.0

func NewBulkPayload(body *BulkRequestBody) *collection.BulkPayload

NewBulkPayload builds a collection service bulk endpoint payload.

func NewBulkStatusHandler added in v0.26.0

func NewBulkStatusHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewBulkStatusHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "bulk_status" endpoint.

func NewCORSHandler

func NewCORSHandler() http.Handler

NewCORSHandler creates a HTTP handler which returns a simple 200 response.

func NewCancelHandler

func NewCancelHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewCancelHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "cancel" endpoint.

func NewCancelPayload

func NewCancelPayload(id uint) *collection.CancelPayload

NewCancelPayload builds a collection service cancel endpoint payload.

func NewDecideHandler added in v0.22.0

func NewDecideHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewDecideHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "decide" endpoint.

func NewDecidePayload added in v0.22.0

func NewDecidePayload(body struct {
	// Decision option to proceed with
	Option *string `form:"option" json:"option" xml:"option"`
}, id uint) *collection.DecidePayload

NewDecidePayload builds a collection service decide endpoint payload.

func NewDeleteHandler

func NewDeleteHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewDeleteHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "delete" endpoint.

func NewDeletePayload

func NewDeletePayload(id uint) *collection.DeletePayload

NewDeletePayload builds a collection service delete endpoint payload.

func NewDownloadHandler added in v0.14.0

func NewDownloadHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewDownloadHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "download" endpoint.

func NewDownloadPayload added in v0.14.0

func NewDownloadPayload(id uint) *collection.DownloadPayload

NewDownloadPayload builds a collection service download endpoint payload.

func NewListHandler

func NewListHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewListHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "list" endpoint.

func NewListPayload

func NewListPayload(name *string, originalID *string, transferID *string, aipID *string, pipelineID *string, earliestCreatedTime *string, latestCreatedTime *string, status *string, cursor *string) *collection.ListPayload

NewListPayload builds a collection service list endpoint payload.

func NewMonitorHandler added in v0.34.0

func NewMonitorHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
	upgrader goahttp.Upgrader,
	configurer goahttp.ConnConfigureFunc,
) http.Handler

NewMonitorHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "monitor" endpoint.

func NewRetryHandler

func NewRetryHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewRetryHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "retry" endpoint.

func NewRetryPayload

func NewRetryPayload(id uint) *collection.RetryPayload

NewRetryPayload builds a collection service retry endpoint payload.

func NewShowHandler

func NewShowHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewShowHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "show" endpoint.

func NewShowPayload

func NewShowPayload(id uint) *collection.ShowPayload

NewShowPayload builds a collection service show endpoint payload.

func NewWorkflowHandler

func NewWorkflowHandler(
	endpoint goa.Endpoint,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
) http.Handler

NewWorkflowHandler creates a HTTP handler which loads the HTTP request and calls the "collection" service "workflow" endpoint.

func NewWorkflowPayload

func NewWorkflowPayload(id uint) *collection.WorkflowPayload

NewWorkflowPayload builds a collection service workflow endpoint payload.

func RetryCollectionPath

func RetryCollectionPath(id uint) string

RetryCollectionPath returns the URL path to the collection service retry HTTP endpoint.

func ShowCollectionPath

func ShowCollectionPath(id uint) string

ShowCollectionPath returns the URL path to the collection service show HTTP endpoint.

func ValidateBulkRequestBody added in v0.26.0

func ValidateBulkRequestBody(body *BulkRequestBody) (err error)

ValidateBulkRequestBody runs the validations defined on BulkRequestBody

func WorkflowCollectionPath

func WorkflowCollectionPath(id uint) string

WorkflowCollectionPath returns the URL path to the collection service workflow HTTP endpoint.

Types

type BulkNotAvailableResponseBody added in v0.26.0

type BulkNotAvailableResponseBody struct {
	// Name is the name of this class of errors.
	Name string `form:"name" json:"name" xml:"name"`
	// ID is a unique identifier for this particular occurrence of the problem.
	ID string `form:"id" json:"id" xml:"id"`
	// Message is a human-readable explanation specific to this occurrence of the
	// problem.
	Message string `form:"message" json:"message" xml:"message"`
	// Is the error temporary?
	Temporary bool `form:"temporary" json:"temporary" xml:"temporary"`
	// Is the error a timeout?
	Timeout bool `form:"timeout" json:"timeout" xml:"timeout"`
	// Is the error a server-side fault?
	Fault bool `form:"fault" json:"fault" xml:"fault"`
}

BulkNotAvailableResponseBody is the type of the "collection" service "bulk" endpoint HTTP response body for the "not_available" error.

func NewBulkNotAvailableResponseBody added in v0.26.0

func NewBulkNotAvailableResponseBody(res *goa.ServiceError) *BulkNotAvailableResponseBody

NewBulkNotAvailableResponseBody builds the HTTP response body from the result of the "bulk" endpoint of the "collection" service.

type BulkNotValidResponseBody added in v0.26.0

type BulkNotValidResponseBody struct {
	// Name is the name of this class of errors.
	Name string `form:"name" json:"name" xml:"name"`
	// ID is a unique identifier for this particular occurrence of the problem.
	ID string `form:"id" json:"id" xml:"id"`
	// Message is a human-readable explanation specific to this occurrence of the
	// problem.
	Message string `form:"message" json:"message" xml:"message"`
	// Is the error temporary?
	Temporary bool `form:"temporary" json:"temporary" xml:"temporary"`
	// Is the error a timeout?
	Timeout bool `form:"timeout" json:"timeout" xml:"timeout"`
	// Is the error a server-side fault?
	Fault bool `form:"fault" json:"fault" xml:"fault"`
}

BulkNotValidResponseBody is the type of the "collection" service "bulk" endpoint HTTP response body for the "not_valid" error.

func NewBulkNotValidResponseBody added in v0.26.0

func NewBulkNotValidResponseBody(res *goa.ServiceError) *BulkNotValidResponseBody

NewBulkNotValidResponseBody builds the HTTP response body from the result of the "bulk" endpoint of the "collection" service.

type BulkRequestBody added in v0.26.0

type BulkRequestBody struct {
	Operation *string `form:"operation,omitempty" json:"operation,omitempty" xml:"operation,omitempty"`
	Status    *string `form:"status,omitempty" json:"status,omitempty" xml:"status,omitempty"`
	Size      *uint   `form:"size,omitempty" json:"size,omitempty" xml:"size,omitempty"`
}

BulkRequestBody is the type of the "collection" service "bulk" endpoint HTTP request body.

type BulkResponseBody added in v0.26.0

type BulkResponseBody struct {
	WorkflowID string `form:"workflow_id" json:"workflow_id" xml:"workflow_id"`
	RunID      string `form:"run_id" json:"run_id" xml:"run_id"`
}

BulkResponseBody is the type of the "collection" service "bulk" endpoint HTTP response body.

func NewBulkResponseBody added in v0.26.0

func NewBulkResponseBody(res *collection.BulkResult) *BulkResponseBody

NewBulkResponseBody builds the HTTP response body from the result of the "bulk" endpoint of the "collection" service.

type BulkStatusResponseBody added in v0.26.0

type BulkStatusResponseBody struct {
	Running    bool    `form:"running" json:"running" xml:"running"`
	StartedAt  *string `form:"started_at,omitempty" json:"started_at,omitempty" xml:"started_at,omitempty"`
	ClosedAt   *string `form:"closed_at,omitempty" json:"closed_at,omitempty" xml:"closed_at,omitempty"`
	Status     *string `form:"status,omitempty" json:"status,omitempty" xml:"status,omitempty"`
	WorkflowID *string `form:"workflow_id,omitempty" json:"workflow_id,omitempty" xml:"workflow_id,omitempty"`
	RunID      *string `form:"run_id,omitempty" json:"run_id,omitempty" xml:"run_id,omitempty"`
}

BulkStatusResponseBody is the type of the "collection" service "bulk_status" endpoint HTTP response body.

func NewBulkStatusResponseBody added in v0.26.0

func NewBulkStatusResponseBody(res *collection.BulkStatusResult) *BulkStatusResponseBody

NewBulkStatusResponseBody builds the HTTP response body from the result of the "bulk_status" endpoint of the "collection" service.

type CancelNotFoundResponseBody

type CancelNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

CancelNotFoundResponseBody is the type of the "collection" service "cancel" endpoint HTTP response body for the "not_found" error.

func NewCancelNotFoundResponseBody

func NewCancelNotFoundResponseBody(res *collection.CollectionNotfound) *CancelNotFoundResponseBody

NewCancelNotFoundResponseBody builds the HTTP response body from the result of the "cancel" endpoint of the "collection" service.

type CancelNotRunningResponseBody

type CancelNotRunningResponseBody struct {
	// Name is the name of this class of errors.
	Name string `form:"name" json:"name" xml:"name"`
	// ID is a unique identifier for this particular occurrence of the problem.
	ID string `form:"id" json:"id" xml:"id"`
	// Message is a human-readable explanation specific to this occurrence of the
	// problem.
	Message string `form:"message" json:"message" xml:"message"`
	// Is the error temporary?
	Temporary bool `form:"temporary" json:"temporary" xml:"temporary"`
	// Is the error a timeout?
	Timeout bool `form:"timeout" json:"timeout" xml:"timeout"`
	// Is the error a server-side fault?
	Fault bool `form:"fault" json:"fault" xml:"fault"`
}

CancelNotRunningResponseBody is the type of the "collection" service "cancel" endpoint HTTP response body for the "not_running" error.

func NewCancelNotRunningResponseBody

func NewCancelNotRunningResponseBody(res *goa.ServiceError) *CancelNotRunningResponseBody

NewCancelNotRunningResponseBody builds the HTTP response body from the result of the "cancel" endpoint of the "collection" service.

type ConnConfigurer added in v0.34.0

type ConnConfigurer struct {
	MonitorFn goahttp.ConnConfigureFunc
}

ConnConfigurer holds the websocket connection configurer functions for the streaming endpoints in "collection" service.

func NewConnConfigurer added in v0.34.0

func NewConnConfigurer(fn goahttp.ConnConfigureFunc) *ConnConfigurer

NewConnConfigurer initializes the websocket connection configurer function with fn for all the streaming endpoints in "collection" service.

type DecideNotFoundResponseBody added in v0.22.0

type DecideNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

DecideNotFoundResponseBody is the type of the "collection" service "decide" endpoint HTTP response body for the "not_found" error.

func NewDecideNotFoundResponseBody added in v0.22.0

func NewDecideNotFoundResponseBody(res *collection.CollectionNotfound) *DecideNotFoundResponseBody

NewDecideNotFoundResponseBody builds the HTTP response body from the result of the "decide" endpoint of the "collection" service.

type DecideNotValidResponseBody added in v0.22.0

type DecideNotValidResponseBody struct {
	// Name is the name of this class of errors.
	Name string `form:"name" json:"name" xml:"name"`
	// ID is a unique identifier for this particular occurrence of the problem.
	ID string `form:"id" json:"id" xml:"id"`
	// Message is a human-readable explanation specific to this occurrence of the
	// problem.
	Message string `form:"message" json:"message" xml:"message"`
	// Is the error temporary?
	Temporary bool `form:"temporary" json:"temporary" xml:"temporary"`
	// Is the error a timeout?
	Timeout bool `form:"timeout" json:"timeout" xml:"timeout"`
	// Is the error a server-side fault?
	Fault bool `form:"fault" json:"fault" xml:"fault"`
}

DecideNotValidResponseBody is the type of the "collection" service "decide" endpoint HTTP response body for the "not_valid" error.

func NewDecideNotValidResponseBody added in v0.22.0

func NewDecideNotValidResponseBody(res *goa.ServiceError) *DecideNotValidResponseBody

NewDecideNotValidResponseBody builds the HTTP response body from the result of the "decide" endpoint of the "collection" service.

type DeleteNotFoundResponseBody

type DeleteNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

DeleteNotFoundResponseBody is the type of the "collection" service "delete" endpoint HTTP response body for the "not_found" error.

func NewDeleteNotFoundResponseBody

func NewDeleteNotFoundResponseBody(res *collection.CollectionNotfound) *DeleteNotFoundResponseBody

NewDeleteNotFoundResponseBody builds the HTTP response body from the result of the "delete" endpoint of the "collection" service.

type DownloadNotFoundResponseBody added in v0.14.0

type DownloadNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

DownloadNotFoundResponseBody is the type of the "collection" service "download" endpoint HTTP response body for the "not_found" error.

func NewDownloadNotFoundResponseBody added in v0.14.0

func NewDownloadNotFoundResponseBody(res *collection.CollectionNotfound) *DownloadNotFoundResponseBody

NewDownloadNotFoundResponseBody builds the HTTP response body from the result of the "download" endpoint of the "collection" service.

type EnduroCollectionWorkflowHistoryResponseBody

type EnduroCollectionWorkflowHistoryResponseBody struct {
	// Identifier of collection
	ID *uint `form:"id,omitempty" json:"id,omitempty" xml:"id,omitempty"`
	// Type of the event
	Type *string `form:"type,omitempty" json:"type,omitempty" xml:"type,omitempty"`
	// Contents of the event
	Details any `form:"details,omitempty" json:"details,omitempty" xml:"details,omitempty"`
}

EnduroCollectionWorkflowHistoryResponseBody is used to define fields on response body types.

type EnduroCollectionWorkflowHistoryResponseBodyCollection

type EnduroCollectionWorkflowHistoryResponseBodyCollection []*EnduroCollectionWorkflowHistoryResponseBody

EnduroCollectionWorkflowHistoryResponseBodyCollection is used to define fields on response body types.

type EnduroStoredCollectionCollectionResponseBody added in v0.5.0

type EnduroStoredCollectionCollectionResponseBody []*EnduroStoredCollectionResponseBody

EnduroStoredCollectionCollectionResponseBody is used to define fields on response body types.

type EnduroStoredCollectionResponseBody added in v0.5.0

type EnduroStoredCollectionResponseBody struct {
	// Identifier of collection
	ID uint `form:"id" json:"id" xml:"id"`
	// Name of the collection
	Name *string `form:"name,omitempty" json:"name,omitempty" xml:"name,omitempty"`
	// Status of the collection
	Status string `form:"status" json:"status" xml:"status"`
	// Identifier of processing workflow
	WorkflowID *string `form:"workflow_id,omitempty" json:"workflow_id,omitempty" xml:"workflow_id,omitempty"`
	// Identifier of latest processing workflow run
	RunID *string `form:"run_id,omitempty" json:"run_id,omitempty" xml:"run_id,omitempty"`
	// Identifier of Archivematica tranfser
	TransferID *string `form:"transfer_id,omitempty" json:"transfer_id,omitempty" xml:"transfer_id,omitempty"`
	// Identifier of Archivematica AIP
	AipID *string `form:"aip_id,omitempty" json:"aip_id,omitempty" xml:"aip_id,omitempty"`
	// Identifier provided by the client
	OriginalID *string `form:"original_id,omitempty" json:"original_id,omitempty" xml:"original_id,omitempty"`
	// Identifier of Archivematica pipeline
	PipelineID *string `form:"pipeline_id,omitempty" json:"pipeline_id,omitempty" xml:"pipeline_id,omitempty"`
	// Creation datetime
	CreatedAt string `form:"created_at" json:"created_at" xml:"created_at"`
	// Start datetime
	StartedAt *string `form:"started_at,omitempty" json:"started_at,omitempty" xml:"started_at,omitempty"`
	// Completion datetime
	CompletedAt *string `form:"completed_at,omitempty" json:"completed_at,omitempty" xml:"completed_at,omitempty"`
}

EnduroStoredCollectionResponseBody is used to define fields on response body types.

type ListResponseBody added in v0.5.0

type ListResponseBody struct {
	Items      EnduroStoredCollectionCollectionResponseBody `form:"items" json:"items" xml:"items"`
	NextCursor *string                                      `form:"next_cursor,omitempty" json:"next_cursor,omitempty" xml:"next_cursor,omitempty"`
}

ListResponseBody is the type of the "collection" service "list" endpoint HTTP response body.

func NewListResponseBody added in v0.5.0

func NewListResponseBody(res *collection.ListResult) *ListResponseBody

NewListResponseBody builds the HTTP response body from the result of the "list" endpoint of the "collection" service.

type MonitorResponseBody added in v0.34.0

type MonitorResponseBody struct {
	// Identifier of collection
	ID uint `form:"id" json:"id" xml:"id"`
	// Type of the event
	Type string `form:"type" json:"type" xml:"type"`
	// Collection
	Item *EnduroStoredCollectionResponseBody `form:"item,omitempty" json:"item,omitempty" xml:"item,omitempty"`
}

MonitorResponseBody is the type of the "collection" service "monitor" endpoint HTTP response body.

func NewMonitorResponseBody added in v0.34.0

func NewMonitorResponseBody(res *collectionviews.EnduroMonitorUpdateView) *MonitorResponseBody

NewMonitorResponseBody builds the HTTP response body from the result of the "monitor" endpoint of the "collection" service.

type MonitorServerStream added in v0.34.0

type MonitorServerStream struct {
	// contains filtered or unexported fields
}

MonitorServerStream implements the collection.MonitorServerStream interface.

func (*MonitorServerStream) Close added in v0.34.0

func (s *MonitorServerStream) Close() error

Close closes the "monitor" endpoint websocket connection.

func (*MonitorServerStream) Send added in v0.34.0

Send streams instances of "collection.EnduroMonitorUpdate" to the "monitor" endpoint websocket connection.

type MountPoint

type MountPoint struct {
	// Method is the name of the service method served by the mounted HTTP handler.
	Method string
	// Verb is the HTTP method used to match requests to the mounted handler.
	Verb string
	// Pattern is the HTTP request path pattern used to match requests to the
	// mounted handler.
	Pattern string
}

MountPoint holds information about the mounted endpoints.

type RetryNotFoundResponseBody

type RetryNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

RetryNotFoundResponseBody is the type of the "collection" service "retry" endpoint HTTP response body for the "not_found" error.

func NewRetryNotFoundResponseBody

func NewRetryNotFoundResponseBody(res *collection.CollectionNotfound) *RetryNotFoundResponseBody

NewRetryNotFoundResponseBody builds the HTTP response body from the result of the "retry" endpoint of the "collection" service.

type RetryNotRunningResponseBody

type RetryNotRunningResponseBody struct {
	// Name is the name of this class of errors.
	Name string `form:"name" json:"name" xml:"name"`
	// ID is a unique identifier for this particular occurrence of the problem.
	ID string `form:"id" json:"id" xml:"id"`
	// Message is a human-readable explanation specific to this occurrence of the
	// problem.
	Message string `form:"message" json:"message" xml:"message"`
	// Is the error temporary?
	Temporary bool `form:"temporary" json:"temporary" xml:"temporary"`
	// Is the error a timeout?
	Timeout bool `form:"timeout" json:"timeout" xml:"timeout"`
	// Is the error a server-side fault?
	Fault bool `form:"fault" json:"fault" xml:"fault"`
}

RetryNotRunningResponseBody is the type of the "collection" service "retry" endpoint HTTP response body for the "not_running" error.

func NewRetryNotRunningResponseBody

func NewRetryNotRunningResponseBody(res *goa.ServiceError) *RetryNotRunningResponseBody

NewRetryNotRunningResponseBody builds the HTTP response body from the result of the "retry" endpoint of the "collection" service.

type Server

type Server struct {
	Mounts     []*MountPoint
	Monitor    http.Handler
	List       http.Handler
	Show       http.Handler
	Delete     http.Handler
	Cancel     http.Handler
	Retry      http.Handler
	Workflow   http.Handler
	Download   http.Handler
	Decide     http.Handler
	Bulk       http.Handler
	BulkStatus http.Handler
	CORS       http.Handler
}

Server lists the collection service endpoint HTTP handlers.

func New

func New(
	e *collection.Endpoints,
	mux goahttp.Muxer,
	decoder func(*http.Request) goahttp.Decoder,
	encoder func(context.Context, http.ResponseWriter) goahttp.Encoder,
	errhandler func(context.Context, http.ResponseWriter, error),
	formatter func(ctx context.Context, err error) goahttp.Statuser,
	upgrader goahttp.Upgrader,
	configurer *ConnConfigurer,
) *Server

New instantiates HTTP handlers for all the collection service endpoints using the provided encoder and decoder. The handlers are mounted on the given mux using the HTTP verb and path defined in the design. errhandler is called whenever a response fails to be encoded. formatter is used to format errors returned by the service methods prior to encoding. Both errhandler and formatter are optional and can be nil.

func (*Server) MethodNames added in v0.37.0

func (s *Server) MethodNames() []string

MethodNames returns the methods served.

func (*Server) Mount added in v0.34.0

func (s *Server) Mount(mux goahttp.Muxer)

Mount configures the mux to serve the collection endpoints.

func (*Server) Service

func (s *Server) Service() string

Service returns the name of the service served.

func (*Server) Use

func (s *Server) Use(m func(http.Handler) http.Handler)

Use wraps the server handlers with the given middleware.

type ShowNotFoundResponseBody

type ShowNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

ShowNotFoundResponseBody is the type of the "collection" service "show" endpoint HTTP response body for the "not_found" error.

func NewShowNotFoundResponseBody

func NewShowNotFoundResponseBody(res *collection.CollectionNotfound) *ShowNotFoundResponseBody

NewShowNotFoundResponseBody builds the HTTP response body from the result of the "show" endpoint of the "collection" service.

type ShowResponseBody

type ShowResponseBody struct {
	// Identifier of collection
	ID uint `form:"id" json:"id" xml:"id"`
	// Name of the collection
	Name *string `form:"name,omitempty" json:"name,omitempty" xml:"name,omitempty"`
	// Status of the collection
	Status string `form:"status" json:"status" xml:"status"`
	// Identifier of processing workflow
	WorkflowID *string `form:"workflow_id,omitempty" json:"workflow_id,omitempty" xml:"workflow_id,omitempty"`
	// Identifier of latest processing workflow run
	RunID *string `form:"run_id,omitempty" json:"run_id,omitempty" xml:"run_id,omitempty"`
	// Identifier of Archivematica tranfser
	TransferID *string `form:"transfer_id,omitempty" json:"transfer_id,omitempty" xml:"transfer_id,omitempty"`
	// Identifier of Archivematica AIP
	AipID *string `form:"aip_id,omitempty" json:"aip_id,omitempty" xml:"aip_id,omitempty"`
	// Identifier provided by the client
	OriginalID *string `form:"original_id,omitempty" json:"original_id,omitempty" xml:"original_id,omitempty"`
	// Identifier of Archivematica pipeline
	PipelineID *string `form:"pipeline_id,omitempty" json:"pipeline_id,omitempty" xml:"pipeline_id,omitempty"`
	// Creation datetime
	CreatedAt string `form:"created_at" json:"created_at" xml:"created_at"`
	// Start datetime
	StartedAt *string `form:"started_at,omitempty" json:"started_at,omitempty" xml:"started_at,omitempty"`
	// Completion datetime
	CompletedAt *string `form:"completed_at,omitempty" json:"completed_at,omitempty" xml:"completed_at,omitempty"`
}

ShowResponseBody is the type of the "collection" service "show" endpoint HTTP response body.

func NewShowResponseBody

NewShowResponseBody builds the HTTP response body from the result of the "show" endpoint of the "collection" service.

type WorkflowNotFoundResponseBody

type WorkflowNotFoundResponseBody struct {
	// Message of error
	Message string `form:"message" json:"message" xml:"message"`
	// Identifier of missing collection
	ID uint `form:"id" json:"id" xml:"id"`
}

WorkflowNotFoundResponseBody is the type of the "collection" service "workflow" endpoint HTTP response body for the "not_found" error.

func NewWorkflowNotFoundResponseBody

func NewWorkflowNotFoundResponseBody(res *collection.CollectionNotfound) *WorkflowNotFoundResponseBody

NewWorkflowNotFoundResponseBody builds the HTTP response body from the result of the "workflow" endpoint of the "collection" service.

type WorkflowResponseBody

type WorkflowResponseBody struct {
	Status  *string                                               `form:"status,omitempty" json:"status,omitempty" xml:"status,omitempty"`
	History EnduroCollectionWorkflowHistoryResponseBodyCollection `form:"history,omitempty" json:"history,omitempty" xml:"history,omitempty"`
}

WorkflowResponseBody is the type of the "collection" service "workflow" endpoint HTTP response body.

func NewWorkflowResponseBody

NewWorkflowResponseBody builds the HTTP response body from the result of the "workflow" endpoint of the "collection" service.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL