forked from apache/pinot
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Re-implement CSV record reader to skip unparseable lines (apache#14396)
- Loading branch information
1 parent
381097d
commit d03241a
Showing
22 changed files
with
657 additions
and
745 deletions.
There are no files selected for viewing
377 changes: 144 additions & 233 deletions
377
...rmat/pinot-csv/src/main/java/org/apache/pinot/plugin/inputformat/csv/CSVRecordReader.java
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
921 changes: 455 additions & 466 deletions
921
.../pinot-csv/src/test/java/org/apache/pinot/plugin/inputformat/csv/CSVRecordReaderTest.java
Large diffs are not rendered by default.
Oops, something went wrong.
8 changes: 4 additions & 4 deletions
8
pinot-plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileBasic.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
id,name | ||
"100","John" | ||
"101","Jane" | ||
"102","Alice" | ||
"103","Bob" | ||
100,John | ||
101,Jane | ||
102,Alice | ||
103,Bob |
Empty file.
2 changes: 1 addition & 1 deletion
2
...lugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithAlternateDelimiter.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
id|fisrtName|lastName | ||
id|firstName|lastName | ||
100|John|Doe | ||
101|Jane|Doe | ||
102|Jen|Doe |
5 changes: 5 additions & 0 deletions
5
pinot-plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithCustomNull.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
id,name | ||
100,NULL | ||
,Jane | ||
NULL,NULL | ||
, |
4 changes: 4 additions & 0 deletions
4
...t-plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithMultiLineValues.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
id,name | ||
100,"John | ||
101,Jane" | ||
102,Alice |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 0 additions & 15 deletions
15
...t-input-format/pinot-csv/src/test/resources/dataFileWithMultipleCombinationsParseable.csv
This file was deleted.
Oops, something went wrong.
File renamed without changes.
3 changes: 0 additions & 3 deletions
3
pinot-plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithQuotedHeaders.csv
This file was deleted.
Oops, something went wrong.
File renamed without changes.
4 changes: 4 additions & 0 deletions
4
pinot-plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithSingleColumn.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
name | ||
John | ||
Jane | ||
Jen |
4 changes: 0 additions & 4 deletions
4
...lugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithSpaceAroundHeaders.csv
This file was deleted.
Oops, something went wrong.
4 changes: 4 additions & 0 deletions
4
...plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithSurroundingSpaces.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
firstName , lastName , id | ||
John , Doe,100 | ||
Jane, Doe, 101 | ||
Jen,Doe ,102 |
File renamed without changes.
3 changes: 3 additions & 0 deletions
3
...ugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithUnparseableLastLine.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
id,name | ||
"100","John" | ||
"101","Jane"s" |
4 changes: 4 additions & 0 deletions
4
...t-plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithUnparseableLine.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
id,name | ||
"100","John" | ||
"101","Jane"s" | ||
"102","Alice" |
5 changes: 0 additions & 5 deletions
5
...plugins/pinot-input-format/pinot-csv/src/test/resources/dataFileWithUnparseableLines2.csv
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters