forked from pledbrook/grails-shiro
-
Notifications
You must be signed in to change notification settings - Fork 2
Grails3MigrationNotes
yellowsnow edited this page Oct 27, 2015
·
9 revisions
During the migration process tracked by #44, several points were addressed in the Grails Shiro plugin. The present page attempts to list them.
- The projects file structure was changed using the excellent migrate2-grails3 plugin :
- For the main project (the plugin)
- And it's test suite :
- shiro2/test/projects/annotation-test -> shiro3/annotation-test
- shiro2/test/projects/cli-tests -> shiro3/cli-tests
- shiro2/test/projects/default -> shiro3/default
- shiro2/test/projects/native-realm-only -> shiro3/native-realm-only
- shiro2/test/projects/native-session -> shiro3/native-session
- shiro2/test/projects/spring-filter -> shiro3/spring-filter
- shiro2/test/projects/wildcard-realm -> shiro3/wildcard-realm
- Multi project build was enabled in shiro3/settings.gradle
- Web xml configuration is not used anymore which drops support for Ini configuration in favor of a pure bean DSL
- Security Filters are not used anymore in favor of interceptors, using this command
create-security-interceptor
should enable a default interceptor. - Each sample project received a
compile project(":grails-shiro")
dependency - Shiro library bumped to 1.2.4
- Travis build .travis.yml :
- Jdk7 and Jdk8 variants
- Firefox setup using Xvfb
- Less verbose builds while providing useful Gradle output (-i option + grep)
- Runs gradle tests on the plugin and the sample projects (integrationTest)
- Native session configuration uses
MYSESSIONID
as a cookie name by default, you can revert to JSESSIONID by configuringbeans.shiroSessionIdCookie.name="JSESSIONID"
. For an unknown reason, usingJSESSIONID
breaks these tests : - Legacy configuration doesn't work, please check these samples for workarounds :
- The
default
sample project is disabled since it uses the legacy configuration
Many things could be done in the future, this is a proposal :
- Use traits for
accessControl
instead of dynamic methods - Use
@CompileStatic
in interceptors (as a consequence of using traits) - Setup automatic publishing to bintray via Travis CI