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

Return write buffer to pool on write error #427

Merged
merged 1 commit into from Sep 24, 2018
Merged

Return write buffer to pool on write error #427

merged 1 commit into from Sep 24, 2018

Commits on Sep 14, 2018

  1. Return write buffer to pool on write error

    Fix bug where connection did not return the write buffer to the pool
    after a write error. Add test for the same.
    
    Rename messsageWriter.fatal method to endMessage and consolidate all
    message cleanup code there. This ensures that the buffer is returned to
    pool on all code paths.
    
    Rename Conn.prepMessage to beginMessage for symmetry with endMessage.
    Move some duplicated code at calls to prepMessage to beginMessage.
    
    Bonus improvement: Adjust message and buffer size in TestWriteBufferPool
    to test that pool works with fragmented messages.
    Steven Scott committed Sep 14, 2018
    Copy the full SHA
    30af872 View commit details
    Browse the repository at this point in the history