//Check that BankAccount entity exists: bankAccountKey.accountNumber = argIn.accountNumber; try { bankAccountDtls = bankAccount.read(bankAccountKey); } catch (RecordNotFoundException rnf) { //This is a SERIOUS error curam.util.exception.AppException e = new AppException( COOKBOOK.ID_NO_SUCH_ACCOUNT, rnf); e.setLoggable(true); //make sure it gets logged e.arg("not found"); // NOT LOCALIZABLE!!! throw e; }