Can somebody tell me what kind of exception can cause tranction?
I defined a exception of my own which extends Exception.But when it was thrown out,the tranction didn't happen,when I replaced it with RemoteException then it happened,can somebody tell me why?
Are you trying to get the transaction to rollback when an exception is thrown? If so your Exception has to extend java.lang.RuntimeException. Encountering an unexpected RemoteException will also cause a transaction to rollback, but throwing a RemoteException to rollback a transaction is not a good practice.