Here's the thing: we have a website which has some i18n. Translations are maintained in DB and manually exported into JSON files which are consumed by our SPA one time on load.
Now I have the following problem to solve: I want to put those i18n JSON files to some CDN and when someone makes updates in database, I would like JSON files to be regenerated automatically and get those uploaded to CDN.
My current thinking is to make Trigger in DB (PostgreSQL) which will send NOTIFY on data change and some service which will listen for that. After this signal it will upload actual JSON to CDN,
Could anyone propose alternative approach?