saving a record is so slow why?
There's some hidden processing for saving operation
-
First, if you create a record, we need to generate unique ID (5 digits) that doesn't exist so we have to make extra query(ies) on that model to pick up an ID that doesn't exist
-
We have to detect and cache all changes that is a result of your action, for example if you updated a task related to contact , this means, contact info will change, and assignee data will change, ... so we have to detect these changes in order to commit them directly to data git repo and push them the commit and push is async process, but detecting and caching changes is a bit heavy.remember we are using flask admin and we don't control the (save) operation directly so we need to use somw ORM magic to detect changes and process them before saving then later on cache them after saving so we intercept the saving process.