openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ss...@apache.org
Subject svn commit: r690402 - /openjpa/branches/0.9.7-r547073/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java
Date Fri, 29 Aug 2008 22:03:31 GMT
Author: ssegu
Date: Fri Aug 29 15:03:30 2008
New Revision: 690402

URL: http://svn.apache.org/viewvc?rev=690402&view=rev
Log:
OPENJPA-365: Raise informative exception when user supplied id argument is wrong type.

Modified:
    openjpa/branches/0.9.7-r547073/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java

Modified: openjpa/branches/0.9.7-r547073/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java
URL: http://svn.apache.org/viewvc/openjpa/branches/0.9.7-r547073/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java?rev=690402&r1=690401&r2=690402&view=diff
==============================================================================
--- openjpa/branches/0.9.7-r547073/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java
(original)
+++ openjpa/branches/0.9.7-r547073/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java
Fri Aug 29 15:03:30 2008
@@ -1114,6 +1114,9 @@
             default:
                 throw new UserException(_loc.get("meta-unknownid", cls));
             }
+        } catch (IllegalArgumentException iae) {
+            throw new  UserException(_loc.get("bad-id-value", val,
+                val.getClass().getName(), cls)).setCause(iae);
         } catch (OpenJPAException ke) {
             throw ke;
         } catch (ClassCastException cce) {



Mime
View raw message