IntegrationManagerEngineFilter.java

  1. /*
  2.  * GovWay - A customizable API Gateway
  3.  * https://govway.org
  4.  *
  5.  * Copyright (c) 2005-2025 Link.it srl (https://link.it).
  6.  *
  7.  * This program is free software: you can redistribute it and/or modify
  8.  * it under the terms of the GNU General Public License version 3, as published by
  9.  * the Free Software Foundation.
  10.  *
  11.  * This program is distributed in the hope that it will be useful,
  12.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14.  * GNU General Public License for more details.
  15.  *
  16.  * You should have received a copy of the GNU General Public License
  17.  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  18.  *
  19.  */

  20. package org.openspcoop2.pdd.services.skeleton;

  21. import java.io.IOException;

  22. import javax.servlet.Filter;
  23. import javax.servlet.FilterChain;
  24. import javax.servlet.FilterConfig;
  25. import javax.servlet.ServletException;
  26. import javax.servlet.ServletRequest;
  27. import javax.servlet.ServletResponse;
  28. import javax.servlet.http.HttpServletResponse;

  29. import org.openspcoop2.pdd.services.connector.ConnectorUtils;
  30. import org.openspcoop2.protocol.sdk.constants.IDService;

  31. /**
  32.  * IntegrationManagerEngineFilter
  33.  *
  34.  * @author Poli Andrea (apoli@link.it)
  35.  * @author $Author$
  36.  * @version $Rev$, $Date$
  37.  */
  38. public class IntegrationManagerEngineFilter implements Filter {

  39.     @Override
  40.     public void destroy() {

  41.     }

  42.     @Override
  43.     public void doFilter(ServletRequest request, ServletResponse response,
  44.             FilterChain chain) throws IOException, ServletException {

  45.         // L'invocazione dell'I.M. deve avvenire via OpenSPCoopServlet dispatcher
  46.         HttpServletResponse httpRes = (HttpServletResponse) response;
  47.         httpRes.sendError(404, ConnectorUtils.generateError404Message(ConnectorUtils.getFullCodeEngineFilter(IDService.INTEGRATION_MANAGER_SOAP)));

  48.     }

  49.     @Override
  50.     public void init(FilterConfig arg0) throws ServletException {

  51.     }

  52. }