vinyl: update recovery context with records written during recovery
During recovery, we may write VY_LOG_CREATE_LSM and VY_LOG_DROP_LSM records we failed to write before restart (because those records are written after WAL and hence may not make it to vylog). Right after recovery we invoke garbage collection to drop incomplete runs. Once VY_LOG_PREPARE_LSM record is introduced, we will also collect incomplete LSM trees there (those we failed to build). However, there may be LSM trees we managed to build but failed to write VY_LOG_CREATE_LSM for. This is OK as we will retry vylog write, but currenntly it isn't reflected in the recovery context used for garbage collection. To avoid purging such LSM trees, let's update the recovery context with records written during recovery. Needed for #1653
Loading
Please register or sign in to comment