framework.externalizeDestroy(true).init(new NettyServletConfig(config.initParams(), ctx));
} catch (ServletException e) {
throw new RuntimeException(e);
}
framework.setAsyncSupport(new NettyCometSupport(framework.getAtmosphereConfig()) {
@Override
public Action suspended(AtmosphereRequest request, AtmosphereResponse response) throws IOException, ServletException {
Action a = super.suspended(request, response);
if (framework.getAtmosphereConfig().isSupportSession()) {
AtmosphereResource r = request.resource();