Skip to content
This repository has been archived by the owner on Sep 9, 2022. It is now read-only.

Long messages are arbitrarily cut #14

Open
stefanhuber opened this issue Mar 25, 2016 · 1 comment
Open

Long messages are arbitrarily cut #14

stefanhuber opened this issue Mar 25, 2016 · 1 comment

Comments

@stefanhuber
Copy link

Dear all,
This is a great cordova plugin. It has reliably worked for me in most situations.

However, if I have a long response message the response is cut arbitrarily and another onReceive Event is triggered with the rest of the message... (very long messages are even cut into multiple pieces). This wouldn't be a problem if there would be some kind of mechanism to check what should get together.

If it is unclear what I mean, I can provide an example where a IRC server is called and the users of a channel are queried. Effectively this is a long string. The response (depending on the size) is cut into various pieces. There is however no indication on how to glue these together other than information inside the message itself, which is very error prone...

@mcelrath
Copy link

mcelrath commented Mar 1, 2017

I'm seeing this problem too, did you find any solution?

This seems to happen whenever the receive buffer gets full. You can make it trigger more easily by decreasing the bufferSize parameter in src/android/ChromeSocketsTcp.java.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants