[
https://jira.jboss.org/jira/browse/JBSEAM-3511?page=com.atlassian.jira.pl...
]
Pete Muir updated JBSEAM-3511:
------------------------------
Fix Version/s: 2.1.0.GA
Assignee: Shane Bryzak
Priority: Critical (was: Major)
Also, please refactor AnnotatedBeanProperty to be object orientated, and use Reflections
to establish setter and getter method names.
User Entity Annotations not working on private fields.
------------------------------------------------------
Key: JBSEAM-3511
URL:
https://jira.jboss.org/jira/browse/JBSEAM-3511
Project: Seam
Issue Type: Bug
Components: Security
Affects Versions: 2.1.0.CR1
Reporter: Ron Thijssen
Assignee: Shane Bryzak
Priority: Critical
Fix For: 2.1.0.GA
Original Estimate: 10 minutes
Remaining Estimate: 10 minutes
Caused by: org.jboss.seam.security.management.IdentityManagementException: Invalid
userClass nl.xxx.xxx.User - required annotation @UserRoles not found on any Field or
Method.
at
org.jboss.seam.security.management.JpaIdentityStore.initProperties(JpaIdentityStore.java:138)
at
org.jboss.seam.security.management.JpaIdentityStore.init(JpaIdentityStore.java:111)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
When the JpaIdentityStore is initialized, the classes are checked on certain required
annotations.
The AnnotatedBeanProperty's method scanForProperty is used to check these required
annotations.
The annotations targets are METHOD and FIELD, and should be used in that way. (do not
care about private or public identifiers)
getFields() is used to retrieve the class fields. This method only returns the public
fields.
getDeclaredFields() however returns public protected and private fields.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira