Results 1 to 2 of 2

Thread: Exclude a controller from interceptor mapping

  1. #1
    Join Date
    Nov 2009
    Location
    Boston,MA
    Posts
    8

    Default Exclude a controller from interceptor mapping

    Hi Folks,

    I am having a bit of an issue configuring my interceptors and was hoping someone might have figured this out.

    I am using Spring 3 with annotated controllers, and everything is loading and functioning fine. Every controller gets intercepted by my two declared HandlerInterceptors. Here is my configuration:

    Code:
    <mvc:interceptors>
      <bean class="com.matt.MdcSetupInterceptor" />
      <bean class="com.matt.AuthInterceptor" />
    </mvc:interceptors>
    I want to apply these two interceptors to every controller EXCEPT my HomePageController, but for the life of me I can't figure out how to do that.

    I have seen plenty of examples on the forum on how to setup interceptors that interceptor a single controller using the "mapping" attribute in the mvc:interceptors declaration, but none on how to exclude one.

    Is there a way to reflect a "Not" in the mapping tag?

    Thanks in advance for your help or for pointing me to a link that explains it.

    - matt

  2. #2
    Join Date
    Nov 2009
    Location
    Boston,MA
    Posts
    8

    Default

    No love for this question?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •