Maven build downloading from wrong link

I'm trying to build my project using Maven but when my dependencies start to download. The download link for Jackson-annotation is incorrect. The version is not added to the link as shown below (${jackson.version.annotations}).

https://na.artifactory.blabla.com/artifactory/sysdse-maven-blabla/com/fasterxml/jackson/core/jackson-annotations/${jackson.version.annotations}/jackson-annotations-${jackson.version.annotations}.pom

I am pulling my dependencies from artifactory. So the repository is correct just not the version.

Here is my pom.xml file:

<dependency>
   <groupId>com.fasterxml.jackson.core</groupId>
   <artifactId>jackson-annotations</artifactId>
   <version>2.9.7</version>
</dependency>

This is the error message I am getting.

WARN org.apache.maven.DefaultMaven - The POM for com.fasterxml.jackson.core:jackson-annotations:jar:2.9.7 is invalid, transitive dependencies (if any) will not be available: 1 problem was encountered while building the effective model for com.fasterxml.jackson.core:jackson-annotations:2.9.7
[ERROR] 'dependencies.dependency.version' for junit:junit:jar is missing. @
ERROR org.apache.maven.cli.MavenCli - Failed to execute goal on project cde-pilot: Could not resolve dependencies for project com.ibm:cde-pilot:jar:1.0-SNAPSHOT: Failed to collect dependencies at com.fasterxml.jackson.core:jackson-databind:jar:2.9.7 -> com.fasterxml.jackson.core:jackson-annotations:jar:${jackson.version.annotations}: Failed to read artifact descriptor for com.fasterxml.jackson.core:jackson-annotations:jar:${jackson.version.annotations}: Could not transfer artifact com.fasterxml.jackson.core:jackson-annotations:pom:${jackson.version.annotations} from/to artifactory-release (https://na.artifactory.blabla.com/artifactory/sysdse-maven-blabla): Illegal character in path at index 117: https://na.artifactory.blabla.com/artifactory/sysdse-maven-blabla/com/fasterxml/jackson/core/jackson-annotations/${jackson.version.annotations}/jackson-annotations-${jackson.version.annotations}.pom

1 answer

  • answered 2019-06-12 10:49 Ximenthis

    Have you tried to add this to your pom.xml?

    <properties>
    <jackson.annotations.version>2.9.7</jackson.annotations.version>
    </properties>