1、在pom文件引入hutool
<dependency>
<groupId>cn.hutool</groupId>
<artifactId>hutool-all</artifactId>
<version>5.5.1</version>
</dependency>
2、在springboot启动类中添加注解@EnableSpringUtil
3、在netty websocket代码中获取bean
1、在pom文件引入hutool
<dependency>
<groupId>cn.hutool</groupId>
<artifactId>hutool-all</artifactId>
<version>5.5.1</version>
</dependency>
2、在springboot启动类中添加注解@EnableSpringUtil
3、在netty websocket代码中获取bean