[ 
https://issues.apache.org/jira/browse/DRILL-7828?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17329901#comment-17329901
 ] 

ASF GitHub Bot commented on DRILL-7828:
---------------------------------------

vdiravka commented on a change in pull request #2192:
URL: https://github.com/apache/drill/pull/2192#discussion_r618839480



##########
File path: 
contrib/format-pcapng/src/main/java/org/apache/drill/exec/store/plugin/PcapFormatConfig.java
##########
@@ -29,18 +29,23 @@
 import com.fasterxml.jackson.annotation.JsonProperty;
 import com.fasterxml.jackson.annotation.JsonTypeName;
 
-@JsonTypeName(PcapngFormatConfig.NAME)
+@JsonTypeName(PcapFormatConfig.NAME)
 @JsonInclude(JsonInclude.Include.NON_DEFAULT)
-public class PcapngFormatConfig implements FormatPluginConfig {
+public class PcapFormatConfig implements FormatPluginConfig {
+  private static final List<String> DEFAULT_EXTNS = ImmutableList.of("pcap", 
"pcapng");
 
-  public static final String NAME = "pcapng";
+  public static final String NAME = "pcap";

Review comment:
       I did it :)
   Please check 
`TestPcapWithPersistentStore#pcapPluginBackwardCompatabilityTest()`. It is 
written similar to `TestPStoreProviders#zkBackwardCompatabilityTest()`.
   It serializes JSON file to `FileSystemConfig` object, put it to ZK 
PersistentStore and retrieves it from there as `PcapFormatConfig` and 
`PcapngFormatConfig` types.
   




-- 
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.

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


> Refactor Pcap and Pcapng format plugin
> --------------------------------------
>
>                 Key: DRILL-7828
>                 URL: https://issues.apache.org/jira/browse/DRILL-7828
>             Project: Apache Drill
>          Issue Type: Sub-task
>            Reporter: Cong Luo
>            Assignee: Vitalii Diravka
>            Priority: Major
>             Fix For: 1.19.0
>
>
> We can check the file's magic number, If that magic number indicates PCAP 
> then use the existing reader, If the magic number indicates PCAPNG, use the 
> refactored NG reader.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to