Move *_context classes out of session::impl.