Large Data Chunks between Server and client

#1

Hello, my name is William and i am new to the group, i really love this frame work and the ease it provides for application development.
My question is to do with communication between android and a python web socket server both using Autobhan, it seems there is a limit to the size of the data i can push from

the python server to my android client , and anything larger than that size just fails .

I was hoping for some advice as to how i can send data in chucks from my python server to my android client to also read incoming binary payloads of approximately 5MB or larger to my Android client.

I was also wondering if any development on the C++ branch of Autobhan will be made in order to allow it to act just like the python implementation so that it also provides web socket services . I would like to use these in some of projects that i am working on especially those in BlackBerry and Sailfish that do use C++, also it would be lovely if it is a Qt Port but bare bone C++ 11 would be really wonderful :slight_smile: Thanks in advance.

0 Likes

#2

Hi William,

Hello, my name is William and i am new to the group, i really love this
frame work and the ease it provides for application development.

Great! That's nice to hear;)

My question is to do with communication between android and a python web
socket server both using Autobhan, it seems there is a limit to the size
of the data i can push from
the python server to my android client , and anything larger than that
size just fails .

The limits for AutobahnAndroid frame/message sizes can be set via options

https://github.com/tavendo/AutobahnAndroid/blob/master/Autobahn/src/de/tavendo/autobahn/WebSocketOptions.java#L44

Those are 128k by default. AutobahnAndroid allocates (fixed) buffers for sending/receiving.

I was hoping for some advice as to how i can send data in chucks from my
python server to my android client to also read incoming binary payloads
of approximately 5MB or larger to my Android client.

You can increase the buffers via above options. That will mean your app's memory consumption will increase likewise.

If you wanted to receive a 1GB file over WebSocket, you would need to do things quite differently.

Foremost, the API to app code would need to be completely different, to allow the app code handle data received on a message that is still incomplete. In other words: a streaming API for WebSocket (with flow-control right into app code).

AutobahnPython has that: a real streaming API in addition to the "normal" message based (it also has a frame-base API).

I don't know another WebSocket implementation that features this, but AutobahnAndroid definitely not.

I was also wondering if any development on the C++ branch of Autobhan
  will be made in order to allow it to act just like the python
implementation so that it also provides web socket services . I would

AutobahnCpp can already be used to implement WAMP application components. Works.

2 notes:

Currently, AutobahnCpp can only talk WAMP-over-TCP (and pipes and Unix domain sockets). It cannot talk WAMP-over-WebSocket. From WAMP point of view, this is irrelevant (completely transparent).

We can add this feature quite easily (reusing WebSocketpp C++ WS impl.).

AutobahnCpp won't act as a WAMP Router. So you will have a (generic) WAMP Router that hosts and connects your app components (like Crossbar).

like to use these in some of projects that i am working on especially
those in BlackBerry and Sailfish that do use C++, also it would be
lovely if it is a Qt Port but bare bone C++ 11 would be really wonderful

AutobahnCpp is a C++ 11 only implementation. We have no plans for a Qt specific one. But you can start one! :wink:

Cheers,
/Tobias

···

Am 30.05.2014 14:41, schrieb willia...@gmail.com:

:slight_smile: Thanks in advance.

--
You received this message because you are subscribed to the Google
Groups "Autobahn" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to autobahnws+...@googlegroups.com
<mailto:autobahnws+...@googlegroups.com>.
For more options, visit https://groups.google.com/d/optout.

0 Likes