I found my mistake, I wasn't using the right instance.

the following fixed the problem 1.

@Override
public String persist() {
 if (Strings.isNull(getInstance().getId()) && !this.isManaged()) {
 KeyGenerator keyGen = (KeyGenerator) Component.getInstance 
(KeyGenerator.class, true);
 getInstance().setId(keyGen.getKey(Constant.Database.KeySuffix.ADMIN));
 } 
 return super.persist();
}


Any clue to my question 2 will be appreciated.


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093605#4093605

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093605
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to