Zephyrnet Logo

WhatsApp like Chat App using GCloud ToolSet

Date:

Saurabh Rathor

During one of my interviews, I was asked to suggest a System Design of Whatsapp like Chat App in Google Cloud. I am going to discuss here the initial design which I had suggested. Points considered and issues with it. And then the optimum solution which I think is better for this platform as per my further research.

Please share your suggestions, if you feel it could be improved further.

Initially, I had suggested an architecture something as above, with only change as “Cloud Spanner” compared to “Cloud SQL”. As storage needs to be synced across multiple locations hence horizontally scaling can be easily done using Spanner. AppEngine will provide the required Autoscaling facility to handle changing traffic volume.

  1. Global Availability — Storage server needs to be close to the client and also in synch for quicker response. So, thought Cloud Spanner will be best as compared to Cloud SQL (Considering the ingested Data is structured).
  2. AutoScaling Infra — Infra should autoscale as per the traffic demand. So, App Engine is best suited.

Later on, after analysis, I felt there are some issues and can be improved further.

1. Chatbot Best Practices for designing a Conversational Experience

2. PythonBot

3. Chatbot software: Dominate the market (The Ultimate Guide)

4. How To Grow Your Business With The Help Of Artificial Intelligence

  1. Unstructured Data — Chat related Data need not be structured always, so a no-SQL DB will suit better.
  2. Write once read more — Since chats once sent is not updated. Also, the historical chat is accessed very less. So, transactional SQL databases are not required here. Also, we can move the historical data to a cheaper storage option.

The major change is to use Firebase services (for authentication, storage, and Code function). It resolves a lot of issues –

  1. Firebase Authentication Service — It helps in authenticating users via various logins like Google, Facebook, email, etc.
  2. Firestore (DB component of Firebase)— All chat related Metadata like user details, groups, online status, etc. are stored in Realtime no-SQL DB i.e. FireStore.

Note, storage is quite expensive, so chat (once delivered), can be stored either in Client or can be uploaded to Google Cloud Storage.

Various stats can be captured via Pub/Sub which is further processed by DataFlow / DataProc and then dumped in BigQuery for performing Analytics. Google Storage Bucket can be used for long term backup option.

StackDriver is always there for monitoring.

If chat service needs to be used for Customer Care Service, there are a no. of AI toolset, which can bring in AI capabilities like Vision, Speech, and Text AI to extract the context.

The above system designs are just the outcome of my research. Your suggestions are really welcome to improve this design further.

Source: https://chatbotslife.com/whatsapp-like-chat-app-using-gcloud-toolset-2cf6a36d1e5b?source=rss—-a49517e4c30b—4

  • Plato Tags:
  • AI
spot_img

Latest Intelligence

spot_img

Chat with us

Hi there! How can I help you?