springboot
冷冷清清中的风风火火
这个作者很懒,什么都没留下…
展开
-
启动报错:Field userService in com.zyr.springboot.sys.XXXController required a single bean, but 2 were f
报错信息:***************************APPLICATION FAILED TO START***************************Description:Field userService in com.zyr.springbootdemo.sys.LoginController required a single bean, but 2 were found: - sysUserServiceImpl: defined in file [F:\wo原创 2022-05-30 14:50:50 · 2158 阅读 · 2 评论 -
spring cloud gateway配置 uri的三种方式
在gateway中配置uri配置有三种方式,包括ws(websocket)方式: uri: ws://localhost:9000http方式: uri: http://localhost:8130/lb(注册中心中服务名字)方式: uri: lb://brilliance-consumer注:http和ws大家都比较熟悉,直接写地址,但lb方式需要注意,单独的服务,服务命名可以随意,但是当使用gateway使用时,就需要注意命名规范。能被gateway的lb方式识别到的命名规则为:原创 2021-12-20 17:49:30 · 6024 阅读 · 0 评论 -
spingboot跳转页面
1、Springboot有自己默认的模板引擎,引用相应的依赖包。<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-thymeleaf</artifactId></dependency>这里注意:静态页面的return默认是跳转到/static/index.html,当在pom.xml中原创 2021-08-27 16:28:16 · 74 阅读 · 0 评论