I want to implement "hot reload" of the tables and columns meta-data in the following project:
qto - github
https://qto.fi - click just login to get to the ui ...
The page life cycle / control flow goes as follows:
- user requests a page - the Mojoicious framework builds the "empty templates" and servers t +hem to the browser - once loaded to the browser, client side axios http requests fetch t +he data from the back-end - vue does the data-binding on the client side by using BOTH the data + for the page and the global tables and columns meta-data
by not-breaking however the horizontal scalability provided the world's best framework Mojolicious
the variant would be to have the following flow of events:
- 1) alter table in postgres - 2) reload a metatable from UI ( to tell to the Application Layer to + reload the meta-data) - 3) the meta data hash ref of hash refs is accessible to all the per +l processes
The current implementation does not implement this "hot reload" to all the hypnotoad processes ... which breaks the listings in the UI, because they are meta-data "aware" ...
Could it be wise to complicate the current setup by adding Redis with publish subscribe mechanism for the meta-data only ?
Could it be implemented by some kind of interprocess signalling / communication - one proc reloads the meta-data and somehow signlas to the others ... as at the end those DDL changes on the db site will probably not occur so often ...
Could some kind of quick hack not requiring a lot of work be implemented ?
In reply to multiprocess run-time data structure sharing in Mojolicious web app ... by YordanGeorgiev
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |