plz

package module
v0.0.0-...-6b27e27 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2018 License: Apache-2.0 Imports: 4 Imported by: 0

README

plz.service

concrete implementation choices for plz service

http

server

func sayHello(ctx *countlog.Context, req *MyReqeust) (*MyResponse, error) {
	// ...
}
server := http.NewServer()
server.Handle("/sayHello", sayHello)
server.Start("127.0.0.1:9998")

client

var sayHello = func (ctx *countlog.Context, req *MyReqeust) (*MyResponse, error)
client := http.NewClient()
client.Handle("POST", "http://127.0.0.1:9998/sayHello", &sayHello)

// use sayHello(...) to call server

thrift

server

func sayHello(ctx *countlog.Context, req *MyReqeust) (*MyResponse, error) {
	// ...
}
server := thrift.NewServer(thrifter.Config{Protocol: thrifter.ProtocolBinary, IsFramed: true}.Froze())
server.Handle("sayHello", sayHello)
server.Start("127.0.0.1:9998")

client

var sayHello = func (ctx *countlog.Context, req *MyReqeust) (*MyResponse, error)
client := thrift.NewClient(thrifter.Config{Protocol: thrifter.ProtocolBinary, IsFramed: true}.Froze())
client.Handle("127.0.0.1:9998", "sayHello", &sayHello)

// use sayHello(...) to call server

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Cluster string
View Source
var ExportCounselor = true

will make counselor externally available after PlugAndPlay

View Source
var ExportWitch = false

will make witch externally available after PlugAndPlay

View Source
var PingUrl = ""
View Source
var PrimaryIP string

who am i, set externally

View Source
var PrimaryPort int
View Source
var ProcessInfo = map[string]interface{}{}

to be set externally, additional info about this process

View Source
var Service string

Functions

func PlugAndPlay

func PlugAndPlay()

PlugAndPlay will register the process into the grid

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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