Skip to content

Conversation

@eldenmoon
Copy link
Member

@eldenmoon eldenmoon commented Jul 9, 2024

picked from #34925 #36317 #36201 #36793

@doris-robot
Copy link

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR

Since 2024-03-18, the Document has been moved to doris-website.
See Doris Document.

@eldenmoon
Copy link
Member Author

run buildall

@eldenmoon eldenmoon changed the title [Refactor](Variant) refactor flush logic to support partial update (#… [pick](Variant) refactor flush logic to support partial update Jul 9, 2024
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

@doris-robot
Copy link

TeamCity be ut coverage result:
Function Coverage: 36.34% (9159/25201)
Line Coverage: 27.87% (74790/268306)
Region Coverage: 26.77% (38576/144124)
Branch Coverage: 23.47% (19551/83314)
Coverage Report: http://coverage.selectdb-in.cc/coverage/36ccf7bafdd42bcb105c03dd50b6ddbbe73e0385_36ccf7bafdd42bcb105c03dd50b6ddbbe73e0385/report/index.html

…pache#34925)

1. Moved variant flatten and flush logic to
`_append_block_with_variant_subcolumns` in segment writer to simplify
handling partial updates.
2. Ensured rowset schema is refreshed during partial updates for tables
with variant types, preventing stale schemas and incorrect data reads.
3. Removed `_output_as_raw_json` as the segment writer now handles
variant flatten and flush logic, which was used for schema change, but t
flatten and flush already handled in segment writer now.
4. Implemented element_at function in BE for non-scalar variants to
enhance functionality.
@eldenmoon
Copy link
Member Author

run buildall

@doris-robot
Copy link

TeamCity be ut coverage result:
Function Coverage: 36.34% (9158/25201)
Line Coverage: 27.88% (74804/268342)
Region Coverage: 26.78% (38602/144147)
Branch Coverage: 23.47% (19558/83332)
Coverage Report: http://coverage.selectdb-in.cc/coverage/d11ece195e6b139e07a912231f9ec5fe2a5c3ae6_d11ece195e6b139e07a912231f9ec5fe2a5c3ae6/report/index.html

…che#36201)

```
Bad cast from type:doris::vectorized::ColumnVector to doris::vectorized::ColumnObject

Check failure stack trace: ***
@ 0x562dcebca976 google::LogMessage::SendToLog()
@ 0x562dcebc73c0 google::LogMessage::Flush()
@ 0x562dcebcb1b9 google::LogMessageFatal::~LogMessageFatal()
@ 0x562d9ded39e6 assert_cast<>()
@ 0x562d9df1e599 doris::segment_v2::HierarchicalDataReader::process_read<>()
@ 0x562d9df1e106 doris::segment_v2::HierarchicalDataReader::next_batch()
@ 0x562d9df3373e doris::segment_v2::ColumnIterator::next_batch()
....
@ 0x562d9ea56d31 doris::EngineChecksumTask::_compute_checksum()
@ 0x562d9ea55cc2 doris::EngineChecksumTask::execute()
@ 0x562d9b558355 doris::check_consistency_callback()
```

introduced by apache#34925
…ma and write missing blocks (apache#36317)

1. update_rowset_schema should not update _context.tablet_schema, since
it's used as src schema for schema change, if it's changed may lead to
wrong schema with block
2. buffering block during schema change should merge first and then
flush, otherwise may lost current block
…che#36793)

1. Variant use serialize_one_row_to_string to string and then parse to
jsonb as row store.Since we could not get the original string after
2. Remove redundant code
@eldenmoon eldenmoon changed the title [pick](Variant) refactor flush logic to support partial update [pick](Variant) pick some refactor and fix Jul 10, 2024
@eldenmoon
Copy link
Member Author

run buildall

@eldenmoon
Copy link
Member Author

run buildall

@doris-robot
Copy link

TeamCity be ut coverage result:
Function Coverage: 36.34% (9156/25197)
Line Coverage: 27.88% (74778/268242)
Region Coverage: 26.77% (38589/144128)
Branch Coverage: 23.47% (19557/83326)
Coverage Report: http://coverage.selectdb-in.cc/coverage/e787a3d118e01a7f9755c44381088afec1b4a1be_e787a3d118e01a7f9755c44381088afec1b4a1be/report/index.html

@xiaokang xiaokang merged commit 217eac7 into apache:branch-2.1 Jul 11, 2024
@eldenmoon eldenmoon deleted the pick-var-rf branch July 12, 2024 10:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants