executor

package
Version: 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: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RPCExecutor

type RPCExecutor struct {
	CatService *services.CatService

	BirdsService *services.BirdService

	DogsService *services.DogsService
}

RPCExecutor is in charge of performing all the RPC requests.

func NewRPCExecutor

func NewRPCExecutor(catService *services.CatService, birdsService *services.BirdService,
	dogsService *services.DogsService) *RPCExecutor

func (RPCExecutor) GetAllPets

func (RPCexecutor RPCExecutor) GetAllPets() (result *RPCResult, err error)

GetAllPets calls the various pet RPCs in parallel, collects all the results and returns them. If there is an error, or time report and return.

type RPCResult

type RPCResult struct {
	Cats  []*catModels.Cat    `json:"cats"`
	Birds []*birdsModels.Bird `json:"birds"`
	Dogs  []*dogsModels.Dog   `json:"dogs"`
}

Source Files

Jump to

Keyboard shortcuts

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