Slazer
Slazer

Reputation: 4990

How to setup latest Dozer version?

I need to use Dozer 6.5.0 (because of this) so I added the following snippet from MVNrepository into my pom.xml.

<!-- https://mvnrepository.com/artifact/com.github.dozermapper/dozer-core -->
<dependency>
    <groupId>com.github.dozermapper</groupId>
    <artifactId>dozer-core</artifactId>
    <version>6.5.0</version>
</dependency>

The project builds, but there are multiple problems.

  1. Old version of Dozer is used instead. I know that, because my logs refer to ~[dozer-5.5.1.jar:na] and the bug persists.
  2. IntelliJ complains that Dependency 'com.github.dozermapper:dozer-core:6.5.0' not found.

I think it uses the older version from some other maven repository I use. It imports org.dozer.Mapper. How can I use the latest version?

Upvotes: 1

Views: 2283

Answers (1)

Slazer
Slazer

Reputation: 4990

There were two problems.

  • It was a Maven multi-module project and the subproject was using the old Dozer version setup in its pom.xml
  • The Dozer library was not downloaded by Maven for some reason. I had to download it and set it up manually. I deleted the jar files of old Maven in File >> Project Structure >> Libraries and imported the new Dozer library I downloaded elsewhere.

Now it works. Don't know why the Dozer JAR was not retrieved automatically by Maven, though.

Upvotes: 1

Related Questions