[BUGFIX] Initialize resource wrapper before session
If you try to attach a resource-dependent object to a session, this
will fail, as the _wakeup() method is called before the resource
wrappers are initialized.
This patch makes sure that the resource framework is initialized
before the session framework in the standard runtime sequence of the