OPENJPA-891 - Remove _recoverable attribute in StoreException and use _fatal instead, per Pinaki's suggestion.

git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@751109 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Albert Lee 2009-03-06 22:22:15 +00:00
parent cae33419ae
commit 70cfcaaee1
3 changed files with 2 additions and 12 deletions

View File

@ -4280,7 +4280,7 @@ public class DBDictionary
storeEx = new StoreException(msg);
}
if (recoverable != null) {
storeEx.setRecoverable(recoverable);
storeEx.setFatal(!recoverable);
}
return storeEx;
}

View File

@ -35,8 +35,6 @@ public class StoreException
public static final int REFERENTIAL_INTEGRITY = 4;
public static final int OBJECT_EXISTS = 5;
private boolean recoverable = false;
public StoreException(String msg) {
super(msg);
}
@ -60,12 +58,4 @@ public class StoreException
public int getType() {
return STORE;
}
public void setRecoverable(boolean recoverable) {
this.recoverable = recoverable;
}
public boolean isRecoverable() {
return recoverable;
}
}

View File

@ -165,7 +165,7 @@ public class PersistenceExceptions
(ke instanceof LockException ? ke : cause);
if (lockEx != null && lockEx.getLockLevel() >=
JPA2LockLevels.LOCK_PESSIMISTIC_READ) {
if (lockEx.isRecoverable()) {
if (!lockEx.isFatal()) {
e = new org.apache.openjpa.persistence
.LockTimeoutException(
ke.getMessage(), getNestedThrowables(ke),