atlan-collect / README.md
README.md
Raw

Atlan Collect

Here is the link to the Problem Statement!

System Design Doc

The design choices made for the code base and what could be improved more is explained here:

https://ranjanmangla.notion.site/Atlan-Backend-Assignment-5fe0e37cbb2a4d7abb5690f33bfd4a25?pvs=74

System Setup (Assuming a Linux based System)

Make sure that minikube, kubectl, docker & k9s are already installed on your device

Change Bind Address of the MongoDB to 0.0.0.0:

  1. Open /etc/mongod.conf
  2. change bindIp value to 0.0.0.0
  3. save & exit
  4. Restart mongodb by: sudo systemctl restart mongod

Make sure you change the port number of redis to 7779 from 6379 ( you can change in the redis.conf file) & it’s bind address. Here is how to do it:

  1. Open /etc/redis/redis.conf
  2. Look for the bind directive in the configuration file.
  3. Change it from 127.0.0.1 to 0.0.0.0
  4. Look for port 6379 and change 6379 to 7779

Append these to your /etc/hosts file:

192.168.49.2 kubernetes.docker.internal
192.168.49.2 rabbitmq-manager.com
192.168.49.2 datacollector.com

And enable ingress in minikube by doing:

minikube addons enable ingress

minikube addons enable ingress-dns

How to Run?

  1. Run minikube start on your terminal to start a Minikube Kubernetes cluster.

  2. In a separate terminal window, run minikube tunnel to establish a network tunnel to expose services running inside the Minikube cluster to your local machine.

  3. Follow the below instructions to run each use case:

    • Run the below commands to deploy use cases on your local kubernetes cluster (minikube):
    kubectl apply -f ./gateway/manifests
    kubectl apply -f ./notifications/manifests
    kubectl apply -f ./submit/manifests
    kubectl apply -f ./rabbit/manifests
    kubectl apply -f ./spreadsheet/manifests
    kubectl apply -f ./translator/manifests
    
  4. Use k9s to verify, if all pods are running successfully

Use the postman collection to test api routes: https://api.postman.com/collections/27939350-a45314db-8cde-4e60-81a9-04a24fb7b872?access_key=PMAT-01HQ974AFAJWFQ90K75SV4W6DY