Polishing

(cherry picked from commit f095aa2)
This commit is contained in:
Juergen Hoeller
2017-01-23 21:28:40 +01:00
parent bddcc669b3
commit fcfacd9f83
17 changed files with 259 additions and 262 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2016 the original author or authors.
* Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -186,9 +186,9 @@ public class ConcurrentMapCache extends AbstractValueAdaptingCache {
try {
return serializeValue(storeValue);
}
catch (Exception ex) {
throw new IllegalArgumentException("Failed to serialize cache value '"
+ userValue + "'. Does it implement Serializable?", ex);
catch (Throwable ex) {
throw new IllegalArgumentException("Failed to serialize cache value '" + userValue +
"'. Does it implement Serializable?", ex);
}
}
else {
@@ -213,9 +213,8 @@ public class ConcurrentMapCache extends AbstractValueAdaptingCache {
try {
return super.fromStoreValue(deserializeValue(storeValue));
}
catch (Exception ex) {
throw new IllegalArgumentException("Failed to deserialize cache value '" +
storeValue + "'", ex);
catch (Throwable ex) {
throw new IllegalArgumentException("Failed to deserialize cache value '" + storeValue + "'", ex);
}
}
else {