airavata-courses / scapsulators

Looking to understand how weather phenomena in a region, affect your research? Well look no further!
https://github.com/airavata-courses/scapsulators/wiki/Weather-enthusiasts-assemble
Apache License 2.0
1 stars 2 forks source link

Project 1 Feedback #68

Open sumedhsalvi opened 2 years ago

sumedhsalvi commented 2 years ago

Very well organized project with clear instructions on project setup. Great UI and all the microservices are working fine. Documentation is easy to understand. I was just curious about your gateway implementation. I am unable to understand the division of gateway into three services. I have referred to the code in the below link. As per my understanding, the gateway services should be generic and route to the appropriate backend microservice irrespective of payload and number of microservices attached. Let me know if I am missing something. https://github.com/airavata-courses/scapsulators/blob/edc103afcd01e6823a82b8dfdc5eef375328c31b/gateway/gateway/routes/allRoute.js I appreciate your views on this.

Otherwise Great Work by the Team. Kudos!

shubhpatr commented 2 years ago

Hey @sumedhsalvi,

Thanks for your feedback.

I did not understand your comment on gateway. The file you are referring to is the router files, in which the routes of the gateway api's are defined.

This does not mean that the gateway will not function if one of the micro-services is down or it depends on payload. The gateway will simply respond with error status and log if one of the micro-services is down and continue to serve other micro-services.

Let me know if I was able to clarify your doubt. Let me know if you meant something else.

sumedhsalvi commented 2 years ago

Hey @shubhpatr

Thank you for your reply.

I mean to say If you add a new microservice then you need to manually modify the routing file and gateway API. The routing should be dynamics irrespective of the number of backend microservices. Let me know whether my understanding is correct or not.

Thanks!

shubhpatr commented 2 years ago

Hey @sumedhsalvi ,

Not sure I follow you clearly. Can you exactly give an example or possible alternative method?