client-java icon indicating copy to clipboard operation
client-java copied to clipboard

Checklist items on performance and thread model

Open ilovesoup opened this issue 7 years ago • 0 comments

We need to make sure:

  • [x] How is the client suppose to use? One RawKVClient per thread or shared among threads? (if thread-safe? If not, we need to document this explicitly. If we prefer it to be one per thread, we need to check if static / global caches is correctly guarded)
  • [x] Before this codebase separated from TiSpark repo, some design assumes client is used in a low TPS circumstance. These design include create regionStoreClient per call (although connection is cached globally); global connection cache is guarded in a very coarse grained way; PD Cache is guarded in a coarse way; Object is created like wild which increase GC pressure. We need to exam those design and see if they slow down perf.
  • [ ] Discuss if we need to support an async sets of API? Likely not recently.

ilovesoup avatar Dec 18 '18 17:12 ilovesoup