jsgrpc

package module
v0.0.0-...-a087cf3 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2015 License: MIT Imports: 10 Imported by: 0

README

jsgrpc

A trivial Go handler code allowing to register gRPC handlers on a standard HTTP/1.1

Probably it won't be needed after https://github.com/bradfitz/http2 gets into official Go and Google publishes a gRPC browser JavaScript client.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Invoke

func Invoke(ctx context.Context, method string, args, reply proto.Message, cc *grpc.ClientConn, opts ...grpc.CallOption) error

Types

type Server

type Server struct {
	// contains filtered or unexported fields
}

func NewServer

func NewServer() *Server

func (*Server) RegisterService

func (s *Server) RegisterService(sd *grpc.ServiceDesc, ss interface{})

RegisterService register a service and its implementation to the gRPC server. Called from the IDL generated code. This must be called before invoking Serve.

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)

implements http.Handler interface

Jump to

Keyboard shortcuts

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