ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [04/50] [abbrv] incubator-ignite git commit: sp-2 store fixes
Date Tue, 10 Mar 2015 10:36:59 GMT
sp-2 store fixes


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/4b234cfa
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4b234cfa
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4b234cfa

Branch: refs/heads/ignite-337
Commit: 4b234cfae1f29a6fd20828ab40f7b52919bb9a16
Parents: 94b8adb
Author: Yakov Zhdanov <yzhdanov@gridgain.com>
Authored: Fri Mar 6 15:49:08 2015 +0300
Committer: Yakov Zhdanov <yzhdanov@gridgain.com>
Committed: Fri Mar 6 15:49:08 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/internal/processors/cache/GridCacheUtils.java | 2 +-
 .../internal/processors/cache/GridCacheWriteBehindStore.java    | 4 ++--
 .../main/java/org/apache/ignite/internal/util/IgniteUtils.java  | 5 ++++-
 3 files changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4b234cfa/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
index dcdf13e..a2c8af0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
@@ -1785,7 +1785,7 @@ public class GridCacheUtils {
      */
     @NotNull public static CacheException convertToCacheException(IgniteCheckedException
e) {
         if (e.hasCause(CacheWriterException.class))
-            return new CacheWriterException(U.convertExceptionLight(e));
+            return new CacheWriterException(U.convertExceptionNoWrap(e));
 
         if (e instanceof CachePartialUpdateCheckedException)
             return new CachePartialUpdateException((CachePartialUpdateCheckedException)e);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4b234cfa/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheWriteBehindStore.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheWriteBehindStore.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheWriteBehindStore.java
index 63a72e3..e621ec0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheWriteBehindStore.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheWriteBehindStore.java
@@ -433,7 +433,7 @@ public class GridCacheWriteBehindStore<K, V> implements CacheStore<K,
V>, Lifecy
             updateCache(entry.getKey(), entry, StoreOperation.PUT);
         }
         catch (IgniteInterruptedCheckedException e) {
-            throw new CacheWriterException(U.convertExceptionLight(e));
+            throw new CacheWriterException(U.convertExceptionNoWrap(e));
         }
     }
 
@@ -453,7 +453,7 @@ public class GridCacheWriteBehindStore<K, V> implements CacheStore<K,
V>, Lifecy
             updateCache((K)key, null, StoreOperation.RMV);
         }
         catch (IgniteInterruptedCheckedException e) {
-            throw new CacheWriterException(U.convertExceptionLight(e));
+            throw new CacheWriterException(U.convertExceptionNoWrap(e));
         }
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4b234cfa/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
index b5bd40f..f58a24d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
@@ -613,10 +613,13 @@ public abstract class IgniteUtils {
     }
 
     /**
+     * Converts exception, but unlike {@link #convertException(IgniteCheckedException)}
+     * does not wrap passed in exception if none suitable converter found.
+     *
      * @param e Ignite checked exception.
      * @return Ignite runtime exception.
      */
-    public static Exception convertExceptionLight(IgniteCheckedException e) {
+    public static Exception convertExceptionNoWrap(IgniteCheckedException e) {
         C1<IgniteCheckedException, IgniteException> converter = exceptionConverters.get(e.getClass());
 
         if (converter != null)


Mime
View raw message