Tag Archives: idea

[Solved] Tomcat runs JavaWeb servlet Error 404

Problem description

A new server template project is built with idea. After Tomcat is configured, the access report 404
is accessed

reason

Tomcat cannot load message 404 because war is not loaded

Solution:

An error occurs because the war artifact of this project is not loaded. You need to import this project as a artifact

and then select war_ Compared with war, the structure of the artifact will be consistent with the source directory for easy development

now the URL is the home page of the artifact by default

access

Spring project import @Resource Annotation Error [How to Solve]

An error is reported after the @resource annotation is introduced into the spring project

Solution:

@Resource annotations are provided by J2EE

However, jdk1.9 and above versions need to import a javax.annotation dependency package from pom.xml in maven:

<dependencies>
    <dependency>
        <groupId>javax.annotation</groupId>
        <artifactId>javax.annotation-api</artifactId>
        <version>1.3.2</version>
    </dependency>
</dependencies>

Solution to communication link failure with error in idea startup project

Problem description

com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure

Solution

Option 1   Tomcat VM configuration parameters: – DJava. Net. Preferipv4stack = true

Option 2   ① Nginx configuring agent MySQL:

    ② Modify database connection: spring. Datasource. Url = JDBC: mysql://localhost:9999/demo?characterEncoding=utf8

Reference from:

https://blog.csdn.net/baidu_21349635/article/details/121032229
https://adong.blog.csdn.net/article/details/111501253

[Solved] BeanCreationException: Error creating bean with name ‘configurationPropertiesBeans‘

Created a SpringBoot project, used SpringCloud, and then started the project and reported an error:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘configurationPropertiesBeans’ defined in class path resource [org/springframework/cloud/autoconfigure/ConfigurationPropertiesRebinderAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.cloud.context.properties.ConfigurationPropertiesBeans]: Factory method ‘configurationPropertiesBeans’ threw exception; nested exception is java.lang.NoClassDefFoundError: org/springframework/boot/context/properties/ConfigurationBeanFactoryMetadata


It is found that the version of SpringBoot is inconsistent with the version of SpringCloud
Corresponding to the modified version


   <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>2.1.6.RELEASE</version>
        <relativePath/>
    </parent>
             <dependency>
                <groupId>org.springframework.cloud</groupId>
                <artifactId>spring-cloud-dependencies</artifactId>
                <version></version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>

Prompt IPA processing failed when exporting IOS adhoc

Prompt IPA processing failed when IOS adhoc

View the log of standard to view errors

View standard’s log

The log contains a large string of simulator information, so directly search the x86 keyword, and then check which framework is included, and then CD go in. Remember to enter the framework and remove i386 and x86_ 64

lipo -info xxxx

Remove command:

lipo -remove i386 xxxx -o xxxx
lipo -remove x86_64 xxxx -o xxxx

View errors

Before, I was misled by the Internet. I had to search all the "x86" keywords, and then search out Ruby (universal. X86_64) , thinking about viewing or updating with lipo , which wasted a lot of time and failed… Finally, homebrew
is also updated

Finally, I tried to search error , and found that framework was included in bundle of tent , and finally it was OK to remove it
IPA processing failed will be prompted when IOS ad hoc , the framework in tencetopen is attached with x86 , after removal, you can check the keywords of failed or error in your log.

Mon 08

03:00

06:00

09:00

12:00

03:00

06:00

09:00

Tue 09

Remove all SDK schemas

Update relevant environment

IOS tasks

IOS diagram functionality to mermaid

Follow up interest can be focused on the following column or official account number [Python2048].

"Android - the world of hackers"
"difficult and miscellaneous bugs - no language"


Author: Altman Superman dujinyang

Source: CSDN

Original text: https://dujinyang.blog.csdn.net/

Copyright notice: This is the original article of blogger Du Jinyang. Please attach the blog link for reprint!

The project tag in the parent project POM file of Maven multi module project reports an error, and the error information is: \n

Error message

Reason: under the dependency management tab in the parent project POM file  <dependencies></dependencies> There are multiple. One is version control dependency, and the other is introduced dependency

Solution:

