Add thread safety explanation to RegoinCache's comment (#362)

Signed-off-by: MyonKeminta <MyonKeminta@users.noreply.github.com>

Co-authored-by: MyonKeminta <MyonKeminta@users.noreply.github.com>
This commit is contained in:
MyonKeminta 2021-11-01 14:43:36 +08:00 committed by GitHub
parent 9ec50224be
commit 5a13df80a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -329,6 +329,8 @@ func (r *Region) isValid() bool {
}
// RegionCache caches Regions loaded from PD.
// All public methods of this struct should be thread-safe, unless explicitly pointed out or the method is for testing
// purposes only.
type RegionCache struct {
pdClient pd.Client
enableForwarding bool