mirror of
https://github.com/apache/impala.git
synced 2026-01-06 06:01:03 -05:00
Logging file or table data is a bad idea, and doing it by default is particularly bad. This patch changes HdfsScanNode::LogRowParseError() to log a file and offset only. Testing: See rewritten tests. To support testing this change, we also fix IMPALA-3895, by introducing a canonical string __HDFS_FILENAME__ that all Hadoop filenames in the ERROR output are replaced with before comparing with the expected results. This fixes a number of issues with the old way of matching filenames which purported to be a regex, but really wasn't. In particular, we can now match the rest of an ERROR line after the filename, which was not possible before. In some cases, we don't want to substitute filenames because the ERROR output is looking for a very specific output. In that case we can write: $NAMENODE/<filename> and this patch will not perform _any_ filename substitutions on ERROR sections that contain the $NAMENODE string. Finally, this patch fixes a bug where a test that had an ERRORS section but no RESULTS section would silently pass without testing anything. Change-Id: I5a604f8784a9ff7b4bf878f82ee7f56697df3272 Reviewed-on: http://gerrit.cloudera.org:8080/4020 Reviewed-by: Henry Robinson <henry@cloudera.com> Tested-by: Internal Jenkins
32 lines
579 B
Plaintext
32 lines
579 B
Plaintext
====
|
|
---- QUERY
|
|
select tinyint_col from overflow
|
|
---- CATCH
|
|
Error converting column: 0 to TINYINT
|
|
====
|
|
---- QUERY
|
|
select smallint_col from overflow
|
|
---- CATCH
|
|
Error converting column: 1 to SMALLINT
|
|
====
|
|
---- QUERY
|
|
select int_col from overflow
|
|
---- CATCH
|
|
Error converting column: 2 to INT
|
|
====
|
|
---- QUERY
|
|
select bigint_col from overflow
|
|
---- CATCH
|
|
Error converting column: 3 to BIGINT
|
|
====
|
|
---- QUERY
|
|
select float_col from overflow
|
|
---- CATCH
|
|
Error converting column: 4 to FLOAT
|
|
====
|
|
---- QUERY
|
|
select double_col from overflow
|
|
---- CATCH
|
|
Error converting column: 5 to DOUBLE
|
|
====
|