services

package
v0.0.0-...-f47669d Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2017 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BirdServiceKey = "BirdService"
)
View Source
const (
	CatServiceKey = "CatService"
)
View Source
const (
	DogsServiceKey = "DogsService"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BirdService

type BirdService struct {
	ServiceAddress string
}

func (*BirdService) RPC

func (service *BirdService) RPC(rpcRequest *RPCRequest) (rpcResponse *RPCResponse, err error)

type CatService

type CatService struct {
	URL string
}

func (*CatService) RPC

func (service *CatService) RPC(rpcRequest *RPCRequest) (rpcResponse *RPCResponse, err error)

type DogsService

type DogsService struct {
	ServiceAddress string
	RPCQueue       string
}

func (*DogsService) RPC

func (service *DogsService) RPC(rpcRequest *RPCRequest) (rpcResponse *RPCResponse, err error)

type RPCRequest

type RPCRequest struct {
	Ctx context.Context
}

type RPCResponse

type RPCResponse struct {
	Key  string
	Data interface{}
}

type RPCService

type RPCService interface {
	RPC(*RPCRequest) (*RPCResponse, error)
}

RPCService is an abstraction of the RPC to be performed.

Jump to

Keyboard shortcuts

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