Say we have a full-text search client that periodically updates the index for every record.
If we had threaded Rails, there is the possibility for a race condition if two record updates are performed at the same time.
The name of the database table is, by convention, the pluralized (in the English language), lower-case form of the model's class name.
In the case of our Intranet application, the models are organized as follows: We haven't built any of these yet, but we will shortly.
This is true even if it’s in another class, since the , and use to temporarily reparent the instance for the duration of the save (I hope that last suggestion made you gag). If we set up our callbacks properly, we can let anyone update is changed (because otherwise timestamps really do need to happen).
A lot of relational tables need created and update timestamps columns.
I prefer having them for all tables with no exception.
We could even move it into Active Record:: Base if we wanted to, and support per-class configuration with subclass (or instance) constants.
What if we want any arbitrary action to be performed without timestamp updating?