-
Notifications
You must be signed in to change notification settings - Fork 17
Description
A customer has reported that the library emits Channel message limit exceeded xxx bytes errors when the number of bytes in the message is less than the MAX_MESSAGE_SIZE on the account. It appears that the library is using the default MAX_MESSAGE_SIZE in favour of the maxMessageSize received from ConnectionDetails.
Update 2022-09-13
ProtocolMessage.connection_details object returns incorrect connection details object. https://github.com/ably/ably-ruby/blob/7cd9226bfe43532a44614fe6b8fc063400e372c1/lib/ably/models/protocol_message.rb#L257
It should delegate/reference to the connection_details sent on CONNECTED state.
attributes[:connection_details] is nil when sending new messages (after CONNECTED) and it overwrites the connection details object.
Update 2022-09-21
Connection details are missed between messages in websocket transport: https://github.com/ably/ably-ruby/blob/main/lib/ably/realtime/connection/websocket_transport.rb#L209,L227. When event_data contains connection_details it should be saved/updated and filled to the protocol message and shared between requests.
ProtocolMessage#connection_details should be replaced with attr_reader :connection_details and assigned in initializer.