-1

I went through several topics on SO but I am not sure what fits my needs as I am newbie.

I am creating an Android application for my website.

I reckon that the users can be over 800000 online at the same time.

Users will be able to: - Submit data through the application - Read news and updates I want the updates to happen in real time..

The question is what approach or technique should I use?

In some SO topics is mentioned that there should be on the server side some php files that will accept http/post/get requests and they will return JSON data as feedback.

Is the above-mentioned a proper technique to serve a huge amount of users at the same time(for my standards "huge" means around 800000 users at the same time)?

I recently came across node.js. From what I read it seems like it can act as service where a user/ app can request or post data.

Can anyone give me a suggestion or links where the things are clear? How can I make sure what approach is the right one for my application?

Whatever the case is can anyone describe the right way of doing this thing?

For example: How Android chat aplications suchs as whatsapp, facebook etc work? How they do it?

I do NOT want you to post any code.. just ideas!

Thanks in advance!

user2399432
  • 738
  • 1
  • 9
  • 17
  • Many good questions generate some degree of opinion based on expert experience, but answers to this question will tend to be almost entirely based on opinions, rather than facts, references, or specific expertise. I would suggest that you find a development forum (perhaps [quora](http://www.quora.com/Computer-Programming)?) to work out generalities. Then, when/if you have specific coding issues, come back to StackOverflow and we'll be glad to help. – Jay Blanchard Jul 14 '15 at 16:46
  • Here's a beautiful comparison between NodeJS and PHP: https://philsturgeon.uk/blog/2013/11/benchmarking-codswallop-nodejs-v-php/ Hope it helps to choose! :) – ital0 Jul 14 '15 at 17:00

3 Answers3

2

If you want create an app like Facebook, Snapchat ... YES you must have a WebService, an API.

The API is linked with your database like your website and return to the app JSON, with the content of your app. Your API (web service) can be programmed in various language as PHP, Node.JS ... If you want to know Facebook had their API in PHP before that they created their own language. Some other app have their API in other language. I don't really know what is THE BEST language, the BEST language is the language which you are good with, and know it.

nekflamm
  • 131
  • 12
1

I think think nodejs will be best option.
NodeJs is helpfull when there are large number of clients.
Nodejs works best when building chat and gaming applications.
I think this link will help you a lot to learn nodejs.
If you are asking how facebook and whatsapp works they are implementing websockets which provides bidirectional flow of data helps in real-time communications between clients.

Community
  • 1
  • 1
KlwntSingh
  • 1,084
  • 8
  • 26
1

If your scenario is sending chats back and forth nodejs is a really good option, Most of the online tutorials you will find about nodejs develop a chat application and its super easy to do so with nodejs. Infact the biggest catch with nodejs is its easy configurations and deployment plus its lightweight. However it might be a good idea to have a look at XMPP as tech giants such as whatsapp use it to send messages and maintain presence. This link can be a good head start for nodejs learning http://code.tutsplus.com/tutorials/nodejs-for-beginners--net-26314

Kayani
  • 942
  • 7
  • 23