Can't resolve dependency

I’m trying to use the following dependency,

<!-- https://mvnrepository.com/artifact/javax.media/jai_imageio -->
		<dependency>
		    <groupId>javax.media</groupId>
		    <artifactId>jai_imageio</artifactId>
		    <version>1.1</version>
		</dependency>

But I get the following error during build,

[ERROR] Failed to execute goal on project pdf-common: Could not resolve dependencies for project com.mycompany.ignition:pdf-common:jar:1.0.0: Failed to collect dependencies at javax.media:jai_imageio:jar:1.1: Failed to read artifact descriptor for javax.media:jai_imageio:jar:1.1: Could not transfer artifact javax.media:jai_imageio:pom:1.1 from/to snapshots (http://nexus.inductiveautomation.com/repository/inductiveautomation-snapshots): Failed to transfer http://nexus.inductiveautomation.com/repository/inductiveautomation-snapshots/javax/media/jai_imageio/1.1/jai_imageio-1.1.pom. Error code 400, Repository version policy: SNAPSHOT does not allow version: 1.1 -> [Help 1]

I’ve tried adding the mvnrepository to my main pom, no dice. How do I use this dependency if it isn’t in the nexus repo?

1 Like

What does the repository management section of your pom.xml look like? Do you only have our snapshots repo listed?

    <repositories>
        <repository>
            <id>releases</id>
            <url>http://nexus.inductiveautomation.com/repository/inductiveautomation-releases</url>
        </repository>

        <repository>
            <id>snapshots</id>
            <url>http://nexus.inductiveautomation.com/repository/inductiveautomation-snapshots</url>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
            </snapshots>
        </repository>

        <repository>
            <id>thirdparty</id>
            <url>http://nexus.inductiveautomation.com/repository/inductiveautomation-thirdparty
            </url>
        </repository>
        
    	<repository>
            <id>javax.media</id>
	    <url>https://mvnrepository.com/artifact/</url>
	    <snapshots>
	        <enabled>true</enabled>
	        <updatePolicy>always</updatePolicy>
	    </snapshots>
    	</repository>

    
    </repositories>

I figured it out, sorry for wasting time. I noob.

The repo url was incorrect,

<repository>
    	<id>javax</id>
	<url>http://maven.geotoolkit.org/</url>
	<snapshots>
		    <enabled>true</enabled>
		    <updatePolicy>always</updatePolicy>
	</snapshots>
</repository>
1 Like

2 posts were split to a new topic: 8.0.0-SNAPSHOT dependency not found