Package javax.servlet.http

Examples of javax.servlet.http.HttpServlet.service()


        _response = new MockResponse(_request);

        try
        {
            s.service(_request, _response);
        }
        catch (Exception ex)
        {
            throw new ApplicationRuntimeException(
                "Error executing request: " + ex.getMessage(),
View Full Code Here


        if (target instanceof HttpServiceInvoker) {
            HttpServiceInvoker invoker = (HttpServiceInvoker) target;
            invoker.invoke(request, response, null);
        } else if (target instanceof HttpServlet) {
            HttpServlet servlet = (HttpServlet) target;
            servlet.service(request, response);
        } else if (target instanceof Filter) {
            Filter filter = (Filter) target;
            filter.doFilter(request, response, filterChain);
        } else {
            logger.warn("invoke called with target " + (target != null ) + " which is not an instance of " + HttpServiceInvoker.class.getSimpleName() + ", " +
View Full Code Here

            moduleServlet = WebServletUtils.getModuleServlet(context, moduleName);
            if (moduleServlet != null) {
               
                //explicitly go through service method
                HttpServletRequest wrappedRequest = wrappedRequest(request, context, moduleName);
                moduleServlet.service(wrappedRequest, response);
            } else {
                logger.warn("No redirection possible for servlet path " + request.getServletPath() + ", module name " + moduleName);
            }
        } else {
            logger.warn("Not possible to figure out module name from servlet path " + request.getServletPath());
View Full Code Here

    if (target instanceof HttpServiceInvoker) {
      HttpServiceInvoker invoker = (HttpServiceInvoker) target;
      invoker.invoke(request, response, null);
    } else if (target instanceof HttpServlet) {
      HttpServlet servlet = (HttpServlet) target;
      servlet.service(request, response);
    } else if (target instanceof Filter) {
      Filter filter = (Filter) target;
      filter.doFilter(request, response, filterChain);
    } else {
      //FIXME add logging
View Full Code Here

        if (jspServlet == null) {
            throw new IllegalStateException("No JSP servlet registered in the module to which the request was directed." +
                    " Your module configuration requires a " + JspServletFactoryBean.class + " configuration entry, or equivalent.");
        }
       
        jspServlet.service(req, resp);
    }
   
    @Override
    protected void doGet(HttpServletRequest req, HttpServletResponse resp)
            throws ServletException, IOException {
View Full Code Here

      moduleServlet = ImpalaServletUtils.getModuleServlet(context, moduleName);
      if (moduleServlet != null) {
       
        //explicitly go through service method
        HttpServletRequest wrappedRequest = wrappedRequest(request, context, moduleName);
        moduleServlet.service(wrappedRequest, response);
      } else {
        logger.warn("No redirection possible for servlet path " + servletPath + ", module name " + moduleName);
      }
    } else {
      logger.warn("Not possible to figure out module name from servlet path " + servletPath);
View Full Code Here

    if (target instanceof HttpServiceInvoker) {
      HttpServiceInvoker invoker = (HttpServiceInvoker) target;
      invoker.invoke(request, response, null);
    } else if (target instanceof HttpServlet) {
      HttpServlet servlet = (HttpServlet) target;
      servlet.service(request, response);
    } else if (target instanceof Filter) {
      Filter filter = (Filter) target;
      filter.doFilter(request, response, filterChain);
    } else {
      logger.warn("invoke called with target " + (target != null ) + " which is not an instance of " + HttpServiceInvoker.class.getSimpleName() + ", " +
View Full Code Here

      moduleServlet = WebServletUtils.getModuleServlet(context, moduleName);
      if (moduleServlet != null) {
       
        //explicitly go through service method
        HttpServletRequest wrappedRequest = wrappedRequest(request, context, moduleName);
        moduleServlet.service(wrappedRequest, response);
      } else {
        logger.warn("No redirection possible for servlet path " + request.getServletPath() + ", module name " + moduleName);
      }
    } else {
      logger.warn("Not possible to figure out module name from servlet path " + request.getServletPath());
View Full Code Here

      moduleServlet = ImpalaServletUtils.getModuleServlet(context, moduleName);
      if (moduleServlet != null) {
       
        //explicitly go through service method
        HttpServletRequest wrappedRequest = wrappedRequest(request, context, moduleName);
        moduleServlet.service(wrappedRequest, response);
      } else {
        logger.warn("No redirection possible for servlet path " + request.getServletPath() + ", module name " + moduleName);
      }
    } else {
      logger.warn("Not possible to figure out module name from servlet path " + request.getServletPath());
View Full Code Here

      log.debug("Instantiating Servlet: " + jspClass.getName());
      HttpServlet servlet = (HttpServlet) jspClass.newInstance();
      log.debug("Initializing Servlet: " + jspClass.getName());
      servlet.init(servletConfig);
      log.debug("Invoking Servlet: " + jspClass.getName());
      servlet.service(request, response);
      if (pageContext.getException() != null) {
        log.debug("An exception was stored into PageContext. Rethrowing it...");
        throw new RuntimeException(pageContext.getException());
      }
    } catch (Exception e) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.