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

Review performance regressions. #1

Open
ioquatix opened this issue Apr 7, 2017 · 3 comments
Open

Review performance regressions. #1

ioquatix opened this issue Apr 7, 2017 · 3 comments

Comments

@ioquatix
Copy link
Member

ioquatix commented Apr 7, 2017

We should be both faster than Bind9 and native resolver. Check why this has regressed.

@ioquatix
Copy link
Member Author

ioquatix commented Apr 7, 2017

I think I found the cause of the problem. There is an excessive amount of logging due to $DEBUG being set in Travis. For these performance specs, perhaps it should be disabled.

@tarcieri
Copy link
Contributor

tarcieri commented Apr 7, 2017

Travis is generally an unreliable place to run benchmarks

@ioquatix
Copy link
Member Author

ioquatix commented Apr 7, 2017

I appreciate that feedback.

  • It's a relative benchmark so it's comparing two things. It's not the absolute performance, but the relative performance that indicates a regression and it's a useful check.

  • I've been running these kinds of performance checks for a long time. While I don't expect travis to be fast, I've never had any specific issue with their performance.

The problem here is the use of $DEBUG to determine a default log level here:

https://github.com/socketry/async/blob/master/lib/async/logger.rb

I think it's not a bad choice except it's causing issues in this particular case. The solution is to disable it for the performance specs e.g. before(:all) { Async.logger.level = Logger::WARN } and the appropriate one afterwards, but there is more than one performance spec, so a shared context would be good here. I actually have a shared context in another project which includes support for Benchmark, RubyProf and some other basic profiling tools, it's really easy to use. I'll probably copy it across.

eblocker pushed a commit to eblocker/async-dns that referenced this issue Feb 6, 2020
…4-dns-tweak-prototype-for-release to eblocker

* commit 'ff59291560ed97df341e36173684702c00d6aada':
  [EB1-664] pinned async version to 0.13.0
  [EB1-674] support round-robin and random querying order of name servers
  [EB1-566] optionally bind socket to host
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

2 participants