fabric-chaincode-go: github.com/hyperledger/fabric-chaincode-go/shim/internal Index | Files | Directories

package internal

import "github.com/hyperledger/fabric-chaincode-go/shim/internal"


Package Files

client.go config.go server.go

func LoadTLSConfig Uses

func LoadTLSConfig(isserver bool, key, cert, root []byte) (*tls.Config, error)

LoadTLSConfig loads the TLS configuration for the chaincode

func NewClientConn Uses

func NewClientConn(
    address string,
    tlsConf *tls.Config,
    kaOpts keepalive.ClientParameters,
) (*grpc.ClientConn, error)

NewClientConn ...

func NewRegisterClient Uses

func NewRegisterClient(conn *grpc.ClientConn) (peerpb.ChaincodeSupport_RegisterClient, error)

NewRegisterClient ...

type Config Uses

type Config struct {
    ChaincodeName string
    TLS           *tls.Config
    KaOpts        keepalive.ClientParameters

Config contains chaincode's configuration

func LoadConfig Uses

func LoadConfig() (Config, error)

LoadConfig loads the chaincode configuration

type Server Uses

type Server struct {
    Listener net.Listener
    Server   *grpc.Server

Server abstracts grpc service properties

func NewServer Uses

func NewServer(
    address string,
    tlsConf *tls.Config,
    srvKaOpts *keepalive.ServerParameters,
) (*Server, error)

NewServer creates a new implementation of a GRPC Server given a listen address

func (*Server) Start Uses

func (s *Server) Start() error

Start the server

func (*Server) Stop Uses

func (s *Server) Stop()

Stop the server


mockCode generated by counterfeiter.

Package internal imports 15 packages (graph) and is imported by 2 packages. Updated 2020-02-07. Refresh now. Tools for package owners.