/** * Create a new Grizzly HTTP container. * * @param application JAX-RS / Jersey application to be deployed on Grizzly HTTP container. * @param parentContext DI provider specific context with application's registered bindings. */ /* package */ GrizzlyHttpContainer(final Application application, final Object parentContext) { this.appHandler = new ApplicationHandler(application, new GrizzlyBinder(), parentContext); cacheConfigSetStatusOverSendError(); cacheConfigEnableLeadingContextPathSlashes(); }
@Override protected void configure() { bindFactory(GrizzlyRequestReferencingFactory.class).to(Request.class) .proxy(false).in(RequestScoped.class); bindFactory(ReferencingFactory.<Request>referenceFactory()).to(new GenericType<Ref<Request>>() {}) .in(RequestScoped.class); bindFactory(GrizzlyResponseReferencingFactory.class).to(Response.class) .proxy(true).proxyForSameScope(false).in(RequestScoped.class); bindFactory(ReferencingFactory.<Response>referenceFactory()).to(new GenericType<Ref<Response>>() {}) .in(RequestScoped.class); } }
@Override public void reload(final ResourceConfig configuration) { appHandler.onShutdown(this); appHandler = new ApplicationHandler(configuration, new GrizzlyBinder()); appHandler.onReload(this); appHandler.onStartup(this); cacheConfigSetStatusOverSendError(); cacheConfigEnableLeadingContextPathSlashes(); }
/** * Create a new Grizzly HTTP container. * * @param application JAX-RS / Jersey application to be deployed on Grizzly HTTP container. */ /* package */ GrizzlyHttpContainer(final Application application) { this.appHandler = new ApplicationHandler(application, new GrizzlyBinder()); cacheConfigSetStatusOverSendError(); cacheConfigEnableLeadingContextPathSlashes(); }
@Override public void reload(final ResourceConfig configuration) { appHandler.onShutdown(this); appHandler = new ApplicationHandler(configuration, new GrizzlyBinder()); appHandler.onReload(this); appHandler.onStartup(this); cacheConfigSetStatusOverSendError(); cacheConfigEnableLeadingContextPathSlashes(); }
/** * Create a new Grizzly HTTP container. * * @param application JAX-RS / Jersey application to be deployed on Grizzly HTTP container. */ /* package */ GrizzlyHttpContainer(final Application application) { this.appHandler = new ApplicationHandler(application, new GrizzlyBinder()); cacheConfigSetStatusOverSendError(); cacheConfigEnableLeadingContextPathSlashes(); }
@Override protected void configure() { bindFactory(GrizzlyRequestReferencingFactory.class).to(Request.class) .proxy(false).in(RequestScoped.class); bindFactory(ReferencingFactory.<Request>referenceFactory()).to(new GenericType<Ref<Request>>() {}) .in(RequestScoped.class); bindFactory(GrizzlyResponseReferencingFactory.class).to(Response.class) .proxy(true).proxyForSameScope(false).in(RequestScoped.class); bindFactory(ReferencingFactory.<Response>referenceFactory()).to(new GenericType<Ref<Response>>() {}) .in(RequestScoped.class); } }
/** * Create a new Grizzly HTTP container. * * @param application JAX-RS / Jersey application to be deployed on Grizzly HTTP container. * @param parentContext DI provider specific context with application's registered bindings. */ /* package */ GrizzlyHttpContainer(final Application application, final Object parentContext) { this.appHandler = new ApplicationHandler(application, new GrizzlyBinder(), parentContext); cacheConfigSetStatusOverSendError(); cacheConfigEnableLeadingContextPathSlashes(); }