http_rpc

package
v0.0.0-...-02cf4f6 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2019 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const ApiServiceName = "TODO: Write a name what you want .."

类似于路由

Variables

View Source
var ConfigDefault config.Config

go-os config

View Source
var Debug = false
View Source
var (
	ErrInvalidPing = errors.BadRequest(10001, "bad ...")
)

错误定义

Functions

func API

func API(w http.ResponseWriter, r *http.Request)

func APIHost

func APIHost() string

配置Host

func ApiAllowedOrigins

func ApiAllowedOrigins() []string

func Ping

func Ping(w http.ResponseWriter, r *http.Request)

func RequestToContext

func RequestToContext(r *http.Request) context.Context

http request to rpc context

func Response

func Response(w http.ResponseWriter, body json.RawMessage, err error)

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