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

JdbcAdapter will not load the policy from database in initial phase #53

Closed doctormacky closed 2 years ago

doctormacky commented 2 years ago

When we try to run the springboot, it will not load existing policy from database. that means the poliicy in memoy of the appliication are empty, this should not work as expected.

from my understanding, the adapter should load all the policy from database during the initial phase of application. Suggest we set following attribute in JdbcAdapter from true to false as default. private volatile boolean isFiltered = false ;

Any idea ?

casbin-bot commented 2 years ago

@tangyang9464 @seriouszyx @elfisworking @fangzhengjin

hsluoyz commented 2 years ago

@seriouszyx can you take a look?

seriouszyx commented 2 years ago

@doctormacky The isFilter value has been set as false in https://github.com/jcasbin/casbin-spring-boot-starter/pull/58.

hsluoyz commented 2 years ago

Resolved.