Help us shape the future of Go! Take the 2026 Go Developer Survey

mediator

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: May 9, 2023 License: Apache-2.0 Imports: 6 Imported by: 3

Documentation

Index

Constants

View Source
const (
	RouteOperationID   = "/mediator"
	RegisterPath       = RouteOperationID + "/register"
	UnregisterPath     = RouteOperationID + "/unregister"
	GetConnectionsPath = RouteOperationID + "/connections"
	ReconnectPath      = RouteOperationID + "/reconnect"
	StatusPath         = RouteOperationID + "/status"
	BatchPickupPath    = RouteOperationID + "/batchpickup"
	ReconnectAllPath   = RouteOperationID + "/reconnect-all"
)

constants for the mediator operations.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConnectionsResponse added in v0.1.5

type ConnectionsResponse struct {
	// in: body
	Params mediator.ConnectionsResponse
}

ConnectionsResponse model

Represents a Connections response message

swagger:response getConnectionsResponse

type Operation

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

Operation contains basic common operations provided by controller REST API.

func New

func New(ctx provider, autoAccept bool) (*Operation, error)

New returns new common operations rest client instance.

func (*Operation) BatchPickup

func (o *Operation) BatchPickup(rw http.ResponseWriter, req *http.Request)

BatchPickup swagger:route POST /mediator/batchpickup mediator batchPickupRequest

BatchPickup dispatches pending messages for given connection.

Responses:

default: genericError
200: batchPickupResponse

func (*Operation) Connections added in v0.1.5

func (o *Operation) Connections(rw http.ResponseWriter, req *http.Request)

Connections swagger:route GET /mediator/connections mediator connectionsRequest

Retrieves the router`s connections.

Responses:

default: genericError
200: getConnectionsResponse

func (*Operation) GetRESTHandlers

func (o *Operation) GetRESTHandlers() []rest.Handler

GetRESTHandlers get all controller API handler available for this service.

func (*Operation) Reconnect

func (o *Operation) Reconnect(rw http.ResponseWriter, req *http.Request)

Reconnect swagger:route POST /mediator/reconnect mediator reconnectRouteRequest

Reconnect the agent with the router to re-establish lost connection.

Responses:

default: genericError

func (*Operation) ReconnectAll added in v0.1.5

func (o *Operation) ReconnectAll(rw http.ResponseWriter, req *http.Request)

ReconnectAll swagger:route GET /mediator/reconnect-all mediator reconnectAll

Re-establishes network connections for all mediator connections.

Responses:

default: genericError

func (*Operation) Register

func (o *Operation) Register(rw http.ResponseWriter, req *http.Request)

Register swagger:route POST /mediator/register mediator registerRouteRequest

Registers the agent with the router.

Responses:

default: genericError
200: registerRouteRes

func (*Operation) Status

func (o *Operation) Status(rw http.ResponseWriter, req *http.Request)

Status swagger:route POST /mediator/status mediator statusRequest

Status returns details about pending messages for given connection.

Responses:

default: genericError
200: statusResponse

func (*Operation) Unregister

func (o *Operation) Unregister(rw http.ResponseWriter, req *http.Request)

Unregister swagger:route DELETE /mediator/unregister mediator unregisterRouter

Unregisters the agent with the router.

Responses:

default: genericError
200: unregisterRouteRes

Jump to

Keyboard shortcuts

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