title: excludePathPatterns Not Working -- Spring
body: <p>I have a controller class:</p>
  
  <pre><code>import org.springframework.beans.factory.annotation.Autowired;
  import org.springframework.web.bind.annotation.*;
  
  import java.util.Map;
  
  @RestController
  @RequestMapping("/wha")
  public class Controlla {
  
      @RequestMapping(method= RequestMethod.POST)
      public @ResponseBody Map&lt;String, Object&gt; hollow(@RequestBody Map&lt;String, Object&gt; body) {
          return body;
      }
  }
  </code></pre>
  
  <p>And an interceptor class which intercepts the request. This is how I add the interceptor:</p>
  
  <pre><code>@Bean
  public Interc inter() {
      return new Interc();
  }
  
  @Override
  public void addInterceptors(InterceptorRegistry registry) {
      registry.addInterceptor(inter())
              .addPathPatterns("/**")
              .excludePathPatterns("/**/wha/**");
  }
  </code></pre>
  
  <p>The request does get intercepted, but it's like the <code>excludePathPatterns</code> is not even there. It doesn't work. I'm running Spring version 4.2.4.RELEASE. I've looked around on the internet and stack overflow but still couldn't get this resolved.</p>