* @param req the {@link AtmosphereResponse}
* @return the {@link AtmosphereHandler} mapped to the passed servlet-path.
* @throws javax.servlet.ServletException
*/
protected AtmosphereHandlerWrapper map(AtmosphereRequest req) throws ServletException {
AtmosphereHandlerWrapper atmosphereHandlerWrapper = mapper.map(req, config.handlers());
if (atmosphereHandlerWrapper == null) {
logger.debug("No AtmosphereHandler maps request for {} with mapping {}", req.getRequestURI(), config.handlers());
throw new AtmosphereMappingException("No AtmosphereHandler maps request for " + req.getRequestURI());
}
config.getBroadcasterFactory().add(atmosphereHandlerWrapper.broadcaster,