Xikui Wang has posted comments on this change. Change subject: Feed Adaptor and RecordReader Clean ......................................................................
Patch Set 10: (4 comments) https://asterix-gerrit.ics.uci.edu/#/c/1535/10/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/input/record/reader/stream/EmptyLineSeparatedRecordReader.java File asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/input/record/reader/stream/EmptyLineSeparatedRecordReader.java: Line 36: public EmptyLineSeparatedRecordReader(AsterixInputStream inputStream, Map<String, String> config) { > why not address this? This is config in the interface which is used by other methods but has no use here. If I remove this method, the newInstance would not be able to find this constructor as for different parameters... Any suggestions? https://asterix-gerrit.ics.uci.edu/#/c/1535/10/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/input/record/reader/stream/LineRecordReader.java File asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/input/record/reader/stream/LineRecordReader.java: > Xikui, this can clearly use an inheritance relationship rather than have th The quoted and unquoted record reader are mapped into the same formats. Should I change the keywords, i.e. user experience to separate these two. (Current one is indeed not clean). Detailed in the comments to Till. PS10, Line 40: quotedReader > I think that having the LineRecordReader and QuotedLineRecordReader as two The original LineRecordReader and QuotedLineRecordReader both are mapped to the same formats set: CSV and delimited-text. Using the `format` keyword only cannot locate the right clazz. Thus I merged these two together... This indeed looks messy. One thing I can do is to map these two to different formats which will change the user experience. Is that ok? For the last part, I am not sure whether I understand correctly. getRecordReaderClazz uses `format` as the key to look for record reader. Do you mean by adding a factory to each type of StreamReader, i.e. having a LineRecordReader handles formats csv and delimited-text, and reads configuration to decide creating Line~ or Quoted~? https://asterix-gerrit.ics.uci.edu/#/c/1535/10/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/input/record/reader/stream/StreamRecordReaderFactory.java File asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/input/record/reader/stream/StreamRecordReaderFactory.java: PS10, Line 79: AsterixException("UNKNOWN Adaptor name"); > ErrorCode Done -- To view, visit https://asterix-gerrit.ics.uci.edu/1535 To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings Gerrit-MessageType: comment Gerrit-Change-Id: I699657ddd8408fd00bcbd7df57b6610ef3692a1a Gerrit-PatchSet: 10 Gerrit-Project: asterixdb Gerrit-Branch: master Gerrit-Owner: Xikui Wang <xkk...@gmail.com> Gerrit-Reviewer: Jenkins <jenk...@fulliautomatix.ics.uci.edu> Gerrit-Reviewer: Till Westmann <ti...@apache.org> Gerrit-Reviewer: Xikui Wang <xkk...@gmail.com> Gerrit-Reviewer: abdullah alamoudi <bamou...@gmail.com> Gerrit-HasComments: Yes