You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by "chestnut-c (via GitHub)" <gi...@apache.org> on 2023/06/29 09:19:28 UTC
[GitHub] [inlong] chestnut-c opened a new pull request, #8370: [INLONG-8369][Manager] Add Mongo field type mapping strategy to improve usability
chestnut-c opened a new pull request, #8370:
URL: https://github.com/apache/inlong/pull/8370
[INLONG-8369][Manager] Add Mongo field type mapping strategy to improve usability
- Fixes #8369
### Motivation
Inlong Mongo ExtractNode or LoadNode currently does not support some special field types, add Mongo field type mapping strategy to mapping to the corresponding type to run correctly
--
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] [inlong] healchow commented on a diff in pull request #8370: [INLONG-8369][Manager] Add MongoDB field type mapping strategy to improve usability
Posted by "healchow (via GitHub)" <gi...@apache.org>.
healchow commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1247489866
##########
inlong-manager/manager-pojo/src/main/java/org/apache/inlong/manager/pojo/sort/node/provider/MongoProvider.java:
##########
@@ -33,6 +35,8 @@
*/
public class MongoProvider implements ExtractNodeProvider {
Review Comment:
Can this class name change to `MongoDBProvider`?
--
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] [inlong] fuweng11 commented on a diff in pull request #8370: [INLONG-8369][Manager] Add Mongo field type mapping strategy to improve usability
Posted by "fuweng11 (via GitHub)" <gi...@apache.org>.
fuweng11 commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1247331794
##########
inlong-manager/manager-common/src/main/java/org/apache/inlong/manager/common/consts/DataNodeType.java:
##########
@@ -35,4 +35,5 @@ public class DataNodeType {
public static final String POSTGRESQL = "POSTGRESQL";
public static final String ORACLE = "ORACLE";
public static final String SQLSERVER = "SQLSERVER";
+ public static final String MONGO = "MONGO";
Review Comment:
`MONGODB`
--
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] [inlong] chestnut-c commented on a diff in pull request #8370: [INLONG-8369][Manager] Add Mongo field type mapping strategy to improve usability
Posted by "chestnut-c (via GitHub)" <gi...@apache.org>.
chestnut-c commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1247435955
##########
inlong-manager/manager-common/src/main/java/org/apache/inlong/manager/common/consts/DataNodeType.java:
##########
@@ -35,4 +35,5 @@ public class DataNodeType {
public static final String POSTGRESQL = "POSTGRESQL";
public static final String ORACLE = "ORACLE";
public static final String SQLSERVER = "SQLSERVER";
+ public static final String MONGO = "MONGO";
Review Comment:
> MONGODB
okk
--
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] [inlong] dockerzhang merged pull request #8370: [INLONG-8369][Manager] Add MongoDB field type mapping strategy to improve usability
Posted by "dockerzhang (via GitHub)" <gi...@apache.org>.
dockerzhang merged PR #8370:
URL: https://github.com/apache/inlong/pull/8370
--
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] [inlong] chestnut-c commented on a diff in pull request #8370: [INLONG-8369][Manager] Add MongoDB field type mapping strategy to improve usability
Posted by "chestnut-c (via GitHub)" <gi...@apache.org>.
chestnut-c commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1248078971
##########
inlong-manager/manager-common/src/main/java/org/apache/inlong/manager/common/fieldtype/strategy/MongoFieldTypeStrategy.java:
##########
@@ -0,0 +1,43 @@
+/*
+ * 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.manager.common.fieldtype.strategy;
+
+import org.apache.inlong.manager.common.consts.DataNodeType;
+import org.apache.inlong.manager.common.fieldtype.FieldTypeMappingReader;
+
+import org.apache.commons.lang3.StringUtils;
+
+import static org.apache.inlong.manager.common.consts.InlongConstants.LEFT_BRACKET;
+
+/**
+ * The mongo field type mapping strategy
+ */
+public class MongoFieldTypeStrategy implements FieldTypeMappingStrategy {
Review Comment:
> `MongoDBFieldTypeStrategy`
okk
##########
inlong-manager/manager-pojo/src/test/java/org/apache/inlong/manager/pojo/sort/util/FieldInfoUtilsTest.java:
##########
@@ -84,4 +85,16 @@ public void testSQLServerFieldTypeInfo() {
TypeInfo typeInfo = fieldInfo.getFormatInfo().getTypeInfo();
Assertions.assertTrue(typeInfo instanceof StringTypeInfo);
}
+
+ @Test
+ public void testMongoFieldTypeInfo() {
Review Comment:
> `testMongoDBFieldTypeInfo`
okk
--
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] [inlong] healchow commented on a diff in pull request #8370: [INLONG-8369][Manager] Add MongoDB field type mapping strategy to improve usability
Posted by "healchow (via GitHub)" <gi...@apache.org>.
healchow commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1247485681
##########
inlong-manager/manager-common/src/main/java/org/apache/inlong/manager/common/fieldtype/strategy/MongoFieldTypeStrategy.java:
##########
@@ -0,0 +1,43 @@
+/*
+ * 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.manager.common.fieldtype.strategy;
+
+import org.apache.inlong.manager.common.consts.DataNodeType;
+import org.apache.inlong.manager.common.fieldtype.FieldTypeMappingReader;
+
+import org.apache.commons.lang3.StringUtils;
+
+import static org.apache.inlong.manager.common.consts.InlongConstants.LEFT_BRACKET;
+
+/**
+ * The mongo field type mapping strategy
+ */
+public class MongoFieldTypeStrategy implements FieldTypeMappingStrategy {
Review Comment:
`MongoDBFieldTypeStrategy`
--
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] [inlong] healchow commented on a diff in pull request #8370: [INLONG-8369][Manager] Add MongoDB field type mapping strategy to improve usability
Posted by "healchow (via GitHub)" <gi...@apache.org>.
healchow commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1247489507
##########
inlong-manager/manager-pojo/src/test/java/org/apache/inlong/manager/pojo/sort/util/FieldInfoUtilsTest.java:
##########
@@ -84,4 +85,16 @@ public void testSQLServerFieldTypeInfo() {
TypeInfo typeInfo = fieldInfo.getFormatInfo().getTypeInfo();
Assertions.assertTrue(typeInfo instanceof StringTypeInfo);
}
+
+ @Test
+ public void testMongoFieldTypeInfo() {
Review Comment:
`testMongoDBFieldTypeInfo`
--
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] [inlong] chestnut-c commented on a diff in pull request #8370: [INLONG-8369][Manager] Add MongoDB field type mapping strategy to improve usability
Posted by "chestnut-c (via GitHub)" <gi...@apache.org>.
chestnut-c commented on code in PR #8370:
URL: https://github.com/apache/inlong/pull/8370#discussion_r1248079269
##########
inlong-manager/manager-pojo/src/main/java/org/apache/inlong/manager/pojo/sort/node/provider/MongoProvider.java:
##########
@@ -33,6 +35,8 @@
*/
public class MongoProvider implements ExtractNodeProvider {
Review Comment:
> Can this class name change to `MongoDBProvider`?
okk
--
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