logo
down
shadow

Could not find artifact com.sun:tools:jar:0


Could not find artifact com.sun:tools:jar:0

By : bproof
Date : November 19 2020, 07:01 PM
I think the issue was by ths following , You're on JDK 11.
The JEP 220 removed both tools.jar and rt.jar from the lib folder.
code :
<plugin>
   <groupId>org.apache.maven.plugins</groupId>
   <artifactId>maven-checkstyle-plugin</artifactId>
   <version>3.0.0</version>
   <dependencies>
     <dependency>
        <groupId>com.puppycrawl.tools</groupId>
        <artifactId>checkstyle</artifactId>
        <version>8.18</version>
     </dependency>
   </dependencies>
</plugin>


Share : facebook icon twitter icon
Jenkins fails to build maven project (Could not find artifact com.sun:tools:jar:1.5.0)

Jenkins fails to build maven project (Could not find artifact com.sun:tools:jar:1.5.0)


By : 3lzvvjn
Date : March 29 2020, 07:55 AM
it should still fix some issue You trying to run the build under a 1.5 JRE instead of JDK which is required by Maven to run. You need a 1.5 JDK and not only a JRE!
Buiding Hadoop with Eclipse / Maven - Missing artifact jdk.tools:jdk.tools:jar:1.6

Buiding Hadoop with Eclipse / Maven - Missing artifact jdk.tools:jdk.tools:jar:1.6


By : chidhambaram bhagava
Date : March 29 2020, 07:55 AM
Hope this helps jdk.tools:jdk.tools (or com.sun:tools, or whatever you name it) is a JAR file that is distributed with JDK. Usually you add it to maven projects like this:
code :
<dependency>
    <groupId>jdk.tools</groupId>
    <artifactId>jdk.tools</artifactId>
    <scope>system</scope>
    <systemPath>${java.home}/../lib/tools.jar</systemPath>
</dependency>
mvn install:install-file -DgroupId=jdk.tools -DartifactId=jdk.tools -Dpackaging=jar -Dversion=1.6 -Dfile=tools.jar -DgeneratePom=true
<dependency>
    <groupId>jdk.tools</groupId>
    <artifactId>jdk.tools</artifactId>
    <version>1.6</version>
</dependency>
Maven build for Grails 2.2.0 app fails with JDK 1.7: Could not find artifact com.sun:tools:jar:1.6

Maven build for Grails 2.2.0 app fails with JDK 1.7: Could not find artifact com.sun:tools:jar:1.6


By : Tenghui Liu
Date : March 29 2020, 07:55 AM
Hope this helps It seems to be a known issue and reportedly still happening in Grails 2.2.0 on Mac OS X.
http://jira.grails.org/browse/MAVEN-186
In the pom.xml for a java project, I get missing artifact jdk.tools:jdk.tools:jar:1.6 error

In the pom.xml for a java project, I get missing artifact jdk.tools:jdk.tools:jar:1.6 error


By : Jpatil
Date : March 29 2020, 07:55 AM
this one helps. I finally tackled this the proper way.
This happens when eclipse is launched with the JRE instead of the JDK as tools.jar isn't in the JRE. Based on that assertion, try installing the JDK. If it's already installed, check in your Path that you have the JDK path and not the JRE path.
Could not find artifact com.sun:tools:jar:1.7

Could not find artifact com.sun:tools:jar:1.7


By : Mohammed Ali
Date : March 29 2020, 07:55 AM
hop of those help? Here is my pom.xml , Short Answers :
code :
<dependency>
    <groupId>...</groupId>
    <artifactId>...</artifactId>
    <version>3.1.8</version>
    <scope>test</scope>
    <exclusions>
        <exclusion>
            <groupId>com.sun</groupId>
            <artifactId>tools</artifactId>                    
        </exclusion>
    </exclusions>            
</dependency>
$ mvn dependency:tree  | grep -B 10  -A 1 tools.jar

[INFO] +- io.fabric8:kubernetes-server-mock:jar:3.1.8:test
[INFO] |  \- io.fabric8:mockwebserver:jar:0.1.0:test
[INFO] |     +- com.squareup.okhttp3:mockwebserver:jar:3.9.0:test
[INFO] |     |  \- org.bouncycastle:bcprov-jdk15on:jar:1.50:test
[INFO] |     \- io.sundr:builder-annotations:jar:0.2.7:test
[INFO] |        +- io.sundr:sundr-core:jar:0.2.7:test
[INFO] |        +- io.sundr:sundr-codegen:jar:0.2.7:test
[INFO] |        |  \- org.apache.velocity:velocity:jar:1.7:test
[INFO] |        |     +- commons-collections:commons-collections:jar:3.2.1:test
[INFO] |        |     \- commons-lang:commons-lang:jar:2.4:test
[INFO] |        \- com.sun:tools:jar:1.7:system
[INFO] +- org.apache.commons:commons-lang3:jar:3.4:compile
    <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>kubernetes-server-mock</artifactId>
        <version>3.1.8</version>
        <scope>test</scope>
        <exclusions>
            <exclusion>
                <groupId>com.sun</groupId>
                <artifactId>tools</artifactId>                    
            </exclusion>
        </exclusions>            
    </dependency>
Related Posts Related Posts :
  • How to get number of bytes?
  • How to parse WSDL in Java?
  • google maps with my application
  • How to use Eclipse for both Java and PHP?
  • redirecting output of a cmd to a file
  • 16 bits bit depth
  • Using a JMS Session from different threads
  • how to call method of Owner?
  • Java - Interfaces
  • What is the best way to create a random value?
  • Jar File doesn't work (It did not launch the application)
  • Explain JAVA code
  • Display HTML Formatted String
  • Generate random letters and numbers together
  • how to implement this observer pattern?
  • How do I run different threads in Java?
  • Java import from other directory
  • Form based authentication in java
  • Delete a line from a file in java
  • Java overloading and overriding
  • how to share a variable between two threads
  • How to get the IP address from the Domain Name in Java?
  • Does Socket open another thread? Does it return something?
  • Random select rows via JPA
  • How do i get a .wav sound to play?
  • How to render a PDF file in Android
  • Java method help
  • Sending an int from Java to C using sockets
  • Convert XML to Java DTO and back in GWT
  • java OutOfMemoryError
  • Collision detection in Java game?
  • Handling multiple exceptions
  • regarding java version 1.3 to 1.4
  • JPA where clause any
  • How to compile many java class?
  • how to convert byte array to image in java?
  • String division
  • Can't delete a file
  • invalid byte 2 of 2-byte UTF-8 sequence
  • Passing "this" in java constructor
  • Template engine recommendations
  • Help with hash tables and quadratic probing in Java
  • javax.persistence.NoResultException: getSingleResult() did not retrieve any entities
  • What does look and feel (java swing) mean?
  • Android Lightweight HTML Template Engine
  • Setting unique key constraint for Db4oEmbedded EmbeddedConfiguration
  • How can I handle user defined exceptions and after handling them resume the flow of program
  • Latest org.json
  • How to create web service client in a .jsp page?
  • Java Runtime command line Process
  • Android: add badge to icons internal to my app
  • spymemcached - is it possible to disable the logging system?
  • Java Logger with Servlets
  • replace special characters in string in java
  • why won't Eclipse use the compiler I specify for my project?
  • Google Web Toolkit, what can I do with it?
  • doubt on private members and Methods
  • How do I check if output stream of a socket is closed?
  • Is there a clean cut way of adding NOP records to an AFP file using Java?
  • Move multiple BufferedImage in Java2D?
  • shadow
    Privacy Policy - Terms - Contact Us © 35dp-dentalpractice.co.uk