KrailOrg / krail

Rapid web app framework using Vaadin 8 integrated with Guice and Shiro
50 stars 19 forks source link

Building UserSitemap makes frequent calls to Realm #750

Open davidsowerby opened 5 years ago

davidsowerby commented 5 years ago

The UserSitemapBuilder needs to check that the current user has permission to access a page before adding it to the UserSitemap.

This is done via the UserSitemapNodeModifier and PageController.

However, each authorisation check calls the realm for the user's permissions. This is unnecessary, and could slow things down significantly when permissions need to be retrieved from an external source.

It could also cause confusion if the permissions change while the UserSitemap is being built