Allowing ConnectionDetails#max_message_size#342
Conversation
owenpearson
left a comment
There was a problem hiding this comment.
LGTM, thanks, although I would prefer to have a spec which mocks the server to respond with a different maxMessageSize and assert that the library sets its own max_message_size accordingly. Do you reckon this would be easy enough to do @lukaszsliwa ?
… and no maxMessageSize is provided.
Thanks @owenpearson . I have prepared two more tests. Both for a case, when the server sends Here is the example snippet, if the client wants (because of some reason) overwrite the server parameters: client.connection.once(:connected) do
connection_details = Ably::Models::ConnectionDetails.new(
'maxMessageSize' => 1048576 # 1MB
#...
)
client.connection.set_connection_details(connection_details)
channel.publish('event', 'x' * 1048575)
end |
…est::Client (TO3l8)

Allowing
max_message_sizefor Realtime client. Client getsmax_message_sizefrom currentconnection.details.ConnectionDetailsattributes are populated when connection is inCONNECTEDstate.Added
max_message_sizetoAbly::Rest::Client.