I'm working on a VOIP startup currently and deciding which software stack will be best. I'm doing a lot of research of how other people do it, like Discord. It's really hard to make some of these initial decisions without fully knowing the requirements or what will work best for my startup. I coming here to get some advice from people with experience gained from wisdom of using doing stuff like this. Anyway,

Discord splits up their backend into several components:

  • API Server (services HTTP GET,PUSH, etc requests)
  • Gateway server (provides real-time service, handles live connections to devices so that it can tell them about new messages and receive messages and such)
  • Voice server (handles the voice connection)
  • Media proxy (resizes videos to thumbnails)

Discord uses Cassandra for their database implementation, but I think I'm going to go with Scylla for mine. I have several questions regarding what tech stack is best for a VOIP service that handles voice, messages, and other items.

First, I plan to use C++ for the Voice Server since it's fast and gives hardware level access. However, how do I separate the API server and Gateway server (should they be separate?). For example, do both the API server and Gateway server get access to the database or does the Gateway server just queue up REST commands that are sent to the API server? I imagine if you have different applications running on a database (gateway and API) things would get complicated with preventing deadlock and race conditions and such.

I guess my questions are this:

  • Should the API server and gateway server both have direct write/read access to the database? If not, how should the gateway inform the database?
  • What is a recommended programming language for the API server (that will service RESTful HTTP requests)? It seems like everyone uses NodeJS but I've been reading that NodeJS doesn't make use of the entire computer well and isn't super scalable. Would something like Django or Spring or Elixir be better for this use case? Should I use a framework?

Your Answer

 

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.