# tec-project-pom
**Repository Path**: tec-cloud/tec-project-pom
## Basic Information
- **Project Name**: tec-project-pom
- **Description**: https://gitee.com/tec-cloud/tec-project-pom
- **Primary Language**: Unknown
- **License**: Not specified
- **Default Branch**: main
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2023-04-14
- **Last Updated**: 2023-11-08
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# javac -parameters
在Java8之前,代码编译为class文件后,方法参数的类型固定,但是方法名称会丢失,方法名称会变成arg0、arg1....。
在Java8开始可以在class文件中保留参数名,这就给反射带来了极大的遍历。
像mybatis等需要使用反射机制获取方法参数的时候就可以不用像以前一样需要使用类似于@Param之类的注解
为了避免.class文件因为保留参数名而导致.class文件过大或者占用更多的内存,
另外也避免有些参数(secrect/password)泄露安全信息,JVM即使时1.8默认是不会保留参数名称的。
# Apache Tomcat 特性支持一览 (2023.04.14)
https://tomcat.apache.org/whichversion.html
| Servlet Spec | JSP Spec | EL Spec | WebSocket Spec | Authentication (JASPIC) Spec | Apache Tomcat Version | Latest Released Version | Supported Java Versions |
| --------------------------- | -------- | ------- | -------------- | ---------------------------- | --------------------- | ----------------------- | ----------------------- |
| 6.1 | 4 | 6 | TBD | TBD | 11.0.x | 11.0.0-M4 (alpha) | 17 and later |
| 6 | 3.1 | 5 | 2.1 | 3 | 10.1.x | 10.1.7 | 11 and later |
| 5 | 3 | 4 | 2 | 2 | 10.0.x (superseded) | 10.0.27 (superseded) | 8 and later |
| 4 | 2.3 | 3 | 1.1 | 1.1 | 9.0.x | 9.0.73 | 8 and later |
| 3.1 | 2.3 | 3 | 1.1 | 1.1 | 8.5.x | 8.5.87 | 7 and later |
| 3.1 | 2.3 | 3 | 1.1 | N/A | 8.0.x (superseded) | 8.0.53 (superseded) | 7 and later |
| 3 | 2.2 | 2.2 | 1.1 | N/A | 7.0.x (archived) | 7.0.109 (archived) | 6 and later
(7 and later for WebSocket) |
| 2.5 | 2.1 | 2.1 | N/A | N/A | 6.0.x (archived) | 6.0.53 (archived) | 5 and later |
| 2.4 | 2 | N/A | N/A | N/A | 5.5.x (archived) | 5.5.36 (archived) | 1.4 and later |
| 2.3 | 1.2 | N/A | N/A | N/A | 4.1.x (archived) | 4.1.40 (archived) | 1.3 and later |
| 2.2 | 1.1 | N/A | N/A | N/A | 3.3.x (archived) | 3.3.2 (archived) | 1.1 and later |
# Public Key Retrieval is not allowed(https://zhuanlan.zhihu.com/p/371161553)
导致“Public Key Retrieval is not allowed”主要是由于当禁用SSL/TLS协议传输后,客户端会使用服务器的公钥进行传输,默认情况下客户端不会主动去找服务器拿公钥,此时就会出现上述错误。
经过查阅官方文档,出现Public Key Retrieval的场景可以概括为在禁用SSL/TLS协议传输切当前用户在服务器端没有登录缓存的情况下,客户端没有办法拿到服务器的公钥。具体的场景如下:
- 新建数据库用户,首次登录;
- 数据库的用户名、密码发生改变后登录;
- 服务器端调用FLUSH PRIVELEGES指令刷新服务器缓存。
针对上述错误,有如下的解决方案:
- 在条件允许的情况下,不要禁用SSL/TLS协议,即不要在CLI客户端使用--ssl-mode=disabled,或在JDBC连接串中加入useSSL=false;
- 如果必须禁用SSL/TLS协议,则可以尝试使用CLI客户端登录一次MySQL数据库制造登录缓存;
- 如果必须禁用SSL/TLS协议,则可以通过增加如下参数允许客户端获得服务器的公钥:
- 在JDBC连接串中加入allowPublicKeyRetrieval=true参数;
- 在CLI客户端连接时加入--get-server-public-key参数;
- 在CLI客户端连接时加入--server-public-key-path=file_name参数,指定存放在本地的公钥文件。
- com.zaxxer.hikari.HikariConfig : HikariPool-1 - idleTimeout is close to or more than maxLifetime, disabling it.
#### Redisson
Caused by: org.redisson.client.RedisException: ERR AUTH called without any password configured for the default user. Are you sure your configuration is correct?. channel: [id: 0x8e29324f, L:/127.0.0.1:54134 - R:127.0.0.1/127.0.0.1:6379] command: (AUTH), params: (password masked)
# Spring状态机
https://docs.spring.io/spring-statemachine/docs/current/reference/