3 Replies Latest reply on Sep 8, 2010 9:39 PM by aarong

    org.osgi.framework.BundleException: Exporting java.* packages not allowed:

    aarong

      I have a simple WebService consumer that I generated the code from a WSDL.

       

      It compiles, and appears to "bundle" correctly. However when I do an:

       

      osgi:install com.company.test/ingest 

       

      I get the  error:

       

      org.osgi.framework.BundleException: Exporting java. packages not allowed: com.company.test

       

      ..any thoughts?

       

      FUSE 4.3

       

      Edited by: aarong on Sep 8, 2010 7:42 PM

        • 1. Re: org.osgi.framework.BundleException: Exporting java.* packages not allowed:
          aarong

          Thought it was fixed...generate-sources never happened, so, that is why it appeared to work..because there were no .class files to "install"

           

          Edited by: aarong on Sep 8, 2010 8:39 PM

          • 2. Re: org.osgi.framework.BundleException: Exporting java.* packages not allowed:
            aarong

            With use 4.3-01 I now get:

             

             

            org.osgi.framework.BundleException: Invalid manifest header Export-Package: "com.company.test;uses:="javax.xml.bind.annotation,javax.xml.datatype,javax.xml.ws,javax.xml.namespace,javax.jws.soap,javax.jws,javax.xml.bind"" : Cannot specify java.* packages in Import/Export headers "com.company.test"

             

             

            I am using Java 1.6, as the VM..I wonder, if there is something down that route causing the fun, cause, after removing the javax.xml.bind & javax.xml.ws & geronimo dependencies because those are now in JDK 1.6_20, don't need those.

            • 3. Re: org.osgi.framework.BundleException: Exporting java.* packages not allowed:
              aarong

              Getting closer.  It has something to do with the felix plugin.

               

              If I use version 2.0.0 or less, of the

               

                              

               

              In the MAINFEST.MF, there is no Export-Package property.  Which is what I want...becuase I don't have any Export-Package instructions.

               

              However, using version 2.0.1 or 2.1 it for some reason it creates an Export-Package property, and that is causing the problem....I think

               

              I found this:

               

              https://issues.apache.org/jira/browse/FELIX-912

               

              but not really sure if this helps my case, because it says the default Export-Package started in 2.0.0