Fix for Issue #41 - Slowness on Linux #358

Closed
wants to merge 4 commits into
from

Projects

None yet

4 participants

@benizi
Contributor
benizi commented Jul 16, 2012

Changes just set the TCP_NODELAY flag on TCP sockets when running on a system that has that flag.

Fixes issue #41 for me.

benizi added some commits Jul 16, 2012
@benizi benizi Set TCP_NODELAY option on the TCPSocket 44489f9
@benizi benizi Guard TCP_NODELAY with kind_of? and defined? tests
I don't have a test system that doesn't have TCP_NODELAY defined, but
presumably these conditions are enough to confine its use to systems on
which it makes sense.
cb57cfa
@jferris
Member
jferris commented Jul 19, 2012

Thanks for the patch. I'd like to get this pulled in, but we need to get it tested first. Even a straight stub/spy/mock would suffice. Otherwise, I'm pretty likely to break this while refactoring.

@MarceloCajueiro

Is there any news?

@benizi
Contributor
benizi commented Jul 24, 2012

First commit is just a minor style update. Second is an in-progress test for this. It fails in RSpec 2.6.0 (some issue with rspec-mocks) -- passes if I remove the '~> 2.6.0' condition in the gemspec. Someone more familiar w/ RSpec mocks could probably fix my test, but I'm also not positive I'm testing what needs to be tested (@jferris ?).

@danivovich
Contributor

This branch works great for me, 197 scenarios with 2556 steps (not all tests running in capybara-webkit) ran in 1/3 the time. All my tests still pass (I was using commit e677cb9 previously)

@jferris
Member
jferris commented Aug 10, 2012

Thanks. I had to make some modifications to get the tests passing for me, but this is merged now.

@jferris jferris closed this Aug 10, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment