Hi,
Did you solve that problem, I have exactly the same. @GeneratedValue is ignored in User class. Consequently all created user have 0 as userId. I have a NonUniqueObjectException when the second user is created.
http://jira.jboss.org/jira/browse/EJBTHREE-508
You'll have to do without a composite key :)