You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@paimon.apache.org by "yuzelin (via GitHub)" <gi...@apache.org> on 2023/04/24 06:18:37 UTC

[GitHub] [incubator-paimon] yuzelin opened a new pull request, #1000: [flink][bug] Correct the use of MySQL JDBC metadata in MySQL CDC actions

yuzelin opened a new pull request, #1000:
URL: https://github.com/apache/incubator-paimon/pull/1000

   ### Purpose
   
   Fix bug in mysql cdc actions.
   
   ### Tests
   
   `MySqlSyncDatabaseActionITCase`
   `MySqlCdcE2eTestBase`
   
   ### API and Format 
   
   No
   
   ### Documentation
   
   No


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@paimon.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-paimon] JingsongLi merged pull request #1000: [flink][bug] Correct the use of MySQL JDBC metadata in MySQL CDC actions

Posted by "JingsongLi (via GitHub)" <gi...@apache.org>.
JingsongLi merged PR #1000:
URL: https://github.com/apache/incubator-paimon/pull/1000


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@paimon.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-paimon] yuzelin commented on pull request #1000: [flink][bug] Correct the use of MySQL JDBC metadata in MySQL CDC actions

Posted by "yuzelin (via GitHub)" <gi...@apache.org>.
yuzelin commented on PR #1000:
URL: https://github.com/apache/incubator-paimon/pull/1000#issuecomment-1519699728

   ![4ADEFB28-E2F0-44D0-BB9E-E210ACD5889D](https://user-images.githubusercontent.com/33053040/233953945-923591d4-f56d-471a-985c-19d5b181beb9.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@paimon.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-paimon] JingsongLi commented on a diff in pull request #1000: [flink][bug] Correct the use of MySQL JDBC metadata in MySQL CDC actions

Posted by "JingsongLi (via GitHub)" <gi...@apache.org>.
JingsongLi commented on code in PR #1000:
URL: https://github.com/apache/incubator-paimon/pull/1000#discussion_r1174833731


##########
paimon-flink/paimon-flink-common/src/main/java/org/apache/paimon/flink/action/cdc/mysql/MySqlDebeziumJsonEventParser.java:
##########
@@ -288,11 +290,10 @@ private Map<String, String> keyCaseInsensitive(Map<String, String> origin) {
         Map<String, String> keyCaseInsensitive = new HashMap<>();
         for (Map.Entry<String, String> entry : origin.entrySet()) {
             String fieldName = entry.getKey().toLowerCase();
-            if (keyCaseInsensitive.containsKey(fieldName)) {
-                LOG.warn(
-                        "Duplicate key appears when converting map keys to case-insensitive form. Original map is:\n{}",
-                        origin);
-            }
+            checkArgument(
+                    !keyCaseInsensitive.containsKey(fieldName),
+                    "Duplicate key appears when converting map keys to case-insensitive form. Original map is:\n"
+                            + origin);

Review Comment:
   Use:
   ```
   public static void checkArgument(
               boolean condition,
               @Nullable String errorMessageTemplate,
               @Nullable Object... errorMessageArgs)
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@paimon.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org