Skip to content
This repository has been archived by the owner on Feb 18, 2021. It is now read-only.

replicator:only update per dest counters if the msg type is MESSAGE #255

Merged
merged 1 commit into from
Jul 19, 2017
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
2 changes: 1 addition & 1 deletion services/replicator/inconn.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ func (conn *inConnection) writeMsgsStream() {

// Update per destination metrics after msg is sent to local store (call is OpenReplicationRemoteRead)
// so they're most accurate.
if conn.metricsScope == metrics.OpenReplicationRemoteReadScope {
if conn.metricsScope == metrics.OpenReplicationRemoteReadScope && msg.GetType() == store.ReadMessageContentType_MESSAGE {
conn.destM3Client.IncCounter(conn.perDestMetricsScope, metrics.ReplicatorInConnPerDestMsgWritten)
latency := time.Duration(time.Now().UnixNano() - msg.GetMessage().Message.GetEnqueueTimeUtc())
conn.destM3Client.RecordTimer(conn.perDestMetricsScope, metrics.ReplicatorInConnPerDestMsgLatency, latency)
Expand Down