-
Notifications
You must be signed in to change notification settings - Fork 543
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
Bug fix: inserting Array of nullable primitive #1104
Bug fix: inserting Array of nullable primitive #1104
Conversation
|
Thank you @Blackmorse! Actually this has been covered in my local changes. Basically, widen unsigned types is probably not the best way, because it consumes more memory and has side effects in type conversion. I added I've completed the read part last night, and I should be able to complete the write part in a day or two. |
Thanks for the answer, @zhicwu Why is this related to the unsigned types? |
Sorry I only explained the reason of refactoring :p The issue is not directly related to unsigned types, but during the refactoring, I also changed the way to handle nullable types and moved methods like |
Hi, @zhicwu |
Hi @Blackmorse, I'm sorry for blocking your work. I must confess that I didn't spend any time on this project in the past weeks due to work on hand. Are you expecting a patch release in maven central? As you probably noticed, there are some more changes in If it's fine to use nightly build(v0.3.3-SNAPSHOT) and wait for a few more days, I can commit some changes in local in a day or two, which will surely fix the issue along with performance improvement(in addition to PR #1087). However, this involves breaking changes to reduce serialization cost - if you're using interfaces ClickHouseDeserializer, ClickHouseSerializer and ClickHouseDataProcessor etc., your code will be impacted. Lastly, I'm sure there's always good reason to use nullable types, but another alternative approach I can think of is to use Array(Int8), which avoids boxed type and null flag in serialization. |
Description:
Unable to insert the data into array of nullables
E.g.
Trying to push an array(Scala code):
Error:
Reason:
when using (e.g)
Array(Nullable(Int8))
type,ClickHouseArrayValue
butClickHouseRowBinaryProcessor
still expectsClickHouseByteArrayValue
.