Hi, I hope that you're all doing great!
This week I've been working on adding the searching layer configurations, as I've mentioned before we decided to go with Algolia services, they have a great plans, super easy and efficient control panel to configure everything related to your index, using algolia necessitates adding some sort of synchronization to always keep our Algolia index updated, therefore I've created a method that will always be triggered when ever the main database got updated, to update the Algolia's index.
2- We've also noticed the importance of adding a validation layer in front of our APIs to ensure that they are going to be used as expected, and to respond with errors as soon as possible, we've used JOI to achieve this and it worked like a charm, Anyway, it's only added to V2 APIs. We've also added an isAdmin middleware to check whether the request is authenticated or not, this will only be used in the suggestions management APIs.
Thank you for reading!
This week I've been working on adding the searching layer configurations, as I've mentioned before we decided to go with Algolia services, they have a great plans, super easy and efficient control panel to configure everything related to your index, using algolia necessitates adding some sort of synchronization to always keep our Algolia index updated, therefore I've created a method that will always be triggered when ever the main database got updated, to update the Algolia's index.
2- We've also noticed the importance of adding a validation layer in front of our APIs to ensure that they are going to be used as expected, and to respond with errors as soon as possible, we've used JOI to achieve this and it worked like a charm, Anyway, it's only added to V2 APIs. We've also added an isAdmin middleware to check whether the request is authenticated or not, this will only be used in the suggestions management APIs.
What's next?
Days fly! the next week is the last week, I will work on adding the unit tests to ensure that everything is working as expected, and I will also work on configuring the docker image for easier deployment process. That's it :')Thank you for reading!