Openvidu android sample code not working

Openvidu android sample code which i downloded from openvidu github repo is not working at all i am only able to see the black window for the local participant and the remote participant with name of the remote participant . Your onAddtrack() method not at all working. Please help me integrate this asap

Did you followed instructions from here?: OpenVidu Docs

Clone the repo using v2.18.0 (latest current version):

git clone https://github.com/OpenVidu/openvidu-tutorials.git -b v2.18.0

Also it could be that your OpenVidu deployment is not accessible to your Android. To check if the deployment is wrong test it with our demos server:

URL: demos.openvidu.io
Secret: MY_SECRET

Still not able to receive the remote participant video stream in android. I have followed all the steps that was mentioned in the docs. Add to it cloned latest openvidu source code i.e. v2.18.0

Try with demos as said. If demos.openvidu.io works, the problem is in your OpenVidu Server deployed in your LAN network for development

Yes tried that also buddy not receiving any remote video streams in android

Can you show me at least some logs of your Android App and your OpenVidu Server?

E/CustomWebSocketListener: No params {“id”:23,“error”:{“code”:-1,“message”:“java.lang.RuntimeException:Request element ‘reconnect’ is missing in method ‘prepareReceiveVideoFrom’. CHECK THAT ‘openvidu-server’ AND ‘openvidu-browser’ SHARE THE SAME VERSION NUMBER”,“data”:“java.lang.RuntimeException: Request element ‘reconnect’ is missing in method ‘prepareReceiveVideoFrom’. CHECK THAT ‘openvidu-server’ AND ‘openvidu-browser’ SHARE THE SAME VERSION NUMBER\n\tat io.openvidu.server.rpc.RpcHandler.getBooleanParam(RpcHandler.java:812)\n\tat io.openvidu.server.rpc.RpcHandler.prepareReceiveVideoFrom(RpcHandler.java:361)\n\tat io.openvidu.server.rpc.RpcHandler.handleRequest(RpcHandler.java:131)\n\tat org.kurento.jsonrpc.internal.JsonRpcHandlerManager.handleRequest(JsonRpcHandlerManager.java:142)\n\tat org.kurento.jsonrpc.internal.server.ProtocolManager$3.run(ProtocolManager.java:218)\n\tat java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)\n\tat java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)\n\tat java.base/java.lang.Thread.run(Thread.java:829)\n”},“jsonrpc”:“2.0”}

Are you running OpenVidu Server 2.18.0 and using the tutorial of the version 2.18.0?

yes its up and running on testing server thanks. But whats the problem with my server

Hello @rohit0507 , try to replace this line of code: openvidu-tutorials/CustomWebSocket.java at v2.18.0 · OpenVidu/openvidu-tutorials · GitHub

With this:

this.mediaServer = "kurento"

Please, notify me if this works for you :slight_smile:

Regards

Thanks alot @cruizba its working absolutely fine. But can you explain me what is this kurento?

This was a bug. We are working on using different media servers in OpenVidu Enterprise. We will support mediasoup in OpenVidu Enterprise very soon. Stay tunned :slight_smile:

I will commit this line in the tutorials of version v2.18.0 as a patch.