notification

package
v2.13.1 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2024 License: Apache-2.0 Imports: 17 Imported by: 2

Documentation

Overview

Package notification is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthNotification        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowNotification          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupNotification = fmt.Errorf("proto: unexpected end of group")
)

Functions

func RegisterNotificationServiceHandler

func RegisterNotificationServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterNotificationServiceHandler registers the http handlers for service NotificationService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterNotificationServiceHandlerClient

func RegisterNotificationServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client NotificationServiceClient) error

RegisterNotificationServiceHandlerClient registers the http handlers for service NotificationService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "NotificationServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "NotificationServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "NotificationServiceClient" to call the correct interceptors.

func RegisterNotificationServiceHandlerFromEndpoint

func RegisterNotificationServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterNotificationServiceHandlerFromEndpoint is same as RegisterNotificationServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterNotificationServiceHandlerServer

func RegisterNotificationServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server NotificationServiceServer) error

RegisterNotificationServiceHandlerServer registers the http handlers for service NotificationService to "mux". UnaryRPC :call NotificationServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterNotificationServiceHandlerFromEndpoint instead.

func RegisterNotificationServiceServer

func RegisterNotificationServiceServer(s *grpc.Server, srv NotificationServiceServer)

Types

type NotificationServiceClient

type NotificationServiceClient interface {
	// List returns list of triggers
	ListTriggers(ctx context.Context, in *TriggersListRequest, opts ...grpc.CallOption) (*TriggerList, error)
	// List returns list of services
	ListServices(ctx context.Context, in *ServicesListRequest, opts ...grpc.CallOption) (*ServiceList, error)
	// List returns list of templates
	ListTemplates(ctx context.Context, in *TemplatesListRequest, opts ...grpc.CallOption) (*TemplateList, error)
}

NotificationServiceClient is the client API for NotificationService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewNotificationServiceClient

func NewNotificationServiceClient(cc *grpc.ClientConn) NotificationServiceClient

type NotificationServiceServer

type NotificationServiceServer interface {
	// List returns list of triggers
	ListTriggers(context.Context, *TriggersListRequest) (*TriggerList, error)
	// List returns list of services
	ListServices(context.Context, *ServicesListRequest) (*ServiceList, error)
	// List returns list of templates
	ListTemplates(context.Context, *TemplatesListRequest) (*TemplateList, error)
}

NotificationServiceServer is the server API for NotificationService service.

type Service

type Service struct {
	Name                 *string  `protobuf:"bytes,1,req,name=name" json:"name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Service) Descriptor

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

func (*Service) GetName

func (m *Service) GetName() string

func (*Service) Marshal

func (m *Service) Marshal() (dAtA []byte, err error)

func (*Service) MarshalTo

func (m *Service) MarshalTo(dAtA []byte) (int, error)

func (*Service) MarshalToSizedBuffer

func (m *Service) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Service) ProtoMessage

func (*Service) ProtoMessage()

func (*Service) Reset

func (m *Service) Reset()

func (*Service) Size

func (m *Service) Size() (n int)

func (*Service) String

func (m *Service) String() string

func (*Service) Unmarshal

func (m *Service) Unmarshal(dAtA []byte) error

func (*Service) XXX_DiscardUnknown

func (m *Service) XXX_DiscardUnknown()

func (*Service) XXX_Marshal

func (m *Service) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Service) XXX_Merge

func (m *Service) XXX_Merge(src proto.Message)

func (*Service) XXX_Size

func (m *Service) XXX_Size() int

func (*Service) XXX_Unmarshal

func (m *Service) XXX_Unmarshal(b []byte) error

type ServiceList

type ServiceList struct {
	Items                []*Service `protobuf:"bytes,1,rep,name=items" json:"items,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*ServiceList) Descriptor

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

func (*ServiceList) GetItems

func (m *ServiceList) GetItems() []*Service

func (*ServiceList) Marshal

func (m *ServiceList) Marshal() (dAtA []byte, err error)

func (*ServiceList) MarshalTo

func (m *ServiceList) MarshalTo(dAtA []byte) (int, error)

func (*ServiceList) MarshalToSizedBuffer

func (m *ServiceList) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ServiceList) ProtoMessage

