From 5d25ab4ce3217c0651dcd12543d25121abb4768d Mon Sep 17 00:00:00 2001 From: XzwZai Date: Thu, 16 Jul 2020 13:23:40 +0800 Subject: [PATCH] Fix a bug about Environment merge --- .../flink/table/gateway/config/entries/ServerEntry.java | 4 ++-- .../flink/table/gateway/config/entries/SessionEntry.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/ververica/flink/table/gateway/config/entries/ServerEntry.java b/src/main/java/com/ververica/flink/table/gateway/config/entries/ServerEntry.java index e07e244..b52d4e1 100644 --- a/src/main/java/com/ververica/flink/table/gateway/config/entries/ServerEntry.java +++ b/src/main/java/com/ververica/flink/table/gateway/config/entries/ServerEntry.java @@ -72,8 +72,8 @@ public Map asTopLevelMap() { * overwritten by the second one. */ public static ServerEntry merge(ServerEntry gateway1, ServerEntry gateway2) { - final Map mergedProperties = new HashMap<>(gateway1.asTopLevelMap()); - mergedProperties.putAll(gateway2.asTopLevelMap()); + final Map mergedProperties = new HashMap<>(gateway1.asMap()); + mergedProperties.putAll(gateway2.asMap()); final DescriptorProperties properties = new DescriptorProperties(true); properties.putProperties(mergedProperties); diff --git a/src/main/java/com/ververica/flink/table/gateway/config/entries/SessionEntry.java b/src/main/java/com/ververica/flink/table/gateway/config/entries/SessionEntry.java index bc2f66f..79156e0 100644 --- a/src/main/java/com/ververica/flink/table/gateway/config/entries/SessionEntry.java +++ b/src/main/java/com/ververica/flink/table/gateway/config/entries/SessionEntry.java @@ -65,8 +65,8 @@ public Map asTopLevelMap() { * overwritten by the second one. */ public static SessionEntry merge(SessionEntry session1, SessionEntry session2) { - final Map mergedProperties = new HashMap<>(session1.asTopLevelMap()); - mergedProperties.putAll(session2.asTopLevelMap()); + final Map mergedProperties = new HashMap<>(session1.asMap()); + mergedProperties.putAll(session2.asMap()); final DescriptorProperties properties = new DescriptorProperties(true); properties.putProperties(mergedProperties);