Add POM file

The dependencies are placed in the dependencies tab. The dependency of version control is placed under the dependency management tab In dependencies.

Note: it’s just to record some mistakes that are easy to ignore or imperceptible.

Idea error: (4, 28) Java: package com.alibaba.fastjson does not exist

The package has been imported through Maven in DEA, and the location of the package can also be located in idea, but error is always reported when compiling, and the package cannot be found.

Presumably, the reason is that the version of idea is incompatible with the build built by Maven

It is recommended to uninstall the idea and install it with another version of the idea. If you do not want to replace the idea, you can take the following measures.

The solution is as follows:

Hosting the build and run of idea under maven

When checked, recompilation can run normally

Plugin Error: Plugin “Android Code Generator“ is incompatible (supported only in IntelliJ IDEA)

1. Question

Plugin Error: Plugin “Android Code Generator” is incompatible (supported only in IntelliJ IDEA).

2. Solution

C:/Users/Admin/AppData/Roaming/Google/AndroidStudio4.2/plugins

After deleting the file, restart the as to solve the problem.

3. Detailed steps

1. Enter the directory of Disk C and click the [user] folder

2. Find the directory of your [administrator] user name, that is, admin above

3. If you enter at this time, you may not find the appdata folder, so you need to open the hidden directory to see it (take win10 as an example here)

4. Follow the above file path to find the directory where the file is located

5. Delete the error folder. This is Android codegenerator plugin IntelliJ

6. Restart Android studio

[Solved] org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class


  .   ____          _            __ _ _
 /\\/___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, |////
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v2.1.6.RELEASE)

2021-10-20 18:20:57.801  INFO 13176 --- [           main] cn.com.topsec.hgdsmp.web.WebApplication  : Starting WebApplication on DESKTOP-CXH with PID 13176 (F:\TopSecWork\06.dsmp\web\target\classes started by lenovo in F:\TopSecWork\06.dsmp\web)
2021-10-20 18:20:57.803  INFO 13176 --- [           main] cn.com.topsec.hgdsmp.web.WebApplication  : No active profile set, falling back to default profiles: default
2021-10-20 18:20:58.465  WARN 13176 --- [           main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [cn.com.topsec.hgdsmp.web.WebApplication]; nested exception is java.io.FileNotFoundException: class path resource [org/jeecgframework/minidao/aspect/EmptyInterceptor.class] cannot be opened because it does not exist
2021-10-20 18:20:58.469  INFO 13176 --- [           main] ConditionEvaluationReportLoggingListener : 

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2021-10-20 18:20:58.481 ERROR 13176 --- [           main] o.s.boot.SpringApplication               : Application run failed

org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [cn.com.topsec.hgdsmp.web.WebApplication]; nested exception is java.io.FileNotFoundException: class path resource [org/jeecgframework/minidao/aspect/EmptyInterceptor.class] cannot be opened because it does not exist
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:181) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:315) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:232) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:275) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:95) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:705) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:531) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:140) ~[spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:742) [spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:389) [spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:311) [spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1213) [spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1202) [spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at cn.com.topsec.hgdsmp.web.WebApplication.main(WebApplication.java:30) [classes/:na]
Caused by: java.io.FileNotFoundException: class path resource [org/jeecgframework/minidao/aspect/EmptyInterceptor.class] cannot be opened because it does not exist
	at org.springframework.core.io.ClassPathResource.getInputStream(ClassPathResource.java:180) ~[spring-core-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.core.type.classreading.SimpleMetadataReader.<init>(SimpleMetadataReader.java:51) ~[spring-core-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.core.type.classreading.SimpleMetadataReaderFactory.getMetadataReader(SimpleMetadataReaderFactory.java:103) ~[spring-core-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.boot.type.classreading.ConcurrentReferenceCachingMetadataReaderFactory.createMetadataReader(ConcurrentReferenceCachingMetadataReaderFactory.java:86) ~[spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.boot.type.classreading.ConcurrentReferenceCachingMetadataReaderFactory.getMetadataReader(ConcurrentReferenceCachingMetadataReaderFactory.java:73) ~[spring-boot-2.1.6.RELEASE.jar:2.1.6.RELEASE]
	at org.springframework.core.type.classreading.SimpleMetadataReaderFactory.getMetadataReader(SimpleMetadataReaderFactory.java:81) ~[spring-core-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.asSourceClass(ConfigurationClassParser.java:682) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser$SourceClass.getInterfaces(ConfigurationClassParser.java:1008) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.processInterfaces(ConfigurationClassParser.java:375) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:323) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:242) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:191) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:295) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:242) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:199) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:167) ~[spring-context-5.1.8.RELEASE.jar:5.1.8.RELEASE]
	... 13 common frames omitted

