You're being redirected to the debug page because of a persistence exception.
What you should do is handle this in the persist method.
Override the persist method and in it check if there's already an object with this
unique persistence and throw an error message in there.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4026591#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...