Merge lp:~openerp-groupes/openobject-server/fix-delayed-ack into lp:openobject-server
Status: | Rejected |
---|---|
Rejected by: | Olivier Dony (Odoo) |
Proposed branch: | lp:~openerp-groupes/openobject-server/fix-delayed-ack |
Merge into: | lp:openobject-server |
Diff against target: | 0 lines |
To merge this branch: | bzr merge lp:~openerp-groupes/openobject-server/fix-delayed-ack |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Olivier Dony (Odoo) | Disapprove | ||
Review via email: mp+78937@code.launchpad.net |
This proposal supersedes a proposal from 2011-01-17.
Description of the change
Everything is in the commit message: we just need TCP_NODELAY between client and server.
Windows has 200ms ACK delay by default. If you deploy client and server on different Windows machines, clicking on administration menu (with extended view enabled) takes more than 10 seconds to complete (30+ RPC calls). Other operations are also terribly slowed down. With the patch this is simply reduced by 200ms times number of RPC calls.
Linux has apparently 40ms ACK delay by default, which is also not negligible. I suppose we never experienced the problem because we always deploy client and server on the same machine.
I also guess it is overkill to tune this further for the moment.
Well, one alternative solution would be to use persistent connections. They are now supported for xml-rpc, but not for Net-RPC yet.
By looking at the tiny_socket.py implementation, I can spot the place where the size (8bytes) is sent in a different operation than the pickled data. This means that we will now have 2 TCP packets[1]. That's increased bandwidth, already.
Isn't there any way to "flush" the socket at the end of mysend()? Shouldn't that happen automatically when the socket is closed at the end of every RPC call?
Conclusions: I cast my doubts on this patch.
[1] please confirm with wireshark