PortletDemo role mapping problem

Hi

I had deployed some portlets without any reference to roles and everithing was fine. Now I’m testing the PortletDemo bundled in Vaadin 6.2.0.

Roles referenced are in portlet.xml:


		<security-role-ref>
			<role-name>administrator</role-name>
		</security-role-ref>
		<security-role-ref>
			<role-name>guest</role-name>
		</security-role-ref>
		<security-role-ref>
			<role-name>power-user</role-name>
		</security-role-ref>
		<security-role-ref>
			<role-name>user</role-name>
		</security-role-ref>

and liferay-portlet.xml:


		<role-mapper>
			<role-name>administrator</role-name>
			<role-link>Administrator</role-link>
		</role-mapper>
		<role-mapper>
			<role-name>guest</role-name>
			<role-link>Guest</role-link>
		</role-mapper>
		<role-mapper>
			<role-name>power-user</role-name>
			<role-link>Power User</role-link>
		</role-mapper>
		<role-mapper>
			<role-name>user</role-name>
			<role-link>User</role-link>
		</role-mapper>

Once the PortletListener is added


		PortletApplicationContext ctx = (PortletApplicationContext) getContext();
			ctx.addPortletListener(this, new DemoPortletListener());

I get in the Liferay tomcat log this error trace
com.liferay.portal.NoSuchRoleException: No Role exists with the key {companyId=1, name=administrator}
at com.liferay.portal.service.persistence.RolePersistenceImpl.findByC_N(RolePersistenceImpl.java:701)
at com.liferay.portal.service.impl.RoleLocalServiceImpl.hasUserRole(RoleLocalServiceImpl.java:318)
at sun.reflect.GeneratedMethodAccessor190.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)

Does anybody know why this error and what dos it mean?

Thanks

I found the error is caused by this call

request.isUserInRole("administrator")

Regards