github.com/kchristidis/fabric@v1.0.4-0.20171028114726-837acd08cde1/protos/peer/admin.pb.go (about)

     1  // Code generated by protoc-gen-go. DO NOT EDIT.
     2  // source: peer/admin.proto
     3  
     4  /*
     5  Package peer is a generated protocol buffer package.
     6  
     7  It is generated from these files:
     8  	peer/admin.proto
     9  	peer/chaincode.proto
    10  	peer/chaincode_event.proto
    11  	peer/chaincode_shim.proto
    12  	peer/configuration.proto
    13  	peer/events.proto
    14  	peer/peer.proto
    15  	peer/proposal.proto
    16  	peer/proposal_response.proto
    17  	peer/query.proto
    18  	peer/signed_cc_dep_spec.proto
    19  	peer/transaction.proto
    20  
    21  It has these top-level messages:
    22  	ServerStatus
    23  	LogLevelRequest
    24  	LogLevelResponse
    25  	ChaincodeID
    26  	ChaincodeInput
    27  	ChaincodeSpec
    28  	ChaincodeDeploymentSpec
    29  	ChaincodeInvocationSpec
    30  	ChaincodeEvent
    31  	ChaincodeMessage
    32  	PutStateInfo
    33  	GetStateByRange
    34  	GetQueryResult
    35  	GetHistoryForKey
    36  	QueryStateNext
    37  	QueryStateClose
    38  	QueryResultBytes
    39  	QueryResponse
    40  	AnchorPeers
    41  	AnchorPeer
    42  	ChaincodeReg
    43  	Interest
    44  	Register
    45  	Rejection
    46  	Unregister
    47  	SignedEvent
    48  	Event
    49  	PeerID
    50  	PeerEndpoint
    51  	SignedProposal
    52  	Proposal
    53  	ChaincodeHeaderExtension
    54  	ChaincodeProposalPayload
    55  	ChaincodeAction
    56  	ProposalResponse
    57  	Response
    58  	ProposalResponsePayload
    59  	Endorsement
    60  	ChaincodeQueryResponse
    61  	ChaincodeInfo
    62  	ChannelQueryResponse
    63  	ChannelInfo
    64  	SignedChaincodeDeploymentSpec
    65  	SignedTransaction
    66  	ProcessedTransaction
    67  	Transaction
    68  	TransactionAction
    69  	ChaincodeActionPayload
    70  	ChaincodeEndorsedAction
    71  */
    72  package peer
    73  
    74  import proto "github.com/golang/protobuf/proto"
    75  import fmt "fmt"
    76  import math "math"
    77  import google_protobuf "github.com/golang/protobuf/ptypes/empty"
    78  
    79  import (
    80  	context "golang.org/x/net/context"
    81  	grpc "google.golang.org/grpc"
    82  )
    83  
    84  // Reference imports to suppress errors if they are not otherwise used.
    85  var _ = proto.Marshal
    86  var _ = fmt.Errorf
    87  var _ = math.Inf
    88  
    89  // This is a compile-time assertion to ensure that this generated file
    90  // is compatible with the proto package it is being compiled against.
    91  // A compilation error at this line likely means your copy of the
    92  // proto package needs to be updated.
    93  const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
    94  
    95  type ServerStatus_StatusCode int32
    96  
    97  const (
    98  	ServerStatus_UNDEFINED ServerStatus_StatusCode = 0
    99  	ServerStatus_STARTED   ServerStatus_StatusCode = 1
   100  	ServerStatus_STOPPED   ServerStatus_StatusCode = 2
   101  	ServerStatus_PAUSED    ServerStatus_StatusCode = 3
   102  	ServerStatus_ERROR     ServerStatus_StatusCode = 4
   103  	ServerStatus_UNKNOWN   ServerStatus_StatusCode = 5
   104  )
   105  
   106  var ServerStatus_StatusCode_name = map[int32]string{
   107  	0: "UNDEFINED",
   108  	1: "STARTED",
   109  	2: "STOPPED",
   110  	3: "PAUSED",
   111  	4: "ERROR",
   112  	5: "UNKNOWN",
   113  }
   114  var ServerStatus_StatusCode_value = map[string]int32{
   115  	"UNDEFINED": 0,
   116  	"STARTED":   1,
   117  	"STOPPED":   2,
   118  	"PAUSED":    3,
   119  	"ERROR":     4,
   120  	"UNKNOWN":   5,
   121  }
   122  
   123  func (x ServerStatus_StatusCode) String() string {
   124  	return proto.EnumName(ServerStatus_StatusCode_name, int32(x))
   125  }
   126  func (ServerStatus_StatusCode) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0, 0} }
   127  
   128  type ServerStatus struct {
   129  	Status ServerStatus_StatusCode `protobuf:"varint,1,opt,name=status,enum=protos.ServerStatus_StatusCode" json:"status,omitempty"`
   130  }
   131  
   132  func (m *ServerStatus) Reset()                    { *m = ServerStatus{} }
   133  func (m *ServerStatus) String() string            { return proto.CompactTextString(m) }
   134  func (*ServerStatus) ProtoMessage()               {}
   135  func (*ServerStatus) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
   136  
   137  func (m *ServerStatus) GetStatus() ServerStatus_StatusCode {
   138  	if m != nil {
   139  		return m.Status
   140  	}
   141  	return ServerStatus_UNDEFINED
   142  }
   143  
   144  type LogLevelRequest struct {
   145  	LogModule string `protobuf:"bytes,1,opt,name=log_module,json=logModule" json:"log_module,omitempty"`
   146  	LogLevel  string `protobuf:"bytes,2,opt,name=log_level,json=logLevel" json:"log_level,omitempty"`
   147  }
   148  
   149  func (m *LogLevelRequest) Reset()                    { *m = LogLevelRequest{} }
   150  func (m *LogLevelRequest) String() string            { return proto.CompactTextString(m) }
   151  func (*LogLevelRequest) ProtoMessage()               {}
   152  func (*LogLevelRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
   153  
   154  func (m *LogLevelRequest) GetLogModule() string {
   155  	if m != nil {
   156  		return m.LogModule
   157  	}
   158  	return ""
   159  }
   160  
   161  func (m *LogLevelRequest) GetLogLevel() string {
   162  	if m != nil {
   163  		return m.LogLevel
   164  	}
   165  	return ""
   166  }
   167  
   168  type LogLevelResponse struct {
   169  	LogModule string `protobuf:"bytes,1,opt,name=log_module,json=logModule" json:"log_module,omitempty"`
   170  	LogLevel  string `protobuf:"bytes,2,opt,name=log_level,json=logLevel" json:"log_level,omitempty"`
   171  }
   172  
   173  func (m *LogLevelResponse) Reset()                    { *m = LogLevelResponse{} }
   174  func (m *LogLevelResponse) String() string            { return proto.CompactTextString(m) }
   175  func (*LogLevelResponse) ProtoMessage()               {}
   176  func (*LogLevelResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
   177  
   178  func (m *LogLevelResponse) GetLogModule() string {
   179  	if m != nil {
   180  		return m.LogModule
   181  	}
   182  	return ""
   183  }
   184  
   185  func (m *LogLevelResponse) GetLogLevel() string {
   186  	if m != nil {
   187  		return m.LogLevel
   188  	}
   189  	return ""
   190  }
   191  
   192  func init() {
   193  	proto.RegisterType((*ServerStatus)(nil), "protos.ServerStatus")
   194  	proto.RegisterType((*LogLevelRequest)(nil), "protos.LogLevelRequest")
   195  	proto.RegisterType((*LogLevelResponse)(nil), "protos.LogLevelResponse")
   196  	proto.RegisterEnum("protos.ServerStatus_StatusCode", ServerStatus_StatusCode_name, ServerStatus_StatusCode_value)
   197  }
   198  
   199  // Reference imports to suppress errors if they are not otherwise used.
   200  var _ context.Context
   201  var _ grpc.ClientConn
   202  
   203  // This is a compile-time assertion to ensure that this generated file
   204  // is compatible with the grpc package it is being compiled against.
   205  const _ = grpc.SupportPackageIsVersion4
   206  
   207  // Client API for Admin service
   208  
   209  type AdminClient interface {
   210  	// Return the serve status.
   211  	GetStatus(ctx context.Context, in *google_protobuf.Empty, opts ...grpc.CallOption) (*ServerStatus, error)
   212  	StartServer(ctx context.Context, in *google_protobuf.Empty, opts ...grpc.CallOption) (*ServerStatus, error)
   213  	GetModuleLogLevel(ctx context.Context, in *LogLevelRequest, opts ...grpc.CallOption) (*LogLevelResponse, error)
   214  	SetModuleLogLevel(ctx context.Context, in *LogLevelRequest, opts ...grpc.CallOption) (*LogLevelResponse, error)
   215  	RevertLogLevels(ctx context.Context, in *google_protobuf.Empty, opts ...grpc.CallOption) (*google_protobuf.Empty, error)
   216  }
   217  
   218  type adminClient struct {
   219  	cc *grpc.ClientConn
   220  }
   221  
   222  func NewAdminClient(cc *grpc.ClientConn) AdminClient {
   223  	return &adminClient{cc}
   224  }
   225  
   226  func (c *adminClient) GetStatus(ctx context.Context, in *google_protobuf.Empty, opts ...grpc.CallOption) (*ServerStatus, error) {
   227  	out := new(ServerStatus)
   228  	err := grpc.Invoke(ctx, "/protos.Admin/GetStatus", in, out, c.cc, opts...)
   229  	if err != nil {
   230  		return nil, err
   231  	}
   232  	return out, nil
   233  }
   234  
   235  func (c *adminClient) StartServer(ctx context.Context, in *google_protobuf.Empty, opts ...grpc.CallOption) (*ServerStatus, error) {
   236  	out := new(ServerStatus)
   237  	err := grpc.Invoke(ctx, "/protos.Admin/StartServer", in, out, c.cc, opts...)
   238  	if err != nil {
   239  		return nil, err
   240  	}
   241  	return out, nil
   242  }
   243  
   244  func (c *adminClient) GetModuleLogLevel(ctx context.Context, in *LogLevelRequest, opts ...grpc.CallOption) (*LogLevelResponse, error) {
   245  	out := new(LogLevelResponse)
   246  	err := grpc.Invoke(ctx, "/protos.Admin/GetModuleLogLevel", in, out, c.cc, opts...)
   247  	if err != nil {
   248  		return nil, err
   249  	}
   250  	return out, nil
   251  }
   252  
   253  func (c *adminClient) SetModuleLogLevel(ctx context.Context, in *LogLevelRequest, opts ...grpc.CallOption) (*LogLevelResponse, error) {
   254  	out := new(LogLevelResponse)
   255  	err := grpc.Invoke(ctx, "/protos.Admin/SetModuleLogLevel", in, out, c.cc, opts...)
   256  	if err != nil {
   257  		return nil, err
   258  	}
   259  	return out, nil
   260  }
   261  
   262  func (c *adminClient) RevertLogLevels(ctx context.Context, in *google_protobuf.Empty, opts ...grpc.CallOption) (*google_protobuf.Empty, error) {
   263  	out := new(google_protobuf.Empty)
   264  	err := grpc.Invoke(ctx, "/protos.Admin/RevertLogLevels", in, out, c.cc, opts...)
   265  	if err != nil {
   266  		return nil, err
   267  	}
   268  	return out, nil
   269  }
   270  
   271  // Server API for Admin service
   272  
   273  type AdminServer interface {
   274  	// Return the serve status.
   275  	GetStatus(context.Context, *google_protobuf.Empty) (*ServerStatus, error)
   276  	StartServer(context.Context, *google_protobuf.Empty) (*ServerStatus, error)
   277  	GetModuleLogLevel(context.Context, *LogLevelRequest) (*LogLevelResponse, error)
   278  	SetModuleLogLevel(context.Context, *LogLevelRequest) (*LogLevelResponse, error)
   279  	RevertLogLevels(context.Context, *google_protobuf.Empty) (*google_protobuf.Empty, error)
   280  }
   281  
   282  func RegisterAdminServer(s *grpc.Server, srv AdminServer) {
   283  	s.RegisterService(&_Admin_serviceDesc, srv)
   284  }
   285  
   286  func _Admin_GetStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   287  	in := new(google_protobuf.Empty)
   288  	if err := dec(in); err != nil {
   289  		return nil, err
   290  	}
   291  	if interceptor == nil {
   292  		return srv.(AdminServer).GetStatus(ctx, in)
   293  	}
   294  	info := &grpc.UnaryServerInfo{
   295  		Server:     srv,
   296  		FullMethod: "/protos.Admin/GetStatus",
   297  	}
   298  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   299  		return srv.(AdminServer).GetStatus(ctx, req.(*google_protobuf.Empty))
   300  	}
   301  	return interceptor(ctx, in, info, handler)
   302  }
   303  
   304  func _Admin_StartServer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   305  	in := new(google_protobuf.Empty)
   306  	if err := dec(in); err != nil {
   307  		return nil, err
   308  	}
   309  	if interceptor == nil {
   310  		return srv.(AdminServer).StartServer(ctx, in)
   311  	}
   312  	info := &grpc.UnaryServerInfo{
   313  		Server:     srv,
   314  		FullMethod: "/protos.Admin/StartServer",
   315  	}
   316  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   317  		return srv.(AdminServer).StartServer(ctx, req.(*google_protobuf.Empty))
   318  	}
   319  	return interceptor(ctx, in, info, handler)
   320  }
   321  
   322  func _Admin_GetModuleLogLevel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   323  	in := new(LogLevelRequest)
   324  	if err := dec(in); err != nil {
   325  		return nil, err
   326  	}
   327  	if interceptor == nil {
   328  		return srv.(AdminServer).GetModuleLogLevel(ctx, in)
   329  	}
   330  	info := &grpc.UnaryServerInfo{
   331  		Server:     srv,
   332  		FullMethod: "/protos.Admin/GetModuleLogLevel",
   333  	}
   334  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   335  		return srv.(AdminServer).GetModuleLogLevel(ctx, req.(*LogLevelRequest))
   336  	}
   337  	return interceptor(ctx, in, info, handler)
   338  }
   339  
   340  func _Admin_SetModuleLogLevel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   341  	in := new(LogLevelRequest)
   342  	if err := dec(in); err != nil {
   343  		return nil, err
   344  	}
   345  	if interceptor == nil {
   346  		return srv.(AdminServer).SetModuleLogLevel(ctx, in)
   347  	}
   348  	info := &grpc.UnaryServerInfo{
   349  		Server:     srv,
   350  		FullMethod: "/protos.Admin/SetModuleLogLevel",
   351  	}
   352  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   353  		return srv.(AdminServer).SetModuleLogLevel(ctx, req.(*LogLevelRequest))
   354  	}
   355  	return interceptor(ctx, in, info, handler)
   356  }
   357  
   358  func _Admin_RevertLogLevels_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   359  	in := new(google_protobuf.Empty)
   360  	if err := dec(in); err != nil {
   361  		return nil, err
   362  	}
   363  	if interceptor == nil {
   364  		return srv.(AdminServer).RevertLogLevels(ctx, in)
   365  	}
   366  	info := &grpc.UnaryServerInfo{
   367  		Server:     srv,
   368  		FullMethod: "/protos.Admin/RevertLogLevels",
   369  	}
   370  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   371  		return srv.(AdminServer).RevertLogLevels(ctx, req.(*google_protobuf.Empty))
   372  	}
   373  	return interceptor(ctx, in, info, handler)
   374  }
   375  
   376  var _Admin_serviceDesc = grpc.ServiceDesc{
   377  	ServiceName: "protos.Admin",
   378  	HandlerType: (*AdminServer)(nil),
   379  	Methods: []grpc.MethodDesc{
   380  		{
   381  			MethodName: "GetStatus",
   382  			Handler:    _Admin_GetStatus_Handler,
   383  		},
   384  		{
   385  			MethodName: "StartServer",
   386  			Handler:    _Admin_StartServer_Handler,
   387  		},
   388  		{
   389  			MethodName: "GetModuleLogLevel",
   390  			Handler:    _Admin_GetModuleLogLevel_Handler,
   391  		},
   392  		{
   393  			MethodName: "SetModuleLogLevel",
   394  			Handler:    _Admin_SetModuleLogLevel_Handler,
   395  		},
   396  		{
   397  			MethodName: "RevertLogLevels",
   398  			Handler:    _Admin_RevertLogLevels_Handler,
   399  		},
   400  	},
   401  	Streams:  []grpc.StreamDesc{},
   402  	Metadata: "peer/admin.proto",
   403  }
   404  
   405  func init() { proto.RegisterFile("peer/admin.proto", fileDescriptor0) }
   406  
   407  var fileDescriptor0 = []byte{
   408  	// 418 bytes of a gzipped FileDescriptorProto
   409  	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xac, 0x93, 0x41, 0x6f, 0xd3, 0x30,
   410  	0x14, 0xc7, 0x9b, 0x42, 0x0b, 0x79, 0x1b, 0xcc, 0x58, 0x08, 0xaa, 0x4e, 0x08, 0x94, 0x13, 0x5c,
   411  	0x1c, 0x69, 0x1c, 0x38, 0x20, 0x0e, 0xdd, 0x12, 0x06, 0x62, 0x4b, 0x23, 0x67, 0x15, 0x02, 0x09,
   412  	0x4d, 0x49, 0xf3, 0xe6, 0x55, 0x38, 0x73, 0xb0, 0x9d, 0x4a, 0xfb, 0x3a, 0x7c, 0x2e, 0x3e, 0x0c,
   413  	0x4a, 0xdc, 0x68, 0x13, 0xb0, 0x03, 0x82, 0x93, 0xf3, 0xde, 0xfb, 0xff, 0xff, 0x71, 0x7e, 0xb1,
   414  	0x81, 0xd4, 0x88, 0x3a, 0xcc, 0xcb, 0x6a, 0x75, 0xc1, 0x6a, 0xad, 0xac, 0xa2, 0xe3, 0x6e, 0x31,
   415  	0xd3, 0x5d, 0xa1, 0x94, 0x90, 0x18, 0x76, 0x65, 0xd1, 0x9c, 0x85, 0x58, 0xd5, 0xf6, 0xd2, 0x89,
   416  	0x82, 0xef, 0x1e, 0x6c, 0x67, 0xa8, 0xd7, 0xa8, 0x33, 0x9b, 0xdb, 0xc6, 0xd0, 0x57, 0x30, 0x36,
   417  	0xdd, 0xd3, 0xc4, 0x7b, 0xe6, 0x3d, 0xbf, 0xbf, 0xf7, 0xd4, 0x09, 0x0d, 0xbb, 0xae, 0x62, 0x6e,
   418  	0x39, 0x50, 0x25, 0xf2, 0x8d, 0x3c, 0xf8, 0x04, 0x70, 0xd5, 0xa5, 0xf7, 0xc0, 0x5f, 0x24, 0x51,
   419  	0xfc, 0xf6, 0x7d, 0x12, 0x47, 0x64, 0x40, 0xb7, 0xe0, 0x4e, 0x76, 0x32, 0xe3, 0x27, 0x71, 0x44,
   420  	0x3c, 0x57, 0xcc, 0xd3, 0x34, 0x8e, 0xc8, 0x90, 0x02, 0x8c, 0xd3, 0xd9, 0x22, 0x8b, 0x23, 0x72,
   421  	0x8b, 0xfa, 0x30, 0x8a, 0x39, 0x9f, 0x73, 0x72, 0xbb, 0xd5, 0x2c, 0x92, 0x0f, 0xc9, 0xfc, 0x63,
   422  	0x42, 0x46, 0xc1, 0x31, 0xec, 0x1c, 0x29, 0x71, 0x84, 0x6b, 0x94, 0x1c, 0xbf, 0x35, 0x68, 0x2c,
   423  	0x7d, 0x02, 0x20, 0x95, 0x38, 0xad, 0x54, 0xd9, 0x48, 0xec, 0xb6, 0xea, 0x73, 0x5f, 0x2a, 0x71,
   424  	0xdc, 0x35, 0xe8, 0x2e, 0xb4, 0xc5, 0xa9, 0x6c, 0x2d, 0x93, 0x61, 0x37, 0xbd, 0x2b, 0x37, 0x11,
   425  	0x41, 0x02, 0xe4, 0x2a, 0xce, 0xd4, 0xea, 0xc2, 0xe0, 0xbf, 0xe4, 0xed, 0xfd, 0x18, 0xc2, 0x68,
   426  	0xd6, 0x82, 0xa7, 0xaf, 0xc1, 0x3f, 0x44, 0xbb, 0x21, 0xf9, 0x88, 0x39, 0xf0, 0xac, 0x07, 0xcf,
   427  	0xe2, 0x16, 0xfc, 0xf4, 0xe1, 0x9f, 0x88, 0x06, 0x03, 0xfa, 0x06, 0xb6, 0x32, 0x9b, 0x6b, 0xeb,
   428  	0xda, 0x7f, 0x6d, 0x7f, 0x07, 0x0f, 0x0e, 0xd1, 0xba, 0xfd, 0xf6, 0x9f, 0x47, 0x1f, 0xf7, 0xe2,
   429  	0x5f, 0xf8, 0x4d, 0x27, 0xbf, 0x0f, 0x1c, 0x09, 0x97, 0x94, 0xfd, 0x9f, 0xa4, 0x03, 0xd8, 0xe1,
   430  	0xb8, 0x46, 0x6d, 0xfb, 0xd9, 0xcd, 0x54, 0x6e, 0xe8, 0x07, 0x83, 0xfd, 0x2f, 0x10, 0x28, 0x2d,
   431  	0xd8, 0xf9, 0x65, 0x8d, 0x5a, 0x62, 0x29, 0x50, 0xb3, 0xb3, 0xbc, 0xd0, 0xab, 0x65, 0xff, 0xe2,
   432  	0xf6, 0xe4, 0xef, 0x6f, 0x77, 0x7f, 0x20, 0xcd, 0x97, 0x5f, 0x73, 0x81, 0x9f, 0x5f, 0x88, 0x95,
   433  	0x3d, 0x6f, 0x0a, 0xb6, 0x54, 0x55, 0x78, 0xcd, 0x18, 0x3a, 0xa3, 0xbb, 0x0a, 0x26, 0x6c, 0x8d,
   434  	0x85, 0xbb, 0x26, 0x2f, 0x7f, 0x06, 0x00, 0x00, 0xff, 0xff, 0x6e, 0xe6, 0xef, 0xb7, 0x41, 0x03,
   435  	0x00, 0x00,
   436  }