1, a problem portal-web initiation and direct communication channel micro distal occur.
问题:Will not attempt to authenticate using SASL (unknown error)
Resolution: The port did not write the zookeeper. Plus zk port 2181 just fine.
It may be ecs and other server is not connected successfully.
2, mysql Connect too many errors
Method 1: Modify the file /etc/my.cnf
The max_connections = 5000 this value increases
Second way: using a data pool management connection
Dependent data pool springboot can be introduced directly into the project.
<!-- druid数据库连接池 -->
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid-spring-boot-starter</artifactId>
<version>1.1.10</version>
</dependency>
The above two methods may be used in combination.
3, spring-boot project started, reported data source configuration errors, can not find the driver.
Problem: spring-boot to start the project in the following problems arise. Can not find driver
wrong reason:
There are dependencies of the dependent mybatis-plus.
The need to rely on the default configuration of the data source.
solution:
Scheme One: the configuration about the data source connection configuration
spring:
datasource:
url: jdbc:mysql://47.94.22.256:3306/ego-shop
username: root
password: 123456
driver-class-name: com.mysql.cj.jdbc.Driver
mybatis-plus:
type-aliases-package: com.zxm.entity
configuration:
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
mapper-locations: classpath:/mapper/*.xml
Option II: Use annotations exclude data source class start
@SpringBootApplication(exclude = DataSourceAutoConfiguration.class)
4, the project can not rely on random write
In a remote call, just rely on search-api. We can not rely indiscriminately.
If you rely on a search-service you will get the configuration file in the dependency. In the absence of the notes in the portal-web @Value("${import.size}")
to get the value in the configuration file, so the project will start being given.