+
+ for block, _ := range coll.BlockDigestToSize {
+ readCollections.BlockToCollectionIndices[block] =
+ append(readCollections.BlockToCollectionIndices[block], collectionIndex)
+ storedReplication := readCollections.BlockToReplication[block]
+ if coll.ReplicationLevel > storedReplication {
+ readCollections.BlockToReplication[block] = coll.ReplicationLevel
+ }
+ }
+ }
+
+ if arvLogger != nil {
+ arvLogger.Update(func(p map[string]interface{}, e map[string]interface{}) {
+ collectionInfo := logger.GetOrCreateMap(p, "collection_info")
+ // Since maps are shallow copied, we run a risk of concurrent
+ // updates here. By copying results.OwnerToCollectionSize into
+ // the log, we're assuming that it won't be updated.
+ collectionInfo["owner_to_collection_size"] =
+ readCollections.OwnerToCollectionSize
+ collectionInfo["distinct_blocks_named"] =
+ len(readCollections.BlockToReplication)
+ })