-
Notifications
You must be signed in to change notification settings - Fork 12
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
Implement maintenance methods #13
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One question but mostly LGTM.
|
||
func (m *measure) CollectGarbage() error { | ||
defer recordLatency(m.gcLatency, time.Now()) | ||
m.gcNum.Inc() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we only modify the metrics if we actually do a GC? That is, shouldn't these go inside the condition?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The count metrics are described as Total number of Datastore.[..] calls
, so my reasoning was that we want to count number of method invocations, not what they are actually doing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see... Meh.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, merge at will
7a90d29
to
fa0f7cf
Compare
Rebased, merging to avoid further conflicts |
No description provided.