[skip ci] Add comment for hasSegment (#10293)

Signed-off-by: bigsheeper <yihao.dai@zilliz.com>
pull/10298/head
bigsheeper 2021-10-20 19:25:29 +08:00 committed by GitHub
parent ff4cd4925f
commit 455172202a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -472,6 +472,7 @@ func (colReplica *collectionReplica) getSegmentByIDPrivate(segmentID UniqueID) (
return segment, nil
}
// hasSegment returns true if collectionReplica has the segment, false otherwise
func (colReplica *collectionReplica) hasSegment(segmentID UniqueID) bool {
colReplica.mu.RLock()
defer colReplica.mu.RUnlock()