Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix subscription struct #18

Merged
merged 1 commit into from
May 26, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 36 additions & 31 deletions padmin/stats_interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,37 +62,37 @@ type PartitionedTopicInternalStats struct {
}

type TopicStatistics struct {
MsgRateIn float64 `json:"msgRateIn,omitempty"`
MsgThroughputIn float64 `json:"msgThroughputIn,omitempty"`
MsgRateOut float64 `json:"msgRateOut,omitempty"`
MsgThroughputOut float64 `json:"msgThroughputOut,omitempty"`
BytesInCounter uint64 `json:"bytesInCounter,omitempty"`
MsgInCounter uint64 `json:"msgInCounter,omitempty"`
BytesOutCounter uint64 `json:"bytesOutCounter,omitempty"`
MsgOutCounter uint64 `json:"msgOutCounter,omitempty"`
AverageMsgSize float64 `json:"averageMsgSize,omitempty"`
MsgChunkPublished bool `json:"msgChunkPublished,omitempty"`
StorageSize uint64 `json:"storageSize,omitempty"`
BacklogSize uint64 `json:"backlogSize,omitempty"`
PublishRateLimitedTimes uint64 `json:"publishRateLimitedTimes,omitempty"`
EarliestMsgPublishTimeInBacklogs uint64 `json:"earliestMsgPublishTimeInBacklogs,omitempty"`
OffloadedStorageSize uint64 `json:"offloadedStorageSize,omitempty"`
LastOffloadLedgerId uint64 `json:"lastOffloadLedgerId,omitempty"`
LastOffloadSuccessTimeStamp uint64 `json:"lastOffloadSuccessTimeStamp,omitempty"`
LastOffloadFailureTimeStamp uint64 `json:"lastOffloadFailureTimeStamp,omitempty"`
OngoingTxnCount uint64 `json:"ongoingTxnCount,omitempty"`
AbortedTxnCount uint64 `json:"abortedTxnCount,omitempty"`
CommittedTxnCount uint64 `json:"committedTxnCount,omitempty"`
Publishers []string `json:"publishers,omitempty"`
WaitingPublishers uint64 `json:"waitingPublishers,omitempty"`
Subscriptions map[string]string `json:"subscriptions,omitempty"`
Replication map[string]string `json:"replication,omitempty"`
DeduplicationStatus string `json:"deduplicationStatus,omitempty"`
NonContiguousDeletedMessagesRanges uint64 `json:"nonContiguousDeletedMessagesRanges,omitempty"`
NonContiguousDeletedMessagesRangesSerializedSize uint64 `json:"nonContiguousDeletedMessagesRangesSerializedSize,omitempty"`
DelayedMessageIndexSizeInBytes uint64 `json:"delayedMessageIndexSizeInBytes,omitempty"`
Compaction Compaction `json:"compaction"`
OwnerBroker string `json:"ownerBroker,omitempty"`
MsgRateIn float64 `json:"msgRateIn,omitempty"`
MsgThroughputIn float64 `json:"msgThroughputIn,omitempty"`
MsgRateOut float64 `json:"msgRateOut,omitempty"`
MsgThroughputOut float64 `json:"msgThroughputOut,omitempty"`
BytesInCounter uint64 `json:"bytesInCounter,omitempty"`
MsgInCounter uint64 `json:"msgInCounter,omitempty"`
BytesOutCounter uint64 `json:"bytesOutCounter,omitempty"`
MsgOutCounter uint64 `json:"msgOutCounter,omitempty"`
AverageMsgSize float64 `json:"averageMsgSize,omitempty"`
MsgChunkPublished bool `json:"msgChunkPublished,omitempty"`
StorageSize uint64 `json:"storageSize,omitempty"`
BacklogSize uint64 `json:"backlogSize,omitempty"`
PublishRateLimitedTimes uint64 `json:"publishRateLimitedTimes,omitempty"`
EarliestMsgPublishTimeInBacklogs uint64 `json:"earliestMsgPublishTimeInBacklogs,omitempty"`
OffloadedStorageSize uint64 `json:"offloadedStorageSize,omitempty"`
LastOffloadLedgerId uint64 `json:"lastOffloadLedgerId,omitempty"`
LastOffloadSuccessTimeStamp uint64 `json:"lastOffloadSuccessTimeStamp,omitempty"`
LastOffloadFailureTimeStamp uint64 `json:"lastOffloadFailureTimeStamp,omitempty"`
OngoingTxnCount uint64 `json:"ongoingTxnCount,omitempty"`
AbortedTxnCount uint64 `json:"abortedTxnCount,omitempty"`
CommittedTxnCount uint64 `json:"committedTxnCount,omitempty"`
Publishers []string `json:"publishers,omitempty"`
WaitingPublishers uint64 `json:"waitingPublishers,omitempty"`
Subscriptions map[string]SubscriptionStats `json:"subscriptions,omitempty"`
Replication map[string]string `json:"replication,omitempty"`
DeduplicationStatus string `json:"deduplicationStatus,omitempty"`
NonContiguousDeletedMessagesRanges uint64 `json:"nonContiguousDeletedMessagesRanges,omitempty"`
NonContiguousDeletedMessagesRangesSerializedSize uint64 `json:"nonContiguousDeletedMessagesRangesSerializedSize,omitempty"`
DelayedMessageIndexSizeInBytes uint64 `json:"delayedMessageIndexSizeInBytes,omitempty"`
Compaction Compaction `json:"compaction"`
OwnerBroker string `json:"ownerBroker,omitempty"`
}

type CursorStats struct {
Expand Down Expand Up @@ -120,3 +120,8 @@ type Compaction struct {
LastCompactionFailedTimestamp uint64 `json:"lastCompactionFailedTimestamp,omitempty"`
LastCompactionDurationTimeInMills uint64 `json:"lastCompactionDurationTimeInMills,omitempty"`
}

type SubscriptionStats struct {
LastConsumedFlowTimestamp uint64 `json:"lastConsumedFlowTimestamp,omitempty"`
MsgBacklog int `json:"msgBacklog"`
}