httpserver

package
v0.0.0-...-9094b4a Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2019 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const HERMES_PATH = "/hermes"

Variables

This section is empty.

Functions

This section is empty.

Types

type HttpHandler

type HttpHandler struct {
	Name        string
	Router      *mux.Router
	FaasManager faasmanager.FaaSManager
	Option      *options.HermesOption
	Connections map[string]*websocket.Conn
	FaasProxy   *httputil.ReverseProxy
}

func NewHttpHandler

func NewHttpHandler(name string, option *options.HermesOption) *HttpHandler

func (*HttpHandler) ServeHTTP

func (h *HttpHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

func (*HttpHandler) Start

func (h *HttpHandler) Start() error

type HttpServer

type HttpServer struct {
	Name   string
	Ip     string
	Port   int32
	Option *options.HermesOption
	Server *http.Server
}

func NewHttpServer

func NewHttpServer(name string, ip string, port int32, option *options.HermesOption) *HttpServer

func (*HttpServer) Start

func (s *HttpServer) Start(stopCh <-chan struct{}) error

func (*HttpServer) Stop

func (s *HttpServer) Stop(stopCh <-chan struct{}) error

Jump to

Keyboard shortcuts

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