jcasbin / casbin-spring-boot-starter

Spring Boot 2.x & 3.x Starter for Casbin, see example at: https://github.com/jcasbin/casbin-spring-boot-example
https://mvnrepository.com/artifact/org.casbin/casbin-spring-boot-starter
Apache License 2.0
196 stars 70 forks source link

关于springboot集成casbin #9

Closed shangchaoshi closed 5 years ago

shangchaoshi commented 5 years ago

原项目采用springboot4构成,配置文件如下。集成casbin的时候会报错 I@GM C7U6 YTNHAGY(TMUIS

项目配置文件如下 L73QR(A}3NEK %YTICEA0H X132TM4O2L)M 955D4I2R{H @fangzhengjin

fangzhengjin commented 5 years ago

spring4的直接使用虽然没有测试过,但是跟boot差别应该不大,看错错误提示应该是没加载到casbin 依赖,可以尝试手动添加下试试! https://github.com/casbin/jcasbin

hsluoyz commented 5 years ago

Please use English everywhere to make Casbin an international project.

fangzhengjin commented 5 years ago

Or your current version does not support spring @Nullable annotations, you can try to update the spring version.

shangchaoshi commented 5 years ago

Or your current version does not support spring @nullable annotations, you can try to update the spring version.

spring4 do not supported @nullable annotations,it needs update to spring5, but my project is too complex, is there any other way to solve it?

fangzhengjin commented 5 years ago

Do you need a watcher for your project?

fangzhengjin commented 5 years ago

If you need to use watcher, please set casbin.enableWatcher=true to try

shangchaoshi commented 5 years ago

If you need to use watcher, please set casbin.enableWatcher=true to try

i don't need it, no matter how i set it up,still reporting that error

fangzhengjin commented 5 years ago

Which spring version are you using? I tried to modify it.

shangchaoshi commented 5 years ago

Which spring version are you using? I tried to modify it.

org.springframework.boot spring-boot-starter-parent 1.5.9.RELEASE

springboot 1.5.9, it dependencys on spring4

fangzhengjin commented 5 years ago

Version 0.0.8 has been released. If you use maven.aliyun.com , you can get it immediately. If you use the central repository, you need to wait for two hours.