Uploaded image for project: 'Weld'
  1. Weld
  2. WELD-2790

Remove validation of interceptor binding target declaration for lifecycle interceptors

XMLWordPrintable

      Based on a recent discussion on the weld-dev mailing list, I noticed that we still keep an interceptor binding target validation for one special case.

      Previously, the interceptors spec contained the following statement:

      With the exception of AroundConstruct lifecycle callback interceptors, an interceptor for lifecycle callbacks may only declare interceptor binding types that are defined as Target(TYPE)

      This has been removed with interceptors 1.2 (maintenance release 3) as the restriction doesn't make much sense; the same class can have other interceptors in it that might make use of bindings that can target methods too.
      Not that Weld never threw an exception, we just logged a warning. Aforementioned validation logic as well as the logging message should now be removed.

              manovotn Matěj Novotný
              manovotn Matěj Novotný
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: