updated version with support for cross-cluster reindexing