Maven problem with invalid jar file which is actually html

Recently, I ran into a problem in my maven assembly that downloads a jar file for javamail-1.4.jar or something like that, but it turns out that the file is not a real jar file, it is actually an html with a link to something where you can get the right jar.

it looks like the repo has changed for this. but in the setup of my maven everything should go to our internal repo, I don’t know how it happened. but in any case, more importantly, how can I fix this problem so that it downloads the correct jar file on a new installation?

thank!

+3
source share
1 answer

settings.xml ~ ~ , , . , , ( javamail , ). , .

: , log4j, log4j 1.2.15. , , log4j 1.2.14, log4j 1.2.15:

<dependency>
  <groupId>log4j</groupId>
  <artifactId>log4j</artifactId>
  <version>1.2.15</version>
  <exclusions>
    <exclusion>
      <groupId>javax.mail</groupId>
      <artifactId>mail</artifactId>
    </exclusion>
    <exclusion>
      <groupId>javax.jms</groupId>
      <artifactId>jms</artifactId>
    </exclusion>
    <exclusion>
      <groupId>com.sun.jdmk</groupId>
      <artifactId>jmxtools</artifactId>
    </exclusion>
    <exclusion>
      <groupId>com.sun.jmx</groupId>
      <artifactId>jmxri</artifactId>
    </exclusion>
  </exclusions>
</dependency>
+1

Source: https://habr.com/ru/post/1737620/


All Articles