Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

org.eclipse.jetty dependency clash between citrus-http and citrus-remote-server #441

Open
u480abt opened this issue Aug 7, 2018 · 1 comment

Comments

@u480abt
Copy link

u480abt commented Aug 7, 2018

Citrus Version
2.7.6

Hi,

unfortunatly there is a dependency clash in citrus dependencies for org.eclipse jetty.

My Test-Setup is:

  • HttpServer-Mock (needs 'citrus-http' dependency)
  • run citrus-tests in an openshift environment, so i used the citrus-remote-plugin and the dependency 'citrus-remote-server' to build a war, which is deployed in an tomcat docker image on openshift.
  • the remote plugin creates a war with all transistive depenedencies inside the web-inf/lib folder.
  • so i got jetty 9.4.6 libs and some jetty 9.4.8 libs in the lib-folder.
  • while citrus tries to start the jetty for my HttpServerMock in my tomcat docker image i got magic org.eclipse.jetty exceptions

Hotfix
I could solve this problem by excluding the org.eclipse.jetty dependencies from the citrus-http-dependency. But this is just a hotfix and should be solved by citrus in future.

<dependency>
            <groupId>com.consol.citrus</groupId>
            <artifactId>citrus-remote-server</artifactId>
        </dependency>
        <dependency>
            <groupId>com.consol.citrus</groupId>
            <artifactId>citrus-http</artifactId>
            <exclusions>
                <exclusion>
                    <groupId>org.eclipse.jetty</groupId>
                    <artifactId>jetty-server</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>org.eclipse.jetty</groupId>
                    <artifactId>jetty-servlet</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

Kind regards
abt

@svettwer
Copy link
Contributor

svettwer commented Aug 7, 2018

Hi!

Thx for the report!
I traced down the issue to the spark-core dependency which is using jetty 9.4.8 internally.

<dependency>
      <groupId>com.sparkjava</groupId>
      <artifactId>spark-core</artifactId>
</dependency>

This issue could also occur when you use citrus-http in combination with citrus-jdbc, because citrus-jdbc is also using the spark-core.

BR,
Sven

@christophd christophd removed the READY label Oct 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants