master

package
v0.0.0-...-a158562 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2021 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_chat2_proto protoreflect.FileDescriptor
View Source
var Location string
View Source
var SensorData string
View Source
var SensorID int32
View Source
var Sensortyp string
View Source
var Timestamp string

Functions

func Master

func Master()

func RegisterChatServiceServer

func RegisterChatServiceServer(s *grpc.Server, srv ChatServiceServer)

func SafeToFile

func SafeToFile(ip string, sid string, tst string)

Types

type ChatServiceClient

type ChatServiceClient interface {
	DataFromSidecar(ctx context.Context, in *CloudEvent, opts ...grpc.CallOption) (*MessageReply, error)
	HealthCheck(ctx context.Context, in *Health, opts ...grpc.CallOption) (*MessageReply, error)
}

ChatServiceClient is the client API for ChatService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type ChatServiceServer

type ChatServiceServer interface {
	DataFromSidecar(context.Context, *CloudEvent) (*MessageReply, error)
	HealthCheck(context.Context, *Health) (*MessageReply, error)
	// contains filtered or unexported methods
}

ChatServiceServer is the server API for ChatService service. All implementations must embed UnimplementedChatServiceServer for forward compatibility

type CloudEvent

type CloudEvent struct {

	// Required Attributes
	IdService   string                                          `protobuf:"bytes,1,opt,name=idService,proto3" json:"idService,omitempty"`
	Source      string                                          `protobuf:"bytes,2,opt,name=source,proto3" json:"source,omitempty"` // URI-reference
	SpecVersion string                                          `protobuf:"bytes,3,opt,name=spec_version,json=specVersion,proto3" json:"spec_version,omitempty"`
	Type        string                                          `protobuf:"bytes,4,opt,name=type,proto3" json:"type,omitempty"`
	Attributes  map[string]*CloudEvent_CloudEventAttributeValue `` /* 161-byte string literal not displayed */
	// Types that are assignable to Data:
	//	*CloudEvent_BinaryData
	//	*CloudEvent_TextData
	//	*CloudEvent_ProtoData
	Data isCloudEvent_Data `protobuf_oneof:"data"`
	// Attribute Extensions
	IdSidecar string `protobuf:"bytes,9,opt,name=idSidecar,proto3" json:"idSidecar,omitempty"`
	IpService string `protobuf:"bytes,10,opt,name=ipService,proto3" json:"ipService,omitempty"`
	IpSidecar string `protobuf:"bytes,11,opt,name=ipSidecar,proto3" json:"ipSidecar,omitempty"`
	Timestamp string `protobuf:"bytes,12,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*CloudEvent) Descriptor deprecated

func (*CloudEvent) Descriptor() ([]byte, []int)

Deprecated: Use CloudEvent.ProtoReflect.Descriptor instead.

func (*CloudEvent) GetAttributes

func (x *CloudEvent) GetAttributes() map[string]*CloudEvent_CloudEventAttributeValue

func (*CloudEvent) GetBinaryData

func (x *CloudEvent) GetBinaryData() []byte

func (*CloudEvent) GetData

func (m *CloudEvent) GetData() isCloudEvent_Data

func (*CloudEvent) GetIdService

func (x *CloudEvent) GetIdService() string

func (*CloudEvent) GetIdSidecar

func (x *CloudEvent) GetIdSidecar() string

func (*CloudEvent) GetIpService

func (x *CloudEvent) GetIpService() string

func (*CloudEvent) GetIpSidecar

func (x *CloudEvent) GetIpSidecar() string

func (*CloudEvent) GetProtoData

func (x *CloudEvent) GetProtoData() *anypb.Any

func (*CloudEvent) GetSource

func (x *CloudEvent) GetSource() string

func (*CloudEvent) GetSpecVersion

func (x *CloudEvent) GetSpecVersion() string

func (*CloudEvent) GetTextData

func (x *CloudEvent) GetTextData() string

func (*CloudEvent) GetTimestamp

func (x *CloudEvent) GetTimestamp() string

func (*CloudEvent) GetType

func (x *CloudEvent) GetType() string

func (*CloudEvent) ProtoMessage

func (*CloudEvent) ProtoMessage()

func (*CloudEvent) ProtoReflect

func (x *CloudEvent) ProtoReflect() protoreflect.Message

func (*CloudEvent) Reset

func (x *CloudEvent) Reset()

func (*CloudEvent) String

func (x *CloudEvent) String() string

type CloudEvent_BinaryData

type CloudEvent_BinaryData struct {
	//Binary data
	BinaryData []byte `protobuf:"bytes,6,opt,name=binary_data,json=binaryData,proto3,oneof"`
}

type CloudEvent_CloudEventAttributeValue

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

func (*CloudEvent_CloudEventAttributeValue) Descriptor deprecated

func (*CloudEvent_CloudEventAttributeValue) Descriptor() ([]byte, []int)

Deprecated: Use CloudEvent_CloudEventAttributeValue.ProtoReflect.Descriptor instead.

func (*CloudEvent_CloudEventAttributeValue) ProtoMessage

func (*CloudEvent_CloudEventAttributeValue) ProtoMessage()

func (*CloudEvent_CloudEventAttributeValue) ProtoReflect

func (*CloudEvent_CloudEventAttributeValue) Reset

func (*CloudEvent_CloudEventAttributeValue) String

type CloudEvent_ProtoData

type CloudEvent_ProtoData struct {
	//Protobuf Message data
	ProtoData *anypb.Any `protobuf:"bytes,8,opt,name=proto_data,json=protoData,proto3,oneof"`
}

type CloudEvent_TextData

type CloudEvent_TextData struct {
	//String data
	TextData string `protobuf:"bytes,7,opt,name=text_data,json=textData,proto3,oneof"`
}

type Health

type Health struct {
	Health string `protobuf:"bytes,1,opt,name=health,proto3" json:"health,omitempty"`
	// contains filtered or unexported fields
}

func (*Health) Descriptor deprecated

func (*Health) Descriptor() ([]byte, []int)

Deprecated: Use Health.ProtoReflect.Descriptor instead.

func (*Health) GetHealth

func (x *Health) GetHealth() string

func (*Health) ProtoMessage

func (*Health) ProtoMessage()

func (*Health) ProtoReflect

func (x *Health) ProtoReflect() protoreflect.Message

func (*Health) Reset

func (x *Health) Reset()

func (*Health) String

func (x *Health) String() string

type MessageReply

type MessageReply struct {
	Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*MessageReply) Descriptor deprecated

func (*MessageReply) Descriptor() ([]byte, []int)

Deprecated: Use MessageReply.ProtoReflect.Descriptor instead.

func (*MessageReply) GetMessage

func (x *MessageReply) GetMessage() string

func (*MessageReply) ProtoMessage

func (*MessageReply) ProtoMessage()

func (*MessageReply) ProtoReflect

func (x *MessageReply) ProtoReflect() protoreflect.Message

func (*MessageReply) Reset

func (x *MessageReply) Reset()

func (*MessageReply) String

func (x *MessageReply) String() string

type Server

type Server struct {
}

func (*Server) DataFromSidecar

func (s *Server) DataFromSidecar(ctx context.Context, message *CloudEvent) (*MessageReply, error)

func (*Server) GetMessage

func (s *Server) GetMessage() string

func (*Server) HealthCheck

func (s *Server) HealthCheck(ctx context.Context, health2 *Health) (*MessageReply, error)

type UnimplementedChatServiceServer

type UnimplementedChatServiceServer struct {
}

UnimplementedChatServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedChatServiceServer) DataFromSidecar

func (UnimplementedChatServiceServer) HealthCheck

type UnsafeChatServiceServer

type UnsafeChatServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeChatServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ChatServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

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