    /**
     * Introspects the injector and collects all instances of bound {@code List<FilterDefinition>}
     * into a master list.
-@@ -84,86 +74,4 @@ class ManagedFilterPipeline implements FilterPipeline{
+@@ -84,89 +74,4 @@ class ManagedFilterPipeline implements FilterPipeline{
      // Copy to a fixed-size array for speed of iteration.
      return filterDefinitions.toArray(new FilterDefinition[filterDefinitions.size()]);
    }
 -
--  public synchronized void initPipeline(ServletContext servletContext)
--      throws ServletException {
+-  @Override
+-  public synchronized void initPipeline(ServletContext servletContext) throws ServletException {
 -
 -    //double-checked lock, prevents duplicate initialization
 -    if (initialized)

Description: Let sub-classes of GuiceFilter customize the servlet filter pipeline
Author: Stuart McCulloch <mcculls@gmail.com>
Bug-Google: http://code.google.com/p/google-guice/issues/detail?id=618
Last-Update: 2016-07-04

diff --git a/extensions/servlet/src/com/google/inject/servlet/AbstractFilterPipeline.java b/extensions/servlet/src/com/google/inject/servlet/AbstractFilterPipeline.java
new file mode 100644
index 0000000..ab8f746
--- /dev/null
+++ b/extensions/servlet/src/com/google/inject/servlet/AbstractFilterPipeline.java
@@ -0,0 +1,150 @@
+/**
+ * Copyright (C) 2008 Google Inc.
+ *

-            doServiceImpl(servletDefinition, requestToProcess, servletResponse);
-          }
-
-          @Override
-          public void include(ServletRequest servletRequest, ServletResponse servletResponse)
-              throws ServletException, IOException {
-            // route to the target servlet
-            doServiceImpl(servletDefinition, servletRequest, servletResponse);
-          }
-
-          private void doServiceImpl(
-              ServletDefinition servletDefinition,
-              ServletRequest servletRequest,
-              ServletResponse servletResponse)
-              throws ServletException, IOException {
-            servletRequest.setAttribute(REQUEST_DISPATCHER_REQUEST, Boolean.TRUE);
-
-            try {