func (*ServiceList) ProtoMessage()

func (*ServiceList) Reset

func (m *ServiceList) Reset()

func (*ServiceList) Size

func (m *ServiceList) Size() (n int)

func (*ServiceList) String

func (m *ServiceList) String() string

func (*ServiceList) Unmarshal

func (m *ServiceList) Unmarshal(dAtA []byte) error

func (*ServiceList) XXX_DiscardUnknown

func (m *ServiceList) XXX_DiscardUnknown()

func (*ServiceList) XXX_Marshal

func (m *ServiceList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ServiceList) XXX_Merge

func (m *ServiceList) XXX_Merge(src proto.Message)

func (*ServiceList) XXX_Size

func (m *ServiceList) XXX_Size() int

func (*ServiceList) XXX_Unmarshal

func (m *ServiceList) XXX_Unmarshal(b []byte) error

type ServicesListRequest

type ServicesListRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ServicesListRequest) Descriptor

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

func (*ServicesListRequest) Marshal

func (m *ServicesListRequest) Marshal() (dAtA []byte, err error)

func (*ServicesListRequest) MarshalTo

func (m *ServicesListRequest) MarshalTo(dAtA []byte) (int, error)

func (*ServicesListRequest) MarshalToSizedBuffer

func (m *ServicesListRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ServicesListRequest) ProtoMessage

func (*ServicesListRequest) ProtoMessage()

func (*ServicesListRequest) Reset

func (m *ServicesListRequest) Reset()

func (*ServicesListRequest) Size

func (m *ServicesListRequest) Size() (n int)

func (*ServicesListRequest) String

func (m *ServicesListRequest) String() string

func (*ServicesListRequest) Unmarshal

func (m *ServicesListRequest) Unmarshal(dAtA []byte) error

func (*ServicesListRequest) XXX_DiscardUnknown

func (m *ServicesListRequest) XXX_DiscardUnknown()

func (*ServicesListRequest) XXX_Marshal

func (m *ServicesListRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ServicesListRequest) XXX_Merge

func (m *ServicesListRequest) XXX_Merge(src proto.Message)

func (*ServicesListRequest) XXX_Size

func (m *ServicesListRequest) XXX_Size() int

func (*ServicesListRequest) XXX_Unmarshal

func (m *ServicesListRequest) XXX_Unmarshal(b []byte) error

type Template

