3 Replies Latest reply on Apr 29, 2010 5:26 AM by josdaniel

    add-identity-management - user mgmt screen access fail

    smohan.mohan.sarangan.gmail.com

      As per the following suggestion http://blog.hibernate.org/10904.lace tried seam gen add-identity-management. After successfully generating application, I was able to login to the applicaiton with using admin/blank.


      But when I was trying to access Manage users or Manage roles link, it fails with error something bad happened. Kindly advice where I went wrong.


      Thanks in advance for your help.

        • 1. Re: add-identity-management - user mgmt screen access fail
          tausuahmed

          Hi,


          Check in useraccountrole table an entry is there for admin user. If not add entry


          insert into user_account_role (account_id, member_of_role) values (1, 1);






          Regards,
          Tauseef

          • 2. Re: add-identity-management - user mgmt screen access fail
            smohan.mohan.sarangan.gmail.com

            Tausseef,


            Thanks for the tip. Yes the data are not populate for some reason. But now I am getting the following error.


            Caused by: org.jboss.seam.InstantiationException: Could not instantiate Seam component: org.jboss.seam.security.jpaPermissionStore
                    at org.jboss.seam.Component.newInstance(Component.java:2144)
                    at org.jboss.seam.Component.getInstance(Component.java:2021)
                    at org.jboss.seam.Component.getInstance(Component.java:1983)
                    at org.jboss.seam.Component.getInstance(Component.java:1977)
                    at org.jboss.seam.Component.getInstance(Component.java:1957)
                    at org.jboss.seam.security.permission.PersistentPermissionResolver.initPermissionStore(PersistentPermissionResolver.java:52)
                    at org.jboss.seam.security.permission.PersistentPermissionResolver.create(PersistentPermissionResolver.java:45)
                    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                    at java.lang.reflect.Method.invoke(Method.java:597)
                    at org.jboss.seam.util.Reflections.invoke(Reflections.java:22)
                    at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:144)
                    at org.jboss.seam.Component.callComponentMethod(Component.java:2249)
                    at org.jboss.seam.Component.callCreateMethod(Component.java:2172)
                    at org.jboss.seam.Component.newInstance(Component.java:2132)
                    ... 74 more
            Caused by: java.lang.RuntimeException: Invalid userPermissionClass com.id.seamproject.eb.UserPermission - required annotation @PermissionUser not found on any Field or Method.
                    at org.jboss.seam.security.permission.JpaPermissionStore.initProperties(JpaPermissionStore.java:129)
                    at org.jboss.seam.security.permission.JpaPermissionStore.init(JpaPermissionStore.java:95)
                    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                    at java.lang.reflect.Method.invoke(Method.java:597)
                    at org.jboss.seam.util.Reflections.invoke(Reflections.java:22)
                    at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:144)
                    at org.jboss.seam.Component.callComponentMethod(Component.java:2249)
                    at org.jboss.seam.Component.callCreateMethod(Component.java:2172)
                    at org.jboss.seam.Component.newInstance(Component.java:2132)


            Kindly advice.


            Cheers,
            Mohan

            • 3. Re: add-identity-management - user mgmt screen access fail
              josdaniel

              I guess your permission class is not configured properly. Most of this information is available in the seam reference manual.