Documentation
¶
Overview ¶
Package databus is a generated protocol buffer package.
It is generated from these files:
library/queue/databus/databus.proto
It has these top-level messages:
Header MessagePB
Index ¶
- Variables
- type Config
- type Databus
- type Header
- func (*Header) Descriptor() ([]byte, []int)
- func (m *Header) GetMetadata() map[string]string
- func (m *Header) Marshal() (dAtA []byte, err error)
- func (m *Header) MarshalTo(dAtA []byte) (int, error)
- func (*Header) ProtoMessage()
- func (m *Header) Reset()
- func (m *Header) Size() (n int)
- func (m *Header) String() string
- func (m *Header) Unmarshal(dAtA []byte) error
- type Message
- type MessagePB
- func (*MessagePB) Descriptor() ([]byte, []int)
- func (m *MessagePB) GetKey() string
- func (m *MessagePB) GetMetadata() map[string]string
- func (m *MessagePB) GetOffset() int64
- func (m *MessagePB) GetPartition() int32
- func (m *MessagePB) GetTimestamp() int64
- func (m *MessagePB) GetTopic() string
- func (m *MessagePB) GetValue() encoding_json.RawMessage
- func (m *MessagePB) Marshal() (dAtA []byte, err error)
- func (m *MessagePB) MarshalTo(dAtA []byte) (int, error)
- func (*MessagePB) ProtoMessage()
- func (m *MessagePB) Reset()
- func (m *MessagePB) Size() (n int)
- func (m *MessagePB) String() string
- func (m *MessagePB) Unmarshal(dAtA []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrAction action error. ErrAction = errors.New("action unknown") // ErrFull chan full ErrFull = errors.New("chan full") // ErrNoInstance no instances ErrNoInstance = errors.New("no databus instances found") )
View Source
var ( ErrInvalidLengthDatabus = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowDatabus = fmt.Errorf("proto: integer overflow") )
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Key string Secret string Group string Topic string Action string // shoule be "pub" or "sub" or "pubsub" Buffer int Name string // redis name, for trace Proto string Addr string Auth string Active int // pool Idle int // pool DialTimeout xtime.Duration ReadTimeout xtime.Duration WriteTimeout xtime.Duration IdleTimeout xtime.Duration Direct bool }
Config databus config.
type Databus ¶
type Databus struct {
// contains filtered or unexported fields
}
Databus databus struct.
type Header ¶
func (*Header) Descriptor ¶
func (*Header) GetMetadata ¶
func (*Header) ProtoMessage ¶
func (*Header) ProtoMessage()
type Message ¶
type Message struct { Key string `json:"key"` Value json.RawMessage `json:"value"` Topic string `json:"topic"` Partition int32 `json:"partition"` Offset int64 `json:"offset"` Timestamp int64 `json:"timestamp"` // contains filtered or unexported fields }
Message Data.
type MessagePB ¶
type MessagePB struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key"` Value encoding_json.RawMessage `protobuf:"bytes,2,opt,name=value,proto3,casttype=encoding/json.RawMessage" json:"value"` Topic string `protobuf:"bytes,3,opt,name=topic,proto3" json:"topic"` Partition int32 `protobuf:"varint,4,opt,name=partition,proto3" json:"partition"` Offset int64 `protobuf:"varint,5,opt,name=offset,proto3" json:"offset"` Timestamp int64 `protobuf:"varint,6,opt,name=timestamp,proto3" json:"timestamp"` Metadata map[string]string `` /* 140-byte string literal not displayed */ }
func (*MessagePB) Descriptor ¶
func (*MessagePB) GetMetadata ¶
func (*MessagePB) GetPartition ¶
func (*MessagePB) GetTimestamp ¶
func (*MessagePB) GetValue ¶
func (m *MessagePB) GetValue() encoding_json.RawMessage
func (*MessagePB) ProtoMessage ¶
func (*MessagePB) ProtoMessage()
Directories
¶
Path | Synopsis |
---|---|
Package databusutil provides a util for building databus based async job with single partition message aggregation and parallel consumption features.
|
Package databusutil provides a util for building databus based async job with single partition message aggregation and parallel consumption features. |
Click to show internal directories.
Click to hide internal directories.