Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.6.2-incubating
    • Component/s: odfdom
    • Labels:
      None

      Description

      ODF Toolkit uses obsolete distribution of Jena from HP however there is Apache Jena under current development and management.

      Replicable steps

      The project main method calls following statement.

      OdfSpreadsheetDocument osd = OdfSpreadsheetDocument.loadDocument(new File("example.ods"));
      

      The project uses the up-to-date Jena dependency from Apache Jena repository.

      <dependency>
          <groupId>org.apache.jena</groupId>
          <artifactId>jena-core</artifactId>
          <version>3.0.0</version>
      </dependency>
      <dependency>
           <groupId>org.apache.jena</groupId>
           <artifactId>jena-arq</artifactId>
           <version>3.0.0</version>
      </dependency>
      

      Despite that the application fails with

      Exception in thread "main" java.lang.NoClassDefFoundError: com/hp/hpl/jena/rdf/model/RDFNode
      	at org.odftoolkit.odfdom.pkg.OdfFileDom.initialize(OdfFileDom.java:215)
      	at org.odftoolkit.odfdom.pkg.manifest.OdfManifestDom.initialize(OdfManifestDom.java:74)
      	at org.odftoolkit.odfdom.pkg.OdfFileDom.<init>(OdfFileDom.java:132)
      	at org.odftoolkit.odfdom.pkg.manifest.OdfManifestDom.<init>(OdfManifestDom.java:63)
      	at org.odftoolkit.odfdom.pkg.OdfFileDom.newFileDom(OdfFileDom.java:189)
      	at org.odftoolkit.odfdom.pkg.OdfPackage.parseManifest(OdfPackage.java:1219)
      	at org.odftoolkit.odfdom.pkg.OdfPackage.readZip(OdfPackage.java:452)
      	at org.odftoolkit.odfdom.pkg.OdfPackage.initializeZip(OdfPackage.java:422)
      	at org.odftoolkit.odfdom.pkg.OdfPackage.<init>(OdfPackage.java:250)
      	at org.odftoolkit.odfdom.pkg.OdfPackage.loadPackage(OdfPackage.java:320)
      	at org.odftoolkit.odfdom.doc.OdfDocument.loadDocument(OdfDocument.java:232)
      	at org.odftoolkit.odfdom.doc.OdfSpreadsheetDocument.loadDocument(OdfSpreadsheetDocument.java:155)
      

      The problem is that OdfFileDom.java uses obsolete HP package name.

      Workaround

      Following duplicate Jena dependency workarounds the issue:

      <dependency>
      	<groupId>com.hp.hpl.jena</groupId>
      	<artifactId>jena</artifactId>
      	<version>2.5.5</version>
      </dependency>
      

        Activity

        Hide
        svanteschubert Svante Schubert added a comment -

        fixed in upcoming release

        Show
        svanteschubert Svante Schubert added a comment - fixed in upcoming release
        Hide
        svanteschubert Svante Schubert added a comment -

        fixed for upcoming release

        Show
        svanteschubert Svante Schubert added a comment - fixed for upcoming release
        Hide
        svanteschubert Svante Schubert added a comment -

        reopening to add 'fixed version' JIRA attribute of upcoming release

        Show
        svanteschubert Svante Schubert added a comment - reopening to add 'fixed version' JIRA attribute of upcoming release
        Hide
        svanteschubert Svante Schubert added a comment -

        fixed

        Show
        svanteschubert Svante Schubert added a comment - fixed
        Hide
        svanteschubert Svante Schubert added a comment -

        Already fixed in current sources

        Show
        svanteschubert Svante Schubert added a comment - Already fixed in current sources

          People

          • Assignee:
            svanteschubert Svante Schubert
            Reporter:
            jspetrak Josef PetrĂ¡k
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development