Merge branch 'grammarly-master'
Merge pull request #36 from grammarly/custom_encoder

Custom encoder
Merge pull request #37 from grammarly/master

Update rebar to 2.5.1 (fixes work under erlang.mk)
cqerl_client: Really update #client_state{} in the sleep state

The response frame pattern in the sleep-state clause of
cqerl_client:handle_info/3 was out of sync with the return value of
cqerl_protocol:response_frame/2.  As a result, the available_slots and
queries fields in #client_state{} were not being updated as intended.
cqerl_client: Fix sleep-state message fragment handling

The the sleep-state clause of cqerl_client:handle_info/3 did not account
for the possiblity that BinaryMsg can contain the final fragment of one
message and the initial fragment of the next.  In this situation, it will
discard the initial fragment, causing the next fragment to become stuck
at the front of #client_state.delayed, and preventing the client from
decoding any more frames.
cqerl_client: Really update #client_state{} in the sleep state

The response frame pattern in the sleep-state clause of
cqerl_client:handle_info/3 was out of sync with the return value of
cqerl_protocol:response_frame/2.  As a result, the available_slots and
queries fields in #client_state{} were not being updated as intended.
cqerl_client: Fix sleep-state message fragment handling

The the sleep-state clause of cqerl_client:handle_info/3 did not account
for the possiblity that BinaryMsg can contain the final fragment of one
message and the initial fragment of the next.  In this situation, it will
discard the initial fragment, causing the next fragment to become stuck
at the front of #client_state.delayed, and preventing the client from
decoding any more frames.
Merge pull request #40 from layerhq/client-sleep-state-fixes

Fix a couple of message-handling in cqerl_client's sleep state
Merge pull request #38 from grammarly/master

[minor] use tuples instead of lists in custom encoders test