Why are auto-committed objects retrieved from DB?

Imagine the following code, where Car is owner of a many-to-many association with Tire. (Forget about the modelling errors, I didn't make them :) )  The first time the microflow is being called, no Tire is associated with the Car. So a new Tire is created, however not committed.  By changing the association between Car and Tire and committing the Car object, the Tire gets auto-committed.  On the next retrieve from database the auto-committed Tire is returned. But I wonder why? Yes it is in the database, but it has the status auto-committed. Which means that when a rollback is performed (for instance the session is killed) the auto-committed Tire will be deleted (as of Mendix7) to maintain database integrity. In other words it hasn't been explicitly committed and thus is some kind of temporary object. If retrieve from DB would only return explicit committed objects, this kind of modelling errors would be easier to spot (as it would result in an infinite loop) however now all seems to be working, until the session is removed and database is corrupted.     
2 answers

Aaah yes, these autocommits :)

The Planned idea ‘Remove the autocommit feature’ is a nice plug here: https://forum.mendix.com/link/ideas/650


If you have objects which were autocommitted, in my experience, they exist until the user who created these objects sign out and then the automcommitted objects will be deleted. You can see in the logs what kind of objects were widthdrawn.