Uploaded image for project: 'Apache IoTDB'
  1. Apache IoTDB
  2. IOTDB-98

Batch insertion in Server

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Done
    • None
    • None
    • None
    • None

    Description

      Currently, when the client sends a batch of statements (insert/delete) to the server, the server will get each statement from the batch and execute one by one. For each statement, the corresponding FileNodeProcessor (for a storage group) will get a write lock and then execute the statement, which causes unnecessary lock contention.

      It can be improved by getting a write lock once and executing a batch of statements. We can first consider the scenario that the statements in a batch are all insertions.

      The new process mainly contains 3 steps:

      (1) Group the insert statement by storage group while retaining the original order in the batch.

      (2) For each storage group, get the write lock and execute all statements belong to it.

      (3) Set the return code of each statement to the origin position in the batch.

      Attachments

        Activity

          People

            Unassigned Unassigned
            qiaojialin Jialin Qiao
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: