Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up options used in store/tikv #24302

Closed
23 tasks done
Tracked by #22513
disksing opened this issue Apr 26, 2021 · 0 comments
Closed
23 tasks done
Tracked by #22513

Clean up options used in store/tikv #24302

disksing opened this issue Apr 26, 2021 · 0 comments
Labels
type/enhancement The issue or PR belongs to an enhancement.

Comments

@disksing
Copy link
Contributor

disksing commented Apr 26, 2021

This is a tracking issue of the big task #22513


The options (store/tikv/kv/option.go) have now been moved to store/tikv. However, this usage pattern of options was created due to the limitations of TiDB and now we have a large number of direct references to these enumerations in other packages of tidb. We would like to move the usage of options out of store/tikv.

Specifically we need to:

  • Use concrete member variables instead of values in map of interface{}
  • Use a concrete method for setting the option
  • Ensure that the option eum are only used in tidb (not in store/tikv)
  • Adapt options to concrete variables in store/driver/txn.

You may refer to the technique we used in #23873 as an example.

  • BinlogInfo
  • SchemaChecker
  • IsolationLevel
  • Priority
  • NotFillCache
  • SyncLog
  • KeyOnly
  • Pessimistic
  • SnapshotTS
  • ReplicaRead
  • TaskID
  • InfoSchema
  • CollectRuntimeStats
  • SchemaAmender
  • SampleStep
  • CommitHook
  • EnableAsyncCommit
  • Enable1PC
  • GuaranteeLinearizability
  • TxnScope
  • IsStalenessReadOnly
  • MatchStoreLabels
  • KVFilter
@disksing disksing added the type/enhancement The issue or PR belongs to an enhancement. label Apr 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement The issue or PR belongs to an enhancement.
Projects
None yet
Development

No branches or pull requests

1 participant