Adding json tags for ShardInfo struct to reuse for docstore
@@ -242,21 +242,21 @@ type (
// ShardInfo describes a shard
ShardInfo struct {
- ShardID int
- Owner string
- RangeID int64
- StolenSinceRenew int
- UpdatedAt time.Time
- ReplicationAckLevel int64
- ReplicationDLQAckLevel map[string]int64
- TransferAckLevel int64
- TimerAckLevel time.Time
- ClusterTransferAckLevel map[string]int64
- ClusterTimerAckLevel map[string]time.Time
+ ShardID int `json:"shard_id"`
+ Owner string `json:"owner"`
+ RangeID int64 `json:"range_id"`
+ StolenSinceRenew int `json:"stolen_since_renew"`
+ UpdatedAt time.Time `json:"updated_at"`
+ ReplicationAckLevel int64 `json:"replication_ack_level"`
+ ReplicationDLQAckLevel map[string]int64 `json:"replication_dlq_ack_level"`
+ TransferAckLevel int64 `json:"transfer_ack_level"`
+ TimerAckLevel time.Time `json:"timer_ack_level"`
+ ClusterTransferAckLevel map[string]int64 `json:"cluster_transfer_ack_level"`
+ ClusterTimerAckLevel map[string]time.Time `json:"cluster_timer_ack_level"`
TransferFailoverLevels map[string]TransferFailoverLevel // uuid -> TransferFailoverLevel
TimerFailoverLevels map[string]TimerFailoverLevel // uuid -> TimerFailoverLevel
- ClusterReplicationLevel map[string]int64 // cluster -> last replicated taskID
- DomainNotificationVersion int64
+ ClusterReplicationLevel map[string]int64 `json:"cluster_replication_level"`
+ DomainNotificationVersion int64 `json:"domain_notification_version"`
}
// TransferFailoverLevel contains corresponding start / end level
