TransientModel is a model super-class that stores data in the database temporarily and it is automatically cleaned up on a defined period of time.
The scheduled action to clean up the database, including the
TransientModel’s data is named "Base: Auto-vacuum internal data" and it can be found at
Settings > Technical > Automation > Scheduled Actions. The default interval for running is once per day.
From a security perspective, all users can create new records of a
TransientModel, however, they can access only the records that they have created, except for the superuser, which can access all records.
Also, when using this class should be taken into consideration that Many2one relations are not allowed with a non-transient model.
TransientModel class is mainly used when working with wizards and configuration settings, although it can be useful in a few other cases. In general, the model can be taken into consideration when there is a need to temporarily store data in the database which is essential only for the duration of a user's interaction with the system and can be removed after the interaction is finished.