Store tags in compressed segments instead of in the metadata Delta Lake#293
Merged
Store tags in compressed segments instead of in the metadata Delta Lake#293
Conversation
chrthomsen
approved these changes
Feb 28, 2025
skejserjensen
requested changes
Mar 2, 2025
This was referenced Mar 5, 2025
skejserjensen
approved these changes
Mar 6, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR implements #197 by storing tags in the compressed segments instead of in the metadata Delta Lake and removing univariate ids from the entire code base.
The ingestion process has been updated to no longer lookup and save the tag hash using the table metadata manager when inserting data points. Instead, we calculate a tag hash in the uncompressed data manager that is only used internally for managing uncompressed multivariate time series during ingestion. This tag hash is not used beyond compression since the compressed segments are stored per table.
Compression has been updated to no longer store the univariate id in the compressed segments and instead store the tag columns. The compressed data manager has also been updated so we now use the tag columns for sorting instead of the univariate id when saving data to disk.
The query process has also been updated accordingly.
ParquetExecnow uses a schema that is based on the specific model table,GridExecreconstructs data points that includes the tag columns in each row, andSortedJoinExecnow reconstructs the query result in the wanted return order using the tag columns in the first field column instead of using the metadata Delta Lake.It should be noted that the objective of this PR is to implement the base functionality for tags in data meaning further optimizations are required. #292 has been created to look into further optimizations.