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

Unwanted allocs in mgo #382

Open
gonejack opened this issue Nov 18, 2019 · 0 comments
Open

Unwanted allocs in mgo #382

gonejack opened this issue Nov 18, 2019 · 0 comments

Comments

@gonejack
Copy link

gonejack commented Nov 18, 2019

The code in https://github.com/globalsign/mgo/blob/master/server.go makes quite a lot of alloc as it is just 25 millisecond, it is kind of unnecessary resource waste for us since we import mgo mainly for BSON decoding.

func init() {
	coarseTime = newcoarseTimeProvider(25 * time.Millisecond)
}

pprof.alloc_objects.alloc_space.inuse_objects.inuse_space.003.pb.gz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant