On Tue, Mar 11, 2008 at 3:37 AM, Julian Wood <[EMAIL PROTECTED]> wrote:
> Hate to answer my own question, but I think the proper relation for:
>
> is:
>
> @ManyToMany( cascade={CascadeType.PERSIST, CascadeType.MERGE} )
>
> You then need to persist your GrantedAuthorityBean independently from
>
On Tue, Mar 11, 2008 at 12:18 AM, Julian Wood <[EMAIL PROTECTED]> wrote:
> In the provided example for tapestry-acegi, I have a question about
> the GrantedAuthorityBean table. That is, if I add more users which
> share roles, each role will create a new row in the GAB table. How can
> this be a
Hate to answer my own question, but I think the proper relation for:
@OneToMany
@Cascade(CascadeType.ALL)
public Collection getGrantedAuthorities() {
return grantedAuthorities;
}
is:
@ManyToMany( cascade={CascadeType.PERSIST, CascadeType.MERGE} )
You then need to persist your GrantedA
In the provided example for tapestry-acegi, I have a question about
the GrantedAuthorityBean table. That is, if I add more users which
share roles, each role will create a new row in the GAB table. How can
this be avoided?
I've tried making the authority unique:
@Table(uniqueConstraints =