Skip to content

Optimized write performace by reducing separators#17670

Open
Caideyipi wants to merge 3 commits into
masterfrom
wal-fix
Open

Optimized write performace by reducing separators#17670
Caideyipi wants to merge 3 commits into
masterfrom
wal-fix

Conversation

@Caideyipi
Copy link
Copy Markdown
Collaborator

Description

As the title said.


This PR has:

  • been self-reviewed.
    • concurrent read
    • concurrent write
    • concurrent read and write
  • added documentation for new or modified features or behaviors.
  • added Javadocs for most classes and all non-trivial methods.
  • added or updated version, license, or notice information
  • added comments explaining the "why" and the intent of the code wherever would not be obvious
    for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold
    for code coverage.
  • added integration tests.
  • been tested in a test IoTDB cluster.

Key changed/added classes (or packages if there are too many classes) in this PR

Comment on lines -1744 to 1801
for (Map.Entry<TsFileProcessor, InsertRowsNode> entry : tsFileProcessorMap.entrySet()) {
final List<Map.Entry<TsFileProcessor, InsertRowsNode>> groupedEntries =
new ArrayList<>(tsFileProcessorMap.entrySet());
markOnlyLastInsertFragment(groupedEntries, Map.Entry::getValue);
for (Map.Entry<TsFileProcessor, InsertRowsNode> entry : groupedEntries) {
InsertRowsNode subInsertRowsNode = entry.getValue();
try {
List<TsFileProcessor> insertedProcessors =
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

May use a count to find the last entry and avoid creating a new list.

@sonarqubecloud
Copy link
Copy Markdown

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.

2 participants