You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by GitBox <gi...@apache.org> on 2022/05/05 02:57:44 UTC
[GitHub] [incubator-inlong] thexiay opened a new pull request, #4065: [INLONG-4030][Sort] Import data in Canal JSON format from Kafka into …
thexiay opened a new pull request, #4065:
URL: https://github.com/apache/incubator-inlong/pull/4065
…Hive in insert-only mode
### Title Name: [INLONG-4030][Sort] Title of the pull request
where *XYZ* should be replaced by the actual issue number.
Fixes #<xyz>
### Motivation
*Explain here the context, and why you're making that change. What is the problem you're trying to solve?*
### Modifications
*Describe the modifications you've done.*
### Verifying this change
*(Please pick either of the following options)*
- [ ] This change is a trivial rework/code cleanup without any test coverage.
- [ ] This change is already covered by existing tests, such as:
*(please describe tests)*
- [ ] This change added tests and can be verified as follows:
*(example:)*
- *Added integration tests for end-to-end deployment with large payloads (10MB)*
- *Extended integration test for recovery after broker failure*
### Documentation
- Does this pull request introduce a new feature? (yes / no)
- If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)
- If a feature is not applicable for documentation, explain why?
- If a feature is not documented yet in this PR, please create a follow-up issue for adding the documentation
--
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: commits-unsubscribe@inlong.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-inlong] yunqingmoswu commented on a diff in pull request #4065: [INLONG-4030][Sort] Import data in Canal JSON format from Kafka into Hive in insert-only mode
Posted by GitBox <gi...@apache.org>.
yunqingmoswu commented on code in PR #4065:
URL: https://github.com/apache/incubator-inlong/pull/4065#discussion_r865566020
##########
inlong-sort/sort-formats/format-json/src/main/java/org/apache/inlong/sort/formats/json/canal/CanalJsonEnhancedDeserializationSchema.java:
##########
@@ -224,6 +236,11 @@ public void deserialize(@Nullable byte[] message, Collector<RowData> out) throws
}
final GenericRowData row = (GenericRowData) jsonDeserializer.convertToRowData(root);
String type = row.getString(2).toString(); // "type" field
+ // only not appendMode type field is valid
+ if (appendMode) {
Review Comment:
This judgment should be removed to avoid the type of output being INSERT?
--
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: commits-unsubscribe@inlong.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-inlong] healchow merged pull request #4065: [INLONG-4030][Sort] Import all changelog mode data ingest into Hive
Posted by GitBox <gi...@apache.org>.
healchow merged PR #4065:
URL: https://github.com/apache/incubator-inlong/pull/4065
--
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: commits-unsubscribe@inlong.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-inlong] healchow commented on a diff in pull request #4065: [INLONG-4030][Sort] Import data in Canal JSON format from Kafka into Hive in insert-only mode
Posted by GitBox <gi...@apache.org>.
healchow commented on code in PR #4065:
URL: https://github.com/apache/incubator-inlong/pull/4065#discussion_r865552299
##########
inlong-sort/sort-formats/format-json/src/main/java/org/apache/inlong/sort/formats/json/canal/CanalEnhancedOptions.java:
##########
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.inlong.sort.formats.json.canal;
+
+import org.apache.flink.configuration.ConfigOption;
+import org.apache.flink.configuration.ConfigOptions;
+
+public class CanalEnhancedOptions {
Review Comment:
Please add some java docs for classes and public methods, thanks.
--
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: commits-unsubscribe@inlong.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-inlong] thexiay commented on a diff in pull request #4065: [INLONG-4030][Sort] Import data in Canal JSON format from Kafka into Hive in insert-only mode
Posted by GitBox <gi...@apache.org>.
thexiay commented on code in PR #4065:
URL: https://github.com/apache/incubator-inlong/pull/4065#discussion_r865892561
##########
inlong-sort/sort-formats/format-json/src/main/java/org/apache/inlong/sort/formats/json/canal/CanalJsonEnhancedDeserializationSchema.java:
##########
@@ -224,6 +236,11 @@ public void deserialize(@Nullable byte[] message, Collector<RowData> out) throws
}
final GenericRowData row = (GenericRowData) jsonDeserializer.convertToRowData(root);
String type = row.getString(2).toString(); // "type" field
+ // only not appendMode type field is valid
+ if (appendMode) {
Review Comment:
avoid add option in different source format. Import hive sink changelog data, regard upsert and delete data as insert data.
--
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: commits-unsubscribe@inlong.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-inlong] thexiay commented on a diff in pull request #4065: [INLONG-4030][Sort] Import all changelog mode data ingest into Hive
Posted by GitBox <gi...@apache.org>.
thexiay commented on code in PR #4065:
URL: https://github.com/apache/incubator-inlong/pull/4065#discussion_r866604359
##########
inlong-sort/sort-formats/format-json/src/main/java/org/apache/inlong/sort/formats/json/canal/CanalEnhancedOptions.java:
##########
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.inlong.sort.formats.json.canal;
+
+import org.apache.flink.configuration.ConfigOption;
+import org.apache.flink.configuration.ConfigOptions;
+
+public class CanalEnhancedOptions {
Review Comment:
Import all changelog mode data ingest into Hive.
So DELETE THIS file.
--
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: commits-unsubscribe@inlong.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org