Jahia in English > Error: org.osgi.framework.Bund...

0 (0 Good)
0 (0 Bad)

Error: org.osgi.framework.BundleException: Unresolved constraint in bundle db-source-provider ......

by  omglion »  2014/07/17 08:57

Hello, everybody,

I hava a problem now. I want to access an external datasource: a table in the mysql database.

After i finished coding and deployed these codes to Jahia, i got an error message when i reboot Jahia:

Error: org.osgi.framework.BundleException: Unresolved constraint in bundle db-source-provider [127]: Unable to resolve 127.1: missing requirement [127.1] osgi.wiring.package; (osgi.wiring.package=com.mchange.v2.c3p0)

What does it mean?

Should i add OSGI MANIFEST.MF file and Activator.java into the module?

Thanks.

Kindly regards

Lion

  • Error: org.osgi.framework.BundleException: Unresolved constraint in bundle db-source-provider ......
    2014/07/17 08:57

    omglion <p>Hello, everybody,</p> <p>I hava a problem now. I want to access an external datasource: a table in the mysql database.</p> <p>After i finished coding and deployed these codes to Jahia, i got an error message when i reboot Jahia:</p> <p>Error: org.osgi.framework.BundleException: Unresolved constraint in bundle db-source-provider [127]: Unable to resolve 127.1: missing requirement [127.1] osgi.wiring.package; (osgi.wiring.package=com.mchange.v2.c3p0)</p> <p>What does it mean?</p> <p>Should i add OSGI MANIFEST.MF file and Activator.java into the module?</p> <p>Thanks.</p> <p>Kindly regards</p> <p>Lion</p>

  • Number of messages  27
    Registration date Jul 17, 2014
    0 (0 Good)
    0 (0 Bad)

    Re: Error: org.osgi.framework.BundleException: Unresolved constraint in bundle db-source-provider ......

    by  qlamerand »  2014/11/26 16:52

    Hello,
    You could try to exclude this package from the import packages as it's probably an optional package coming from mysql-connector-java.
    You should have in your pom.xml something like :

          <plugin>
            <groupId>org.apache.felix</groupId>
            <artifactId>maven-bundle-plugin</artifactId>
            <extensions>true</extensions>
            <configuration>
              <instructions>
                <Import-Package>${jahia.plugin.projectPackageImport},!com.mchange.v2.c3p0,*</Import-Package>
              </instructions>
            </configuration>
          </plugin>

    Regards,
    Quentin

  • Re: Error: org.osgi.framework.BundleException: Unresolved constraint in bundle db-source-provider ......
    2014/11/26 16:53

    qlamerand <p>Hello,<br /> You could try to exclude this package from the import packages as it&#39;s probably an optional package coming from mysql-connector-java.<br /> You should have in your pom.xml something like :</p> <blockquote> <p>&nbsp; &nbsp; &nbsp; &lt;plugin&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &lt;groupId&gt;org.apache.felix&lt;/groupId&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &lt;artifactId&gt;maven-bundle-plugin&lt;/artifactId&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &lt;extensions&gt;true&lt;/extensions&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &lt;configuration&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;instructions&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;Import-Package&gt;${jahia.plugin.projectPackageImport},<strong>!com.mchange.v2.c3p0</strong>,*&lt;/Import-Package&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;/instructions&gt;<br /> &nbsp; &nbsp; &nbsp; &nbsp; &lt;/configuration&gt;<br /> &nbsp; &nbsp; &nbsp; &lt;/plugin&gt;</p> </blockquote> <p>Regards,<br /> Quentin</p>

  • Number of messages  28
    Registration date Nov 26, 2014
    Contact
    Share
    Feedback

    Get in touch

    Whether you are a current user or if you are just evaluating Jahia, we are here to help.

    Contact us

    Share this page