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

Weld class should be easier to extend to introduce custom behavior, for example the ability to replace the ResourceLoader

    Details

    • Type: Feature Request
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 1.0.1.Final
    • Fix Version/s: 1.1.0.Beta1
    • Component/s: Java SE Support
    • Labels:
      None
    • Environment:

      Weld SE + Java 6

      Description

      According to the docs "org.jboss.weld.resources.spi.ResourceLoader" is responsible for resource loading/class creation and if it worked it would appear to solve a lot of potential integration problems, f.x. with OSGI (see issue 520).

      Unfortunately, Weld SE does not apper to use ResourceLoaders and it ignores any implementations of this service that the Java SE app supplies. Even worse, Weld SE classloading behavior is hardcoded in "org.jboss.weld.environment.se.util.Reflections". This makes it impossible to use Weld SE where classloading does not work with the Thread's context class loader such as OSGI etc.

      Weld SE should be changed to look for service implementations of "org.jboss.weld.resources.spi.ResourceLoader" (i.e. actually work according to its own documentation).

      P.S: It would also be nice if Weld SE would allow users to supply a Classloader to the constructor for org.jboss.weld.environment.se.Weld

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                peteroyle Peter Royle
                Reporter:
                mmc41 Morten Christensen
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: