SIP and WebRTC

We will be using Kurento or some kind of media server/mixer in out setup because of the following reasons:

  1. Imagine a call between user A, B, C and D. When you don’t use any media server/mixer. User A will do an upload to user B, C and D, also user A receives streams from B, C and D. Same applies to other users. Meaning every user opens a specific stream to the other users. On a desktop / laptop maybe it won’t give you any problems (maybe with 16 users it will). But on a mobile device this isn’t a good practice, for the data usage and processor power to our experience.
  2. If you will be using SIP hardphones with video to your Asterisk server. These phones will most likely use H.264 video codec. So if you want to be able to have a video call between WebRTC client and a SIP hardphone client someone needs to do some video transcoding.
  3. If all media went peer-to-peer then you wouldn’t be able to record any video session, would you?

We are looking into JSSIP + Asterisk + Kurento because of the following reasons:

  1. Our users want the ability to always call a ‘traditional telephone line’.
  2. Kurento is needed for above reasons (or some other media server if that seems to do a better job)
  3. Connect through browser, android and ios (ios is still an issue)
  4. Ability to add other SIP services to the platform

Hi Mark, thanks for your in-depth comment. It makes a lot of sense.

We will be trying something quite similar… I have been looking at Janus in some detail and it seems to offer some interesting functionality/possibilities, although it can be looked at as more of a framework than a server in itself. I’ll need to get a Kurento instance up to really evaluate.

Thanks!

To all following an reading this thread. Some people finally added a WebRTC plugin to Cordova that exposes WebRTC on IOS, check this GitHub: https://github.com/eface2face/cordova-plugin-iosrtc

1 Like

At this moment TokBox is creating a new community-based Cordova plugin for WebRTC support. The plugin can be found on the cordova-plugin-opentokjs GitHub page. Please note that it is still in development at this moment. But everyone is working towards a 1.0.0 release.

We have added also an Ionic example based on the Ionic tabs starter project. The example can be found on our cordova-plugin-opentokjs-example GitHub page.

Noticed this yesterday https://www.sinch.com/products/voice-api/sip-integration/

1 Like

Integrating Bowser will save all the VOIPers! it will become rediciusly easy to manage voice and video calls with its full webRTC support.
as I said here im wiling to volenteer for this integration project. any one who see the benefits it might bring welcome to help me and announce it on the topic.

Hi all,

It is good to see I am not alone ‘fighting the crime’. I need to start a complex media project based on mobiles (Android and iOS) and I do not have clear path to follow. Reading this thread I added a couple of things to look (Crosswalk or some cordova plugins), but after considering the rest of libraries/media servers/framewroks as you did, I am still lost (well, it is important to mention that I do not have time for doing proof of concepts because I need to have something to show in two months time :frowning: ).

In short: I am in the same position as @markdark @rvn were some months ago: “choosing/investigating technologies”, so, let me ask some questions and have a chance to finish something (please):

@rvn, @markdark if today you had to start a media project for phones, which technology you would use (SIP is not needed) for the client side (remember: iOS and Android devices)?

At the beginning I thought to use phoneRTC because it includes the Google’s WebRTC implementation and instead of using its built-in backend modify the js files for using the JS wrapper which Kurento offers (or Licode), but I am terrible dissapointed when @markdark mentioned the performance was not good as it should be. I considered as well OpenTok but I “can not” use any commercial solution, so would you give Crosswalk a chance? It looks like it included WebRTC for iOS and Android, doesn’t it?

Do you know if CrossWalk when it is used inside ionic does it include everything related with WebRTC? If Crosswalk does not work which cordova/ionic plugins would you use? Maybe [this one][1] for both ios and Android 4.4+?

In the backend I am going to use Kurento as well (need to record conversations, control users, moving, extending, joining automatically chat rooms…, so a Media Server is needed and it looks they have a constant development. I will give them a chance)

Something that I am missing? Of course if you have any question, feel free to ask me whatever needed.

I really appreciate your help. Thanks in advance,

Adolfo

PS. This thread brought me some hope in order to save time and start since the beginning following a valid path. Thanks.
[1]: https://github.com/eface2face/cordova-plugin-iosrtc

@apanizo If you don’t need SIP, kep it to pure WebRTC. Microsoft is also implementing WebRTC in their new browser Edge. Keep in mind untill Microsoft finishes this implementation WebRTC won’t be supported out-of-the-box and you need some plugins. Same goes for Safari, but Apple still hasn’t told the community what they will do.

That being said and you telling that a commercial solution isn’t the path to go, you probably need the next path (you found already):

  • Use CrossWalk (Android only), which allows you to support older versions for Android. I am not sure from which version, but at some point (I believe Android 4.3 or 4.2) Android included Chrome as the standard web browser. Which supports WebRTC. Before that there is another browser used which didn’t support WebRTC. Because of CrossWalk you will package a Chromium browser with it that does support WebRTC. Also you have the benefit that you are sure what you test will be the same on all other Android phones, because you deliver the same version of the Webview to all the devices.
  • For IOS CrossWalk is developed in en opensource community at this moment. Not sure how stable it is at this moment. But as I have understand it is not officially supported by CrossWalk. Like you mentioned you’ll need this plugin to get pure WebRTC support on IOS.
  • Implement Kurento

Thanks @markdark for your quick reply.

You are right. Yesterday after sending my previous post I continued looking into the exactly solution that you have mentioned. At first I was skeptical, because using that approach everything is much simpler and no third parties are involved.

But after reading that post (done by plugin’s creator): https://webrtchacks.com/webrtc-hybrid-applications/ all pieces fit together.

Also I had one requirement that if is possible native development is a plus so, doing Hybrid development I can have the best of both approaches ( I am a ninja on HTML/JS :slight_smile: ). Probably I will have a lot of problems but at least now I can follow a ‘valid’ path.

One quick thing, under your experience which DB do you like for integrating with Kurento? I would need it for storing broadcast conferences and audio from user’s conversations. NoSql? CouchDB?

Also, which Web Server do you recommend? Tomcat? Jetty9?

Really thank you because this thread “has been/is being” really helpful.

Adolfo.

@apanizo I haven’t used Kurento, so can’t comment on that. But if NoSQL can do the job for you, use NoSQL.
As a webserver I am still an Apache fan or nginx.

1 Like

Currently im wondering about this too.
Im trying to use PeerJS as client and server (separate examples are provided by peerjs.com).
For not no luck with iOS, its works with Crosswalk on android os but little luggy.

You should dive into the Google Groups of PeerJS and cordova-plugin-iortc. Looks like there are people working in both repositories:

@apanizo @rvn I am now working on a another project which also needs pure WebRTC and we are looking into Kurento. We have created a simple example to demonstrate group calling: https://github.com/Mobilea/kurento-group-call

How are others doing on this WebRTC part at the moment?

@markdark we still working on it, and it works fine. At the end I have forked the kurento-room project for build our own UI and add our own REST endpoints and puttin aside the typical problems of update libraries, there is no problems at all.

We have not done any stress test in order to know the limits of the project, but as I said, it seems to be ok.

On Android and desktop it works out of the box, and for iOS we still use the iosrtc plugin (Cordova app).

So, if you want very specific information about how it works under certain scenario like: X users, Y rooms at the same time, I can not be really helpful, but if you just want feedback for a prototype you can pick those technologies up without any problem (to be honest I think it will scale fine).

We also use for our environment: as DB CouchDb-Ektorp, Tomcat 8 (SSL), Apache 2 and everything works fine with secure connections (HTTPS, WSS) as well.

If you want any more info, just let me know.

Thanks,

Adolfo.

@apanzio/ @markdark, thank you for providing the insights to different frameworks and your updates. @apanzio, when you say kurento works out of the box on Android, is it an Android app/ browser based solution? Looking to create mobile app for app-to-app calling/ chat using webrtc on Android/ iOS/ desktop. How is the voice call/ video quality with Kurento?

Thanks in advance,
Puja

https://github.com/Mobilea/cordova-plugin-opentokjs-example
This link is 404 now, may I know is there any update link? Thanks.

We stopped using TokBox for several reasons. One is the lack of proper Cordova support. And the non-willing to get things up and running using cordova-plugin-iosrtc.
So we switched to purely WebRTC solution with the use of cordova-plugin-iosrtc which runs great!

Hi @markdark would you mind sharing a bit of the backend you are using? Are you leveraging p2p webrtc or going through a server for multiuser conference ans/or recording etc?

Thanks

Hello Mark,
We are using ionic 1 for our hybrid app. Like to use WebRTC a for video chat and exploring various options. It is essential that we have a solution with Angular wrapper and Cordova plugin. We use Angular for our WebUI piece along with bootstrap.

Can you please share current status on ionic support for WebRTC ? Any suggestions on using simpleWebRTC and signalmaster for signalling ?

Thanks a ton

1 Like

Hello guys, sorry for digging up this topic, but I just got in the same spot you were years ago.

I’m developping one app that must connect into a SIP (Asterisk) server for creating only audio calls.
I think the only difference is that I’m using Ionic 2, but by my researches about PhoneRTC it’s compatible and have all the WebRTC resources I’ll need (besides the need for “cordova-plugin-iosrtc” for iOS wich is ok).

So, I’m starting now following your paths. Thanks for all the explanations and let’s keep this topic alive!