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

ProcessSyntheticAnnotatedType not fired for types added via configurators

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • 7.0.0.Alpha2, 6.0.5.Final
    • 7.0.0.Alpha1, 5.1.7.Final, 6.0.4.Final
    • Extensions
    • None

      Recent work on CDI made me notice an oddity on how Weld handles PAT for synthetic types (noticed this while writing TCKs for https://github.com/jakartaee/cdi-tck/issues/680).

      Technically, all synthetic types should trigger ProcessSyntheticAnnotatedType - a subtype of classical PAT.
      For types added via addAnnotatedType(AnnotatedType, String), this works as expected.
      However, for those added via configurators it doesn't. In such case we end up firing ordinary PAT instead of synthetic one.

      The cause of this seems to be that ContainerEvent#getReceiver() method can no longer detect that a given type was added via an extension. This is because registration of configurator based types actually has to happen after observer method notification.
      We should add special handling for those cases.

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

                Created:
                Updated: