sysbench
sysbench copied to clipboard
lua: speed up creating secondary
When creating a secondary index, the database needs to supplement the index for each existing data synchronously. In some distributed databases, creating a secondary index requires a lot of steps (for example, using the online schema change scheme of Google F1), and it takes longer to create a secondary index in this scenario. Create indexes before performing bulk insert, which can avoid some unnecessary work and significantly reduce the delay in the oltp prepare phase.