core

package
v0.0.0-...-1d5e6b2 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2016 License: Apache-2.0 Imports: 24 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CacheConfiguration

func CacheConfiguration() error

CacheConfiguration caches configuration settings so that reading the yaml file can be avoided on future requests

func CheckSpec

func CheckSpec(spec *pb.ChaincodeSpec) error

CheckSpec to see if chaincode resides within current package capture for language.

func LoggingInit

func LoggingInit(command string)

LoggingInit is a 'hook' called at the beginning of command processing to parse logging-related options specified either on the command-line or in config files. Command-line options take precedence over config file options, and can also be passed as suitably-named environment variables. To change module logging levels at runtime call `logging.SetLevel(level, module)`. To debug this routine include logging=debug as the first term of the logging specification.

func SecurityEnabled

func SecurityEnabled() bool

SecurityEnabled returns true if security is enabled

func SetupTestConfig

func SetupTestConfig()

SetupTestConfig setup the config during test execution

func SetupTestLogging

func SetupTestLogging()

SetupTestLogging setup the logging during test execution

Types

type Config

type Config struct {
}

Config the config wrapper structure

type Devops

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

Devops implementation of Devops services

func NewDevopsServer

func NewDevopsServer(coord peer.MessageHandlerCoordinator) *Devops

NewDevopsServer creates and returns a new Devops server instance.

func (*Devops) Build

Build builds the supplied chaincode image

func (*Devops) Deploy

Deploy deploys the supplied chaincode image to the validators through a transaction

func (*Devops) EXP_ExecuteWithBinding

func (d *Devops) EXP_ExecuteWithBinding(ctx context.Context, executeWithBinding *pb.ExecuteWithBinding) (*pb.Response, error)

EXP_ExecuteWithBinding executes a transaction with a specific binding/TXHandler

func (*Devops) EXP_GetApplicationTCert

func (d *Devops) EXP_GetApplicationTCert(ctx context.Context, secret *pb.Secret) (*pb.Response, error)

EXP_GetApplicationTCert retrieves an application TCert for the supplied user

func (*Devops) EXP_PrepareForTx

func (d *Devops) EXP_PrepareForTx(ctx context.Context, secret *pb.Secret) (*pb.Response, error)

EXP_PrepareForTx prepares a binding/TXHandler pair to be used in subsequent TX

func (*Devops) EXP_ProduceSigma

func (d *Devops) EXP_ProduceSigma(ctx context.Context, sigmaInput *pb.SigmaInput) (*pb.Response, error)

EXP_ProduceSigma produces a sigma as []byte and returns in response

func (*Devops) GetTransactionResult

func (d *Devops) GetTransactionResult(ctx context.Context, txRequest *pb.TransactionRequest) (*pb.Response, error)

GetTransactionResult request a TransactionResult. The Response.Msg will contain the TransactionResult if successfully found the transaction in the chain.

func (*Devops) Invoke

func (d *Devops) Invoke(ctx context.Context, chaincodeInvocationSpec *pb.ChaincodeInvocationSpec) (*pb.Response, error)

Invoke performs the supplied invocation on the specified chaincode through a transaction

func (*Devops) Login

func (d *Devops) Login(ctx context.Context, secret *pb.Secret) (*pb.Response, error)

Login establishes the security context with the Devops service

func (*Devops) Query

func (d *Devops) Query(ctx context.Context, chaincodeInvocationSpec *pb.ChaincodeInvocationSpec) (*pb.Response, error)

Query performs the supplied query on the specified chaincode through a transaction

type PeerConnectionFSM

type PeerConnectionFSM struct {
	To  string
	FSM *fsm.FSM
}

PeerConnectionFSM example FSM for demonstration purposes.

func NewPeerConnectionFSM

func NewPeerConnectionFSM(to string) *PeerConnectionFSM

NewPeerConnectionFSM creates and returns a PeerConnectionFSM

type ServerAdmin

type ServerAdmin struct {
}

ServerAdmin implementation of the Admin service for the Peer

func NewAdminServer

func NewAdminServer() *ServerAdmin

NewAdminServer creates and returns a Admin service instance.

func (*ServerAdmin) GetStatus

func (*ServerAdmin) GetStatus(context.Context, *google_protobuf.Empty) (*pb.ServerStatus, error)

GetStatus reports the status of the server

func (*ServerAdmin) StartServer

func (*ServerAdmin) StartServer(context.Context, *google_protobuf.Empty) (*pb.ServerStatus, error)

StartServer starts the server

func (*ServerAdmin) StopServer

func (*ServerAdmin) StopServer(context.Context, *google_protobuf.Empty) (*pb.ServerStatus, error)

StopServer stops the server

type StaticDiscovery

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

StaticDiscovery is an implementation of Discovery

func NewStaticDiscovery

func NewStaticDiscovery(rootNodesString string) *StaticDiscovery

NewStaticDiscovery is a constructor of a Discovery implementation Accepts as a parameter the root node configuration, which is a single node, or a comma separated list of nodes with no spaces

func (*StaticDiscovery) GetRandomNode

func (sd *StaticDiscovery) GetRandomNode() string

GetRandomNode returns a random root node out of the nodes the discovery was initialized with

func (*StaticDiscovery) GetRootNodes

func (sd *StaticDiscovery) GetRootNodes() []string

GetRootNodes returns an array of all the nodes it was initialized with

Directories

Path Synopsis
shim
Package shim provides APIs for the chaincode to access its state variables, transaction context and call other chaincodes.
Package shim provides APIs for the chaincode to access its state variables, transaction context and call other chaincodes.
attributes/proto
Package protos is a generated protocol buffer package.
Package protos is a generated protocol buffer package.
api

Jump to

Keyboard shortcuts

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