Csaba Ringhofer created IMPALA-10662:
----------------------------------------
Summary: Remove HS2 vs Beeswax differences is EE tests
Key: IMPALA-10662
URL: https://issues.apache.org/jira/browse/IMPALA-10662
Project: IMPALA
Issue Type: Improvement
Components: Infrastructure
Reporter: Csaba Ringhofer
Beeswax and HS2 results sets have some differences in precision:
TIMESTAMP:
- HS2 rounds to microsecond precision, while Beeswax returns nanosec
- only differs in EE tests, impala-shell returns timestamps the same way for
both protocols
- the cause is that impyla (and dpapi in general) converts timestamps to
datetime.datetime by default, which has only microsec precision
DOUBLE/FLOAT:
- HS2 rounds to less digits
- differs both in EE tests and impala-shell
- the cause is that by default Python formats strings with less precision than
the stringstream we use in c++
- there is no clear good way to format a double, string<->double conversions
are inherently lossy
- probably there is a standard way to do this in SQL, but I don't know about it
This difference is handled in .test files with the DBAPI_RESULTS, which lets us
specify different outputs for the protocols.
I think that it would be better to remove DBAPI_RESULTS and simply format these
types in HS2 to match with the beeswax output. The default conversions can be
tested in impyla, while the EE tests should focus on Impala and use the maximum
precision possible.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]