How you access various app services depends on your app. If you are using 
injection, it is declarative and fairly trivial. If not, you can either use a 
static singleton, or look things up in ServletContext. E.g. if you are using 
CayenneFilter to bootstrap Cayenne, you’d do this:

ServletContext servletContext = .. 
CayenneRuntime r = WebUtil.getCayenneRuntime(servletContext);

Andrus


On Jan 14, 2014, at 12:43 PM, jotpe <[email protected]> wrote:
> Hello,
> 
> how can I create a child context in 3.2?
> 
> class ObjectContext in 3.0 the method createChildContext is deprecated and
> CayenneRuntime.getContext(DataChannel) should be used.
> 
> How can I receive the CayenneRuntime object in my webapplication, where no
> ServerRuntime instance is available directly?
> 
> Regards Johannes

Reply via email to