healchow commented on code in PR #7935:
URL: https://github.com/apache/inlong/pull/7935#discussion_r1179080013


##########
inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/source/tubemq/TubeMQSourceOperator.java:
##########
@@ -110,17 +110,22 @@ public Map<String, List<StreamSource>> 
getSourcesMap(InlongGroupInfo groupInfo,
             tubeMQSource.setTopic(streamInfo.getMqResource());
             tubeMQSource.setGroupId(streamId);
             tubeMQSource.setMasterRpc(masterRpc);
-            if (StringUtils.isNotBlank(streamInfo.getDataType())) {
-                String serializationType = 
DataTypeEnum.forType(streamInfo.getDataType()).getType();
-                tubeMQSource.setSerializationType(serializationType);
-            }
             tubeMQSource.setIgnoreParseError(streamInfo.getIgnoreParseError());
 
             for (StreamSource sourceInfo : streamSources) {
                 if (!Objects.equals(streamId, sourceInfo.getInlongStreamId())) 
{
                     continue;
                 }
-                
tubeMQSource.setSerializationType(sourceInfo.getSerializationType());
+
+                if 
(sourceInfo.getSourceType().equalsIgnoreCase(SourceType.FILE) ||

Review Comment:
   Do not use `equalsIgnoreCase`, because in the usage scenarios of other 
modules (such as query MySQL, and Dashboard passing parameters), lowercase 
types are invalid, and we need to limit the generation of dirty 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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to