-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Avoid writing to Hive an empty list of column stats because Hive 2.x fails #13502
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a product test? I confirmed we can reproduce the issue in EnvSinglenode.
432d5db to
d28103a
Compare
|
I wonder what change done after |
#12806 is the only candidate i could find. If @dain, do you know whether #12806 change the lifecycle of |
|
Please try making the commit comment a bit more expressive: (and try to keep the length of the lines in the commit less than 80 chars) |
|
I approve that |
d28103a to
b5c8111
Compare
b5c8111 to
aa803a6
Compare
|
This is a good change, but I am still concerned about #13502 (comment). @guyco33 are you able to verify this? |
|
Thrift calls will reach the exception code only for hive Metastore that doesn't support date statistics - It should be for earlier hive versions before 1.2.0 |
|
It seems now that every table with both date and non-date columns will execute 2 Thrift calls while the code that test the value of |
Issue happens on hive2.3.
Sending empty stats will generate empty columns list that will return null value and will make this to fail on
java.lang.NullPointerException: Cannot invoke "java.util.List.iterator()" because "stats" is nullOn hive3 issue doesn't happen since empty column list result with empty list
On
387the issue happens only when it's the first write before any other "mixed" table with both date and non-date columns - that's why it's hard to catch it, since most of tables contains both date and non-date columns.On
388+it seems to constantly happen.Description
Related issues, pull requests, and links
Documentation
( ) No documentation is needed.
( ) Sufficient documentation is included in this PR.
( ) Documentation PR is available with #prnumber.
( ) Documentation issue #issuenumber is filed, and can be handled later.
Release notes
( ) No release notes entries required.
( ) Release notes entries required with the following suggested text: