Missing customization for accessAnnotationChecker
and viewAccessChecker
#914
Labels
accessAnnotationChecker
and viewAccessChecker
#914
Issue
the beans
viewAccessChecker
andaccessAnnotationChecker
are the core security handlers when using vaadin 21+There are number of reasons why one would like to provide a custom AnnotationCheker or ViewAccessChecker. You could implement custom or new authorisation schema!
(No) Abstraction
While there is a way to forcefully overwrite the beans provided by vaadin using
@Primary
there are still t issues@Primary
and if they do they cant name their beanviewAccessChecker
Quickfix
For users that need to solve this specific problem at the moment there is a (little hacky) workaround:
Lets assmue you want 2 custom annotations
@Public
and@Private
(keep it simple for sake of exampleSo you annotate your View With
Then you need to impement a custom Annotation Checker
Then you need to overwrite the annotation checker bean
You are done :) ... no not rly because for some reason
ViewAccessChecker
does not uses the bean but instanciates the object itself so you need to overwrite this bean too.Proposed Changes
AnnotationAccessChecker
ViewAccessChecker
@ConditionalOnMissingBean
to all beans provided by vaadin and therefore encouraging overwriting without introducing incompatibilitiesThe text was updated successfully, but these errors were encountered: