0

I have a Maven project where I am using the Jongo dependency with the following POM.

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.xxx</groupId>
    <artifactId>mytracker</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>jar</packaging>

    <name>mytracker</name>
    <url>http://maven.apache.org</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <maven.compiler.source>1.7</maven.compiler.source>
        <maven.compiler.target>1.7</maven.compiler.target>

    </properties>
    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.11</version>
        </dependency>
        <dependency>
            <groupId>com.yammer.dropwizard</groupId>
            <artifactId>dropwizard-core</artifactId>
            <version>0.6.2</version>
        </dependency>
        <dependency>
            <groupId>net.vz.mongodb.jackson</groupId>
            <artifactId>mongo-jackson-mapper</artifactId>
            <version>1.4.2</version>
        </dependency>
        <dependency>
            <groupId>org.jongo</groupId>
            <artifactId>jongo</artifactId>
            <version>1.2</version>
        </dependency>
        <dependency>
            <groupId>org.joda</groupId>
            <artifactId>joda-money</artifactId>
            <version>0.10.0</version>
        </dependency>
        <dependency>
            <groupId>com.sun.jersey.jersey-test-framework</groupId>
            <artifactId>jersey-test-framework-core</artifactId>
            <version>1.19</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.sun.jersey</groupId>
            <artifactId>jersey-client</artifactId>
            <version>1.19</version>
        </dependency>

        <dependency>
            <groupId>com.sun.jersey.test.framework</groupId>
            <artifactId>jersey-test-framework</artifactId>
            <version>1.0.3.1</version>

        </dependency>
        <dependency>
            <groupId>javax</groupId>
            <artifactId>javaee-api</artifactId>
            <version>7.0</version>
        </dependency>
    </dependencies>

</project>

Now when I run my Main class , I get the following error in eclipse , although the project is built successfully using Maven , this error shows up when I run the Main class. I am using JDK 1.7 ,any ideas ?

Exception in thread "main" java.lang.VerifyError: (class: org/jongo/marshall/jackson/configuration/AbstractMappingBuilder, method: <init> signature: ()V) Incompatible argument to function
    at org.jongo.Jongo.<init>(Jongo.java:32)
    at com.mycompany.mytracker.CashbackService.run(CashbackService.java:44)
    at com.mycompany.mytracker.CashbackService.run(CashbackService.java:18)
    at com.yammer.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:38)
    at com.yammer.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:58)
    at com.yammer.dropwizard.cli.Cli.run(Cli.java:53)
    at com.yammer.dropwizard.Service.run(Service.java:61)
    at com.mycompany.mytracker.CashbackService.main(CashbackService.java:22)
user1965449
  • 2,849
  • 6
  • 34
  • 51

1 Answers1

0

I removed the following dependency and it solved my problem.

<dependency>
    <groupId>net.vz.mongodb.jackson</groupId>
    <artifactId>mongo-jackson-mapper</artifactId>
    <version>1.4.2</version>
</dependency>
user1965449
  • 2,849
  • 6
  • 34
  • 51