Documentation ¶
Index ¶
- func CalculateMsgLength(message pulsar.Message) int
- func ConvertMap2Headers(m map[string]string) []*codec.Header
- func DebugKafkaTopicMatch(s set.Set[string], topic string) bool
- func DebugPulsarPartitionTopicMatch(s set.Set[string], partitionTopic string) bool
- func DebugTopicMatch(kSet, pSet set.Set[string], kTopic, pTopic string) bool
- func GetLatestMsgId(partitionedTopic string, client *padmin.PulsarAdmin) (*padmin.MessageId, error)
- func PartitionedTopic(topic string, partition int) string
- func ReadEarliestMsg(partitionedTopic string, maxWaitMs int, pulsarClient pulsar.Client) (pulsar.Message, error)
- func ReadLatestMsg(partitionedTopic string, maxWaitMs int, messageId *padmin.MessageId, ...) (pulsar.Message, error)
- type KeyBasedRateLimiter
- type PartitionedTopicInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CalculateMsgLength ¶
func GetLatestMsgId ¶
func PartitionedTopic ¶
func ReadEarliestMsg ¶
Types ¶
type KeyBasedRateLimiter ¶
type KeyBasedRateLimiter struct {
// contains filtered or unexported fields
}
func NewKeyBasedRateLimiter ¶
func NewKeyBasedRateLimiter(seconds, times int) *KeyBasedRateLimiter
func (*KeyBasedRateLimiter) Acquire ¶
func (k *KeyBasedRateLimiter) Acquire(key string) bool
func (*KeyBasedRateLimiter) Clean ¶
func (k *KeyBasedRateLimiter) Clean(key string)
type PartitionedTopicInfo ¶
func GetTenantNamespaceTopicFromPartitionedPrefix ¶
func GetTenantNamespaceTopicFromPartitionedPrefix(str string) (info PartitionedTopicInfo, err error)
Click to show internal directories.
Click to hide internal directories.