Error Messages:
org.jetbrains.jps.builders.java.dependencyView.TypeRepr$PrimitiveType cannot be cast to org.jetbrains.jps.builders.java.dependencyView.TypeRepr$ClassType
Solution:
Error Messages:
org.jetbrains.jps.builders.java.dependencyView.TypeRepr$PrimitiveType cannot be cast to org.jetbrains.jps.builders.java.dependencyView.TypeRepr$ClassType
Solution:
Problem background:
Idea with git will remind you of the following error
arbitrary: use of Rex. W is meaningless (default operand size is 64)
because there is security software, you need to add a key in the registry
Computer \ HKEY_ LOCAL_ Create a new [string value] HookApi under machine \ software \ Tec \ ocular. 3 \ agent \ config_ Dis INS, numerical data: 1
but it’s too troublesome to manually add and restart idea every time. Now it’s changed to automatically add registry configuration after startup
1. Find a directory and create two files, one regidea.bat and one regidea.log
As shown in Figure
2. Modify the bat file and enter the following instructions
(reg query HKEY_LOCAL_MACHINE\SOFTWARE\TEC\Ocular.3\agent\config /v hookapi_disins && (echo %date:~0,4%-%date:~5,2%-%date:~8,2% %time:~0,2%:%time:~3,2%:%time:~6,2% reg exist... >>%~dp0\regIdea.log )) || ((reg add HKEY_LOCAL_MACHINE\SOFTWARE\TEC\Ocular.3\agent\config /t REG_SZ /v hookapi_disins /d 1)&&(echo %date:~0,4%-%date:~5,2%-%date:~8,2% %time:~0,2%:%time:~3,2%:%time:~6,2% reg set suc... >>%~dp0\regIdea.log ))
The main idea is to query whether there is a hook API in the registry_ Dis INS, set and print a line of text set suc… In regidea.log
If yes, print reg exist…
log file just to see if the instruction takes effect
3. Create a shortcut to the bat file and drag it into the following directory
C: \ users \ XXX \ appdata \ roaming \ Microsoft \ windows \ start menu \ programs \ startup
where XXX is the user name
if the directory cannot be found, check the view hidden item of the folder
Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.1.8.RELEASE:repackage (repackage) on project online-common: Execution repackage of goal org.springframework.boot:spring-boot-maven-plugin:2.1.8.RELEASE:repackage failed: Unable to find a single main class from the following candidates [com.example.onlinecommon.valatiledemo.Main, com.example.onlinecommon.valatiledemo.MainDemo, com.example.onlinecommon.valatiledemo.MyRunnable]
According to the above tips, I deleted the main method in classes main, maindemo and myrunnable
2. Continue packing
Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.1.8.RELEASE:repackage (repackage) on project online-common: Execution repackage of goal org.springframework.boot:spring-boot-maven-plugin:2.1.8.RELEASE:repackage failed: Unable to find main class
The above tip: my common module lacks the main class, because this is my tool module, so there is no need to start the class. I changed the package file to
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
Skip the packaging of this module
1 problem description
When a new branch code (GIT fetch + git checkout – b) is pulled to operate a new local branch, there is a problem (GIT rebase, GIT stash, GIT checkout old branches will not prompt this error, and the same error will be reported on rollback on idea)
2 problem solving
Stop the application (the project is running, and the jar package is referenced, which makes git unable to access). Rollback the jar package in the idea, select the jar package, and click the button
3 problem analysis
The project is running, the jar package is referenced, and git cannot be updated
reason
The settings.xml in the conf directory under the Maven installation directory is incorrectly configured
I forgot to complete <mirrors></mirrors>
Solution:
Check settings.xml for syntax errors
Troubleshooting: error: Java: outofmemoryerror: insufficient memory
1.idea
2. Desktop – my computer – the arrow in the upper left corner to the desktop – find the user folder – find xxx.vmoptions – config – change the size 3, restart the idea
Note:
you can’t find it on the Internet successfully. Record it.
Today, when the company server rabbitmq related configuration is changed to local related configuration in the code, an error is reported: failed to check/redeclare auto delete queue (s)
Error reporting reason:
15672 is the port of the web management interface; 5672 is the port accessed by MQ, so changing the port in the configuration file to 5672 is OK;
This article is an original article of Joshua 317. Please note that it is reproduced from Joshua 317 blog Solve the problem of error running xxxapplication command line is too long – Joshua 317 when compiling IntelliJ idea
Idea reports an error when compiling the project, and the saved information is as follows:
15:42 Error running 'xxxxApplication': Command line is too long. Shorten command line for xxxxApplication or also for Spring Boot default configuration.
Solution 1
Found in the project folder. Idea/workspace.xml
<component name="PropertiesComponent">
...
</component>
Then add a row of attributes to solve the problem:
<property name="dynamic.classpath" value="true" />
Solution 2
Open the running configuration of the program and change short command line
to jar manifest
or classpath file
, as shown in the figure:
This article is an original article of Joshua 317. Please note that it is reproduced from Joshua 317 blog Solve the problem of error running xxxapplication command line is too long – Joshua 317 when compiling IntelliJ idea
Problem display
resolvent
1. Find the Tomcat installation directory
2. Open the logging.properties file from the conf folder
find the line java.util.logging.consolehandler.encoding = UTF-8 and change it to java.util.logging.consolehandler.encoding = GBK
that is, change the console code from UTF-8 to GBK
Successful solution, give a praise
Upgrade to IntelliJ idea 2021.2 and start the project with an error
Problem description solution
Problem description
Upgrade to IntelliJ idea 2021.2 and start the project with an error.
Unrecognized option: --add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED
Solution
File – project structure,
modify as shown in the figure
Jedis calls the tool class and reports java.lang.exceptionininitializererror exception. The reason is that the resource configuration file is not read. Change the resource configuration file to an absolute path to solve it (the default read file path of idea is SRC path)
The problem is solved