title: Android how to transfer real-time stream videos to a node js server
body: <p>I'm an android developer but a noob in nodejs.I want to create a live radio appliction so I use android to create the client app and nodejs to create the server.</p>
  
  <p>Step:</p>
  
  <ul>
  <li>Android : MediaRecord to record video and transfer to nodejs server.</li>
  <li>Nodejs server : Receive the stream and transfer it to another clients or save it in the database.</li>
  </ul>
  
  <p>I read the MediaRecord apis and found the native way to send stream videos to server. </p>
  
  <pre><code>Socket socket = new Socket(“xxx.xxx.x.xxx”, 8890);
  ParcelFileDescriptor pfd = ParcelFileDescriptor.fromSocket(socket);
  MediaRecorder.setOutputFile(pfd.getFileDescriptor()); 
  </code></pre>
  
  <p>But it the NATIVE socket. NOT suit for nodejs server.</p>
  
  <p>I use the Socket.io to establish the socket server and the socket.io-client in android client to connect to the socket server. But it doesn't support to transfer the stream video info from android to server. Then I found socket.io-stream. It supports to transfer the stream info but no any android api. So I want to know what should I do or what should I use to transfer stream videos from Android to a nodejs server? Do I need to estabilsh my own nodejs socket libs to finish this work?<br>
  Any help will be appreciated. Thanks anyway.</p>