type Template struct {
	Name                 *string  `protobuf:"bytes,1,req,name=name" json:"name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Template) Descriptor

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

func (*Template) GetName

func (m *Template) GetName() string

func (*Template) Marshal

func (m *Template) Marshal() (dAtA []byte, err error)

func (*Template) MarshalTo

func (m *Template) MarshalTo(dAtA []byte) (int, error)

func (*Template) MarshalToSizedBuffer

func (m *Template) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Template) ProtoMessage

func (*Template) ProtoMessage()

func (*Template) Reset

func (m *Template) Reset()

func (*Template) Size

func (m *Template) Size() (n int)

func (*Template) String

func (m *Template) String() string

func (*Template) Unmarshal

func (m *Template) Unmarshal(dAtA []byte) error

func (*Template) XXX_DiscardUnknown

func (m *Template) XXX_DiscardUnknown()

func (*Template) XXX_Marshal

func (m *Template) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Template) XXX_Merge

func (m *Template) XXX_Merge(src proto.Message)

func (*Template) XXX_Size

func (m *Template) XXX_Size() int

func (*Template) XXX_Unmarshal

func (m *Template) XXX_Unmarshal(b []byte) error

type TemplateList

type TemplateList struct {
	Items                []*Template `protobuf:"bytes,1,rep,name=items" json:"items,omitempty"`
	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
	XXX_unrecognized     []byte      `json:"-"`
	XXX_sizecache        int32       `json:"-"`
}

func (*TemplateList) Descriptor

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

func (*TemplateList) GetItems

func (m *TemplateList) GetItems() []*Template

func (*TemplateList) Marshal

func (m *TemplateList) Marshal() (dAtA []byte, err error)

func (*TemplateList) MarshalTo

func (m *TemplateList) MarshalTo(dAtA []byte) (int, error)

func (*TemplateList) MarshalToSizedBuffer

func (m *TemplateList) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TemplateList) ProtoMessage

func (*TemplateList) ProtoMessage()

func (*TemplateList) Reset

func (m *TemplateList) Reset()

func (*TemplateList) Size

func (m *TemplateList) Size() (n int)

func (*TemplateList) String

func (m *TemplateList) String() string

func (*TemplateList) Unmarshal

func (m *TemplateList) Unmarshal(dAtA []byte) error

func (*TemplateList) XXX_DiscardUnknown

func (m *TemplateList) XXX_DiscardUnknown()

func (*TemplateList) XXX_Marshal

func (m *TemplateList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TemplateList) XXX_Merge

func (m *TemplateList) XXX_Merge(src proto.Message)

func (*TemplateList) XXX_Size

func (m *TemplateList) XXX_Size() int

func (*TemplateList) XXX_Unmarshal

func (m *TemplateList) XXX_Unmarshal(b []byte) error

type TemplatesListRequest

type TemplatesListRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*TemplatesListRequest) Descriptor

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

func (*TemplatesListRequest) Marshal

func (m *TemplatesListRequest) Marshal() (dAtA []byte, err error)

func (*TemplatesListRequest) MarshalTo

func (m *TemplatesListRequest) MarshalTo(dAtA []byte) (int, error)

func (*TemplatesListRequest) MarshalToSizedBuffer

func (m *TemplatesListRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TemplatesListRequest) ProtoMessage

func (*TemplatesListRequest) ProtoMessage()

func (*TemplatesListRequest) Reset

func (m *TemplatesListRequest) Reset()

func (*TemplatesListRequest) Size

func (m *TemplatesListRequest) Size() (n int)

func (*TemplatesListRequest) String

func (m *TemplatesListRequest) String() string

func (*TemplatesListRequest) Unmarshal

func (m *TemplatesListRequest) Unmarshal(dAtA []byte) error

func (*TemplatesListRequest) XXX_DiscardUnknown

func (m *TemplatesListRequest) XXX_DiscardUnknown()

func (*TemplatesListRequest) XXX_Marshal

func (m *TemplatesListRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TemplatesListRequest) XXX_Merge

func (m *TemplatesListRequest) XXX_Merge(src proto.Message)

func (*TemplatesListRequest) XXX_Size

func (m *TemplatesListRequest) XXX_Size() int

func (*TemplatesListRequest) XXX_Unmarshal

func (m *TemplatesListRequest) XXX_Unmarshal(b []byte) error

type Trigger

type Trigger struct {
	Name                 *string  `protobuf:"bytes,1,req,name=name" json:"name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Trigger) Descriptor

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

func (*Trigger) GetName

func (m *Trigger) GetName() string

func (*Trigger) Marshal

func (m *Trigger) Marshal() (dAtA []byte, err error)

func (*Trigger) MarshalTo

func (m *Trigger) MarshalTo(dAtA []byte) (int, error)

func (*Trigger) MarshalToSizedBuffer

func (m *Trigger) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Trigger) ProtoMessage

func (*Trigger) ProtoMessage()

func (*Trigger) Reset

func (m *Trigger) Reset()

func (*Trigger) Size

func (m *Trigger) Size() (n int)

func (*Trigger) String

func (m *Trigger) String() string

func (*Trigger) Unmarshal

func (m *Trigger) Unmarshal(dAtA []byte) error

func (*Trigger) XXX_DiscardUnknown

func (m *Trigger) XXX_DiscardUnknown()

func (*Trigger) XXX_Marshal

func (m *Trigger) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Trigger) XXX_Merge

func (m *Trigger) XXX_Merge(src proto.Message)

func (*Trigger) XXX_Size

func (m *Trigger) XXX_Size() int

func (*Trigger) XXX_Unmarshal

func (m *Trigger) XXX_Unmarshal(b []byte) error

type TriggerList

type TriggerList struct {
	Items                []*Trigger `protobuf:"bytes,1,rep,name=items" json:"items,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*TriggerList) Descriptor

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

func (*TriggerList) GetItems

func (m *TriggerList) GetItems() []*Trigger

func (*TriggerList) Marshal

func (m *TriggerList) Marshal() (dAtA []byte, err error)

func (*TriggerList) MarshalTo

func (m *TriggerList) MarshalTo(dAtA []byte) (int, error)

func (*TriggerList) MarshalToSizedBuffer

func (m *TriggerList) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TriggerList) ProtoMessage

func (*TriggerList) ProtoMessage()

func (*TriggerList) Reset

func (m *TriggerList) Reset()

func (*TriggerList) Size

func (m *TriggerList) Size() (n int)

func (*TriggerList) String

func (m *TriggerList) String() string

func (*TriggerList) Unmarshal

func (m *TriggerList) Unmarshal(dAtA []byte) error

func (*TriggerList) XXX_DiscardUnknown

func (m *TriggerList) XXX_DiscardUnknown()

func (*TriggerList) XXX_Marshal

func (m *TriggerList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TriggerList) XXX_Merge

func (m *TriggerList) XXX_Merge(src proto.Message)

func (*TriggerList) XXX_Size

func (m *TriggerList) XXX_Size() int

func (*TriggerList) XXX_Unmarshal

func (m *TriggerList) XXX_Unmarshal(b []byte) error

type TriggersListRequest

type TriggersListRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*TriggersListRequest) Descriptor

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

func (*TriggersListRequest) Marshal

func (m *TriggersListRequest) Marshal() (dAtA []byte, err error)

func (*TriggersListRequest) MarshalTo

func (m *TriggersListRequest) MarshalTo(dAtA []byte) (int, error)

func (*TriggersListRequest) MarshalToSizedBuffer

func (m *TriggersListRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TriggersListRequest) ProtoMessage

func (*TriggersListRequest) ProtoMessage()

func (*TriggersListRequest) Reset

func (m *TriggersListRequest) Reset()

func (*TriggersListRequest) Size

func (m *TriggersListRequest) Size() (n int)

func (*TriggersListRequest) String

func (m *TriggersListRequest) String() string

func (*TriggersListRequest) Unmarshal

func (m *TriggersListRequest) Unmarshal(dAtA []byte) error

func (*TriggersListRequest) XXX_DiscardUnknown

func (m *TriggersListRequest) XXX_DiscardUnknown()

func (*TriggersListRequest) XXX_Marshal

func (m *TriggersListRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TriggersListRequest) XXX_Merge

func (m *TriggersListRequest) XXX_Merge(src proto.Message)

func (*TriggersListRequest) XXX_Size

func (m *TriggersListRequest) XXX_Size() int

func (*TriggersListRequest) XXX_Unmarshal

func (m *TriggersListRequest) XXX_Unmarshal(b []byte) error

type UnimplementedNotificationServiceServer

type UnimplementedNotificationServiceServer struct {
}

UnimplementedNotificationServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedNotificationServiceServer) ListServices

func (*UnimplementedNotificationServiceServer) ListTemplates

func (*UnimplementedNotificationServiceServer) ListTriggers

Jump to

Keyboard shortcuts

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