Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The process aborts only when a partition is destroyed.

At node startup, during partition initialization, if the total number of pages for re-encryption is greater than zero - this cache group is scheduled for re-encryption.

Cleanup old key

Old cache group encryption key will be removed when

...

  1. If checkpoint failed it should restore physical records from WAL, as usual.
  2. If checkpoint was not invoked re-encryption is started from the beginning using saved logical WAL record (that was recorded during key rotation).

Risks and assumptions

  • Background re-encryption may affect performance. Performance impact can be managed using the following configuration options:
    1. reencryptionThreadCnt - number of threads used for re-encryption.
    2. reencryptionBatchSize - number of pages that are scanned during re-encryption under checkpoint lock.
    3. reencryptionRateLimit - page scanning speed limit in megabytes per second.
  • The WAL history can be not enough to store all entries between checkpoints (this should be carefully tuned by properly setting the size of the WAL history and tuning the re-encryption performance).
  • The WAL history (for delta rebalancing) may be lost for all cache groups due to background re-encryption.

...