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

BeanManager#getReference always creates child CreationalContext which can lead to issues when destroying instance

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 5.1.1.Final
    • 5.1.0.Final
    • None
    • None

      Currently, using BM#getReference to create a dependent bean which itself has an interceptor with another dependent instance injected into it can lead to problems when attempting to destroy the whole hierarchy via Bean#destroy

      The test attached to the PR will explain this scenario.

      Note that we are going to need a new TCK release (anything past 4.0.9) to be able to implement this fix, otherwise we are failing a TCK test that is being challenged in https://github.com/jakartaee/cdi-tck/issues/454
      See the PR comment explaining this - https://github.com/weld/core/pull/2836#issuecomment-1544112981

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

              Created:
              Updated:
              Resolved: