Back to all updates

almost 14 years ago

Efficient big data transfers

We're past the halfway mark in the AllJoyn Peer-2-Peer App Challenge. The submission deadline is December 27.

Here's another tip to help you develop an Android-based game, social app, or educational app using the AllJoyn SDK. Great exposure, recognition, plus over $170,000 in cash & prizes await!

How to transfer large amounts of data using AllJoyn

To determine the best action, consider your use case:

  1. If transferring to more than one application, a BusSignal should be used and the data should be chunked into 10k-100k byte blocks. Signals are guaranteed to arrive in the order they are sent, so there's no need to worry about the order of arrival. However, consider the case where a user of your application leaves the session and then comes back.
  2. If sending to one application, a BusMethod could be used. Again, data should be chunked into 10k-100k byte blocks. This will take slightly longer than BusSignals due to BusMethods being synchronous methods.
  3. Another way to send to a single application is to bind a new session for transferring data and then have the session joined by the receiving application (or the inverse, sender joins receiver) and use a BusSignals as described in #1 above.
  4. AllJoyn also provides for the ability to create a RAW_SESSION in which you would set up a new session designated as a RAW_SESSION and place a call to BusAttachment getSessionFd(). Once you have a handle to the FileDescriptor, you can write on one side and read on the other. This method is recommended for C++ users. This method is not recommended for Java users at this time due to a known limitation when using the Java binding.


Haven't started yet?

Check out the Quick-Start Guide and the How to Rock the Challenge post from earlier updates. There's still plenty of time to build an app — start coding today!


Questions

For technical problems with AllJoyn, refer to the Troubleshooting Guide, or post issues that have not been covered in the AllJoyn Developers Forum. For questions about the challenge, please email us at [email protected] and include "AllJoyn" in the subject line. We're fully dedicated to supporting your development process, and will respond as soon as we can!