Jetty
  1. Jetty
  2. JETTY-1339

Get rid of dependency to jtidy:jtidy:jar:4aug2000r7-dev

    Details

    • Type: Improvement Improvement
    • Status: Resolved Resolved
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 7.2.2
    • Fix Version/s: None
    • Component/s: Maven
    • Labels:
      None
    • Number of attachments :
      0

      Description

      We have deployed an application to Jetty which uses net.sf.jtidy:jtidy:r938 which for example offers the method setInputEncoding. Running in Jetty it will fail with:

      java.lang.NoSuchMethodError: org.w3c.tidy.Tidy.setInputEncoding(Ljava/lang/String;)V
      

      because the call goes to the JTidy-version provided with Jetty which is jtidy:jtidy:jar:4aug2000r7-dev. This again comes with org.apache.maven.plugin-tools:maven-plugin-tools-api:jar:2.5.1.

      Because of MNG-2163 I know of no workaround to get rid of this dependency.

        Activity

        Hide
        Mark Michaelis added a comment -

        The following Plugin configuration works for me:

              <plugin>
                <groupId>org.mortbay.jetty</groupId>
                <artifactId>jetty-maven-plugin</artifactId>
                <dependencies>
                  <dependency>
                    <groupId>net.sf.jtidy</groupId>
                    <artifactId>jtidy</artifactId>
                    <version>r938</version>
                  </dependency>
                  <dependency>
                    <groupId>org.apache.maven.plugin-tools</groupId>
                    <artifactId>maven-plugin-tools-api</artifactId>
                    <version>2.5.1</version>
                    <exclusions>
                      <exclusion>
                        <groupId>jetty</groupId>
                        <artifactId>jetty</artifactId>
                      </exclusion>
                    </exclusions>
                  </dependency>
                </dependencies>
        [...]
              </plugin>
            </plugins>
        
        Show
        Mark Michaelis added a comment - The following Plugin configuration works for me: <plugin> <groupId> org.mortbay.jetty </groupId> <artifactId> jetty-maven-plugin </artifactId> <dependencies> <dependency> <groupId> net.sf.jtidy </groupId> <artifactId> jtidy </artifactId> <version> r938 </version> </dependency> <dependency> <groupId> org.apache.maven.plugin-tools </groupId> <artifactId> maven-plugin-tools-api </artifactId> <version> 2.5.1 </version> <exclusions> <exclusion> <groupId> jetty </groupId> <artifactId> jetty </artifactId> </exclusion> </exclusions> </dependency> </dependencies> [...] </plugin> </plugins>
        Hide
        Greg Wilkins added a comment -

        Jetty does not depend on jtidy.

        Can you do a

        mvn dependency:tree

        to see what does and reopen if you still think it is jetty

        Show
        Greg Wilkins added a comment - Jetty does not depend on jtidy. Can you do a mvn dependency:tree to see what does and reopen if you still think it is jetty
        Hide
        Mark Michaelis added a comment -

        Actually this issue is caused by MPLUGIN-173. Because Jetty depends on maven-plugin-tools-api it also gets the dependency to the outdated JTidy version as stated before.

        As I found a workaround meanwhile (see my comment before) I assume it is ok for Jetty to ignore the problem and thus I am fine with "Won't Fix".

        Show
        Mark Michaelis added a comment - Actually this issue is caused by MPLUGIN-173 . Because Jetty depends on maven-plugin-tools-api it also gets the dependency to the outdated JTidy version as stated before. As I found a workaround meanwhile (see my comment before ) I assume it is ok for Jetty to ignore the problem and thus I am fine with "Won't Fix".

          People

          • Assignee:
            Unassigned
            Reporter:
            Mark Michaelis
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: