From e4ae16c38beff38b0741174e95e92381392b0f57 Mon Sep 17 00:00:00 2001 From: Tyrantlucifer Date: Mon, 14 Nov 2022 16:08:15 +0800 Subject: [PATCH] [Improve][Connector][bin-log] Unified exception of MapMakerHelper (#1395) (cherry picked from commit 1248cc23b1b65a47d3eb351c7c705aad9989afe5) --- .../main/java/com/google/common/collect/MapMakerHelper.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/chunjun-connectors/chunjun-connector-binlog/src/main/java/com/google/common/collect/MapMakerHelper.java b/chunjun-connectors/chunjun-connector-binlog/src/main/java/com/google/common/collect/MapMakerHelper.java index 6b872409e6..a3a1fec708 100644 --- a/chunjun-connectors/chunjun-connector-binlog/src/main/java/com/google/common/collect/MapMakerHelper.java +++ b/chunjun-connectors/chunjun-connector-binlog/src/main/java/com/google/common/collect/MapMakerHelper.java @@ -17,6 +17,8 @@ */ package com.google.common.collect; +import com.dtstack.chunjun.throwable.ChunJunRuntimeException; + import com.google.common.base.Function; import java.lang.reflect.Method; @@ -31,7 +33,7 @@ public static MapMaker softValues(MapMaker mapMaker) { method.setAccessible(true); return (MapMaker) method.invoke(mapMaker); } catch (Exception e) { - throw new RuntimeException(e); + throw new ChunJunRuntimeException(e); } } @@ -44,7 +46,7 @@ public static ConcurrentMap makeComputingMap( method.setAccessible(true); return (ConcurrentMap) method.invoke(mapMaker, computingFunction); } catch (Exception e) { - throw new RuntimeException(e); + throw new ChunJunRuntimeException(e); } } }