Closed tahini closed 1 month ago
@kaligrafy, did you really review this ? Seem quick to take 4 minutes to review 24 files that affect how we interract with the database...
Tested with sequential tests and transition (gtfs import and calculations)
I did review, but i did not test
@greenscientist I added tons of comments and used nested function whenever it made more sense scope-wise than private functions.
Nested functions, when used judiciously, is a quite powerful feature of javascript! But apparently people coming from C/C++ don't like them... :p
All this and I'm not even closing an issue!
Also make sure individual operations that span many tables (like scenarios and schedules) are all inside transactions to avoid errors while saving those object to leave the object is an intermediate, unknown, state.
While doing so, to make transactions as fast and short as possible, the queries that involved reading/processing/writing now try to do it in a single database query, or favor batch inserts/updates/deletes.