Uploaded image for project: 'NetBeans'
  1. NetBeans
  2. NETBEANS-1774

Netigso tries to load classes from an OSGi fragment bundle instead of the host bundle

    XMLWordPrintableJSON

Details

    Description

      We are using a library with fragmented OSGi bundles in our NetBeans Platform application. The bundles resolve fine, but during runtime the NetigsoLoader instance that was created for the bundle tries to load classes from the fragment, instead of the host. This is not desirable, and e.g. Felix throws an exception (see link 1).

      The issue is in Netigso, in the createLoader method, which doesn't handle the caught BundleException correctly (thrown when trying to start the fragment, see link 2).

      I have fixed this for our application by simply looking up the fragments host bundle and substituting the fragment with its host in the created NetigsoLoader.

      Apache Felix, class Felix, line 2062

      Apache NetBeans, class Netigso, line 329

       

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              iajn Iiro Nykänen
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 20m
                  1h 20m