Tag Archives: IDEA

IDEA Compile Kotlin Project Error: Cannot inline bytecode buit with JVM target 1.8 into bytecode that is being built with JVM target 1.6.Please specify proper ‘-jvm-target’ option

Reason: the target set by idea’s default kotlin compiler is 1.6, which can be modified to 1.8 or above

[Solved] IDEA Error: Failed to resolve org.junit.platform:junit-platform-launcher

Reason for the problem:
the problem here is that IntelliJ tries to solve the required artifact itself without using the Maven “user settings file” (settings. XML) configured in the IDE. It will connect directly to Maven central, but it is blocked by my employer

Solution add in POM file:

 <!-- this is needed or IntelliJ gives junit.jar or junit-platform-launcher:1.3.2 not found errors -->

IDEA Run mapreduce error: PATH Set Error [How to Solve]

Error Message:
[[email protected] servers]# hadoop jar loginVisit.jar cn.itcast.loginVisit.step1.Step1Main
19/07/17 22:14:59 INFO client.RMProxy: Connecting to ResourceManager at node01/
19/07/17 22:14:59 WARN security.UserGroupInformation: PriviledgedActionException as:root (auth:SIMPLE) cause:java.net.ConnectException: Call From node01.hadoop.com/ to node02:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
Exception in thread “main” java.net.ConnectException: Call From node01.hadoop.com/ to node02:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)



Step1Main.java, path set error.
TextOutputFormat.setOutputPath(job,new Path(“hdfs://node02:8020/loginVisit/output3”));
Change node02 to node01.

Rabbitmq error of connecting the native idea to Linux: java.net.connectexception: connection timed out: Connect [Solved]

The code is as follows:

        ConnectionFactory connectionFactory = new ConnectionFactory();

        Connection connection=null;
        Channel channel = null;

        try {
            //2.create linke Connection
            connection = connectionFactory.newConnection("Creator");

Error: Java. Net. Connectexception: connection timed out: connect

Cause analysis: first, the IP port account and password are excluded

Error reason: port 5672 is not open. I always thought that everything would be fine as long as the protective wall was closed


1. Restart the firewall: systemctl start firewall

2. Open 5672 port: firewall CMD — zone = public — add port = 5672/TCP — permanent

3. Reload: firewall CMD — reload

Run debug:


Error reporting of dependency package introduced by idea

      When updating the project today, Maven relies on a service that keeps reporting errors. After checking, it was found that it was due to the lack of dependent packages. But I’m dependent on Bao Mingming

      Download again, as usual… After working for a long time, I found that my dependent package class status is unavailable. As shown in the figure below:




  Well, the solution is simple:




When Maven relies on, it preferentially relies on the local; If local is not available, it will still rely on local…  

The interface method is not rewritten, and the idea does not report an error.

Today, I was a little confused when I was writing interceptors in idea. I inherited handlerinterceptor without any errors. I always thought he would remind me to rewrite methods. As shown below

By checking the data, well, finally find the reason. First, go to the source code of the handlerinterceptor interface

public interface HandlerInterceptor {

	default boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler)
			throws Exception {
		return true;

	default void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,
			@Nullable ModelAndView modelAndView) throws Exception {
	default void afterCompletion(HttpServletRequest request, HttpServletResponse response, Object handler,
			@Nullable Exception ex) throws Exception {

Knock on the blackboard. Here’s the point

The above is the source code of the handlerinterceptor interface. You can see that in the higher version of spring webmvc jar package, the handlerinterceptor interface defines the default method, which is a new feature of JDK1.8. In other words, you can rewrite the methods in the interface without any error

So it doesn’t remind you to rewrite. You have to write it yourself

The project is normal in eclipse, and an error is reported in IDEA [How to Solve]

Eclipse has always been used, but many employees of the company use idea, so they want to try. Unexpectedly, after importing Maven project, they always report errors. Finally, they find that there is no XML file in Dao in the compiled target, resulting in errors when the listener loads resources

Finally, after repeated search, we finally found the answer

In pom.xml < build> Add to:

Delete the target folder, recompile, and the project starts.
Something magical happened, the project started. It's a real pain in the ass.

Idea uses git’s pull command to report error 1

Reference blog: https://blog.csdn.net/nan7_/ article/details/25624637

Your local changes would be overwritten by merge. Commit, stage or revert them to proceed

Cause: git conflict

1. Use the GIT repository stash changes command to save your changes

At this time, you will find that the modified parts are gone and return to the original state


Download the code on GIT

3、git-repository-Unstash changes

Take out your own code and compare and merge the code

In the comparison page, the version in Git library is on the left, the original version is in the middle, and your own version is on the right