IMPORTANT CREATE/SAVE API REFACTOR (changes API a bit) to stick more closely to ActiveRecord. You may be impacted in your code when you where explicitely passing a context or if you were using the 'reload=false' flag in create or save methods (there is one argument less now). This also drops passing context in calls or context attached to instanciated objects. It's now preferred you use the context from the session. Eventually a session.with_context block API will allow refining the context locally. But propagating context on objects was cluttering the API, it was brittle and since Ooor 2.x and the multi-sessions system, it was not required anymore.
some code documentation love
added some more method from ActiveRecord public persistence API; not deeply tested yet though
implemented session#with_context(context) {} to force some local context
superficial adaptation of the context tests to comply with with_context API change (yes more testing is needed)
better API: connection propertie s actually a session; better ActiveModel::Naming support; don't delegate class name to template
connection -> session; more robust
changed ModelTemplate to ModelSchema and moved to separate file to be closer to the ActiveRecord pattern