org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [cn.com.topsec.hgdsmp.web.WebApplication]; nested exception is java.io.FileNotFoundException: class path resource [org/jeecgframework/minidao/aspect/EmptyInterceptor.class] cannot be opened because it does not exist
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:181)
	at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:315)
	at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:232)
	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:275)
	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:95)
	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:705)
	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:531)
	at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:140)
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:742)
	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:389)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:311)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1213)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1202)
	at cn.com.topsec.hgdsmp.web.WebApplication.main(WebApplication.java:30)
Caused by: java.io.FileNotFoundException: class path resource [org/jeecgframework/minidao/aspect/EmptyInterceptor.class] cannot be opened because it does not exist
	at org.springframework.core.io.ClassPathResource.getInputStream(ClassPathResource.java:180)
	at org.springframework.core.type.classreading.SimpleMetadataReader.<init>(SimpleMetadataReader.java:51)
	at org.springframework.core.type.classreading.SimpleMetadataReaderFactory.getMetadataReader(SimpleMetadataReaderFactory.java:103)
	at org.springframework.boot.type.classreading.ConcurrentReferenceCachingMetadataReaderFactory.createMetadataReader(ConcurrentReferenceCachingMetadataReaderFactory.java:86)
	at org.springframework.boot.type.classreading.ConcurrentReferenceCachingMetadataReaderFactory.getMetadataReader(ConcurrentReferenceCachingMetadataReaderFactory.java:73)
	at org.springframework.core.type.classreading.SimpleMetadataReaderFactory.getMetadataReader(SimpleMetadataReaderFactory.java:81)
	at org.springframework.context.annotation.ConfigurationClassParser.asSourceClass(ConfigurationClassParser.java:682)
	at org.springframework.context.annotation.ConfigurationClassParser$SourceClass.getInterfaces(ConfigurationClassParser.java:1008)
	at org.springframework.context.annotation.ConfigurationClassParser.processInterfaces(ConfigurationClassParser.java:375)
	at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:323)
	at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:242)
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:191)
	at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:295)
	at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:242)
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:199)
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:167)
	... 13 more

Process finished with exit code 0

Solution: remove <–< scope> system Method, using Maven warehouse

!-- JimuReport import start -->
        <dependency>
            <groupId>org.jeecgframework.jimureport</groupId>
            <artifactId>jimureport-spring-boot-starter</artifactId>
            <version>1.4.0-beta</version>
            <!--<scope>system</scope>
            <systemPath>${project.basedir}/lib/jimureport-spring-boot-starter-1.4.0-beta.jar</systemPath>-->
        </dependency>

IntelliJ idea error: Java: compilation failed: solution to internal java compiler error

Method 1: it may be due to heap memory problems

In setting — & gt; Build,Execution,Deployment–> Build process heap size (Mbytes) found in compiler: 700 changed to 1024 (as appropriate)

Method 2: it may be due to project coding

PS: I can compile it by changing it to GBK. The system default GBK format is invalid and needs to be manually changed to GBK

Idea startup error: Port occupied/address already exists

Error message:

org.apache.catalina.LifecycleException: Failed to start component

resolvent:

Open the CMD command window and enter the netstat – ano command to view all ports and PIDs (the number in the last column).

Find the occupied port at the local address and write down the PID value.

Enter the instruction tasklist | findstr “PID value” to find the corresponding process.

Kill the process and restart.   Example: taskkill/F/T/im java.exe & lt– Java.exe is the process found in the previous step — & gt;