Showing posts with label relay. Show all posts
Showing posts with label relay. Show all posts

Sunday, November 14, 2010

Jingle Nodes Updates

Jingle Nodes will complete 9 months of official Specification published. As suggested by @luissoeiro, I will summit what happened so far.
How to contribute to Jingle Nodes:
  • Writing Code and Discuss the Specification - All fixes, patches and suggestions are always welcome (Jingle Nodes Group)
  • Talk about the project - Talk about Jingle Nodes simplicity and how it's easier than other alternatives
  • Propaganda - Add a Jingle Nodes Image to your Blog or Website (Jingle Nodes Selo.png)
  • Write a Tutorial - Describe how you are making use of Jingle Nodes
  • Testing and giving feedback - Your opinion matters!

Monday, October 19, 2009

Java and Jingle Nodes


For a couple of months, I was wondering if Java would be suitable to provide relay services, in case of a Java Jingle Client wanted to enable it.
Of course Java is perfectly suitable for using a Relay Service, no doubt about the trivial statement. But is Java suitable to be used on providing it?
Researching on Internet I found nothing but rumors and assumptions. So I decided to try it myself. I agreed with a Jingle Node Project Contributor to provide a Java Relay Channel Class just like we have the C++ version using Boost. And I would provide the UnitTest Cases in order to measure added latency. This weekend with the code in our hands we ran the tests.

All the tests were conducted using loopback interface in order to prevent real network to influence in the results.
You can find the Test Case in Jingle Nodes Repository:

Results running 10 simultaneous channels processing and relaying 30 packets, the overall average values after 100 tests, for Latency was:
  • Max: 52ms
  • Min: 7ms
  • Avg: 10.0ms
Surprisingly the results are very satisfactory for Client Side Relaying. And I have to admit that the Java Code is by far more elegant and simple.

This means that SIP Communicator is not only a good candidate for Jingle Nodes usage, but also a great candidate to also provide Jingle Nodes relaying features.
For comparison criteria I created an extra test case based on a single Relay Channel using a C++ and a Java Channel measuring the added latency by using a Relay, instead of direct traffic. The results were the following:

C++/Boost-ASIO Latency:
Max: 16ms, Min: 2ms, Avg: 3.0ms

Java NIO Latency:
Max: 90ms, Min: 2ms, Avg: 5.0ms

I strongly encourage Java and C++ Developers to do a try out and spicy the discussion.