Skip to content

Large messages issue #47

@darkl

Description

@darkl

Hi,

I've been told that WampSharp has issues with the vtrotola WebSocketListener transport and large messages.

After investigating this, this seems to be an issue that looks like a race condition in WebSocketListener. I'm attaching some code that reproduces this. Note that not every run results with an exception, so it seems this is really some kind of race condition.

See the code here. You need to install vtortola.WebSocketListener, WebSocket4Net and Newtonsoft.Json. The application should crash at some point with this exception:

An unhandled exception of type 'Newtonsoft.Json.JsonReaderException' occurred in Newtonsoft.Json.dll

Additional information: Unterminated string. Expected delimiter: ". Path '[31].tags[0]', line 1, position 32776.

Investigating the received message, we see a substring of the sent JSON ending with this suffix "i��y2���".

You might suspect that this may be a problem related to WebSocket4Net, but it works fine with other WebSocket libraries such as Fleck.

Any help is appreciated,
Thanks!

Elad

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions