fileserver

package
v0.0.0-...-69b4764 Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const APIName = "publisher"

APIName is the name of the API as defined in the design.

View Source
const APIVersion = "1.0.0"

APIVersion is the version of the API as defined in the design.

View Source
const ServiceName = "fileserver"

ServiceName is the name of the service as defined in the design. This is the same value that is set in the endpoint request contexts under the ServiceKey key.

Variables

View Source
var MethodNames = [2]string{"request-to-publish", "query-publishing-status"}

MethodNames lists the service method names as defined in the design. These are the same values that are set in the endpoint request contexts under the MethodKey key.

Functions

func NewQueryPublishingStatusEndpoint

func NewQueryPublishingStatusEndpoint(s Service) goa.Endpoint

NewQueryPublishingStatusEndpoint returns an endpoint function that calls the method "query-publishing-status" of service "fileserver".

func NewRequestToPublishEndpoint

func NewRequestToPublishEndpoint(s Service) goa.Endpoint

NewRequestToPublishEndpoint returns an endpoint function that calls the method "request-to-publish" of service "fileserver".

Types

type Client

type Client struct {
	RequestToPublishEndpoint      goa.Endpoint
	QueryPublishingStatusEndpoint goa.Endpoint
}

Client is the "fileserver" service client.

func NewClient

func NewClient(requestToPublish, queryPublishingStatus goa.Endpoint) *Client

NewClient initializes a "fileserver" service client given the endpoints.

func (*Client) QueryPublishingStatus

func (c *Client) QueryPublishingStatus(ctx context.Context, p *QueryPublishingStatusPayload) (res string, err error)

QueryPublishingStatus calls the "query-publishing-status" endpoint of the "fileserver" service.

func (*Client) RequestToPublish

func (c *Client) RequestToPublish(ctx context.Context, p *RequestToPublishPayload) (res []string, err error)

RequestToPublish calls the "request-to-publish" endpoint of the "fileserver" service.

type Endpoints

type Endpoints struct {
	RequestToPublish      goa.Endpoint
	QueryPublishingStatus goa.Endpoint
}

Endpoints wraps the "fileserver" service endpoints.

func NewEndpoints

func NewEndpoints(s Service) *Endpoints

NewEndpoints wraps the methods of the "fileserver" service with endpoints.

func (*Endpoints) Use

func (e *Endpoints) Use(m func(goa.Endpoint) goa.Endpoint)

Use applies the given middleware to all the "fileserver" service endpoints.

type QueryPublishingStatusPayload

type QueryPublishingStatusPayload struct {
	// request track id
	RequestID string
}

QueryPublishingStatusPayload is the payload type of the fileserver service query-publishing-status method.

type RequestToPublishPayload

type RequestToPublishPayload struct {
	// The full url of the pushed OCI artifact, contain the tag part. It will parse
	// the repo from it.
	ArtifactURL string
}

RequestToPublishPayload is the payload type of the fileserver service request-to-publish method.

type Service

type Service interface {
	// RequestToPublish implements request-to-publish.
	RequestToPublish(context.Context, *RequestToPublishPayload) (res []string, err error)
	// QueryPublishingStatus implements query-publishing-status.
	QueryPublishingStatus(context.Context, *QueryPublishingStatusPayload) (res string, err error)
}

Publisher service for static file server

Jump to

Keyboard shortcuts

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