Uploaded image for project: 'MyFaces Core'
  1. MyFaces Core
  2. MYFACES-4461

Faces 4.0: WELD-001408: Unsatisfied dependencies for Push & FlowBuilderParameter

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 4.0.0-RC1
    • 4.0.0-RC2
    • None
    • None

    Description

      FacesArtifactProducer is only registered when @FacesConfig is present.  This means @Push and @FlowBuilderParameter are used, Weld will report these errors:

      WELD-001408: Unsatisfied dependencies for type FlowBuilder with qualifiers @FlowBuilderParameter
      WELD-001408: Unsatisfied dependencies for type PushContext with qualifiers @Push

      This breaks many applications, as what previously worked does not.

      Just for reference: PushContextFactoryBean.java was previously used for the cdi producer registration, but was removed.  The getPushContext method was moved to the FacesArtifactProducer (JsfArtifactProducer).

      https://github.com/apache/myfaces/commit/6f5599a219ae1f19d6a6ba7a8a9dc566b0bff1a4#diff-1184a79edde14f5fcedfb0b2dde1f8e89cb5c259b1f7c3980036ebb4d5bf7d1dL37-L40

      I think the solution is to have Faces behave as if @FacesConfig is present (even when it's not).  In other words, always register cdi producers.
       
      See code here:
      https://github.com/apache/myfaces/blob/main/impl/src/main/java/org/apache/myfaces/cdi/FacesArtifactProducerExtension.java#L32

      Attachments

        Issue Links

          Activity

            People

              volosied Volodymyr Siedlecki
              volosied Volodymyr Siedlecki
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: