Uploaded image for project: 'ZABBIX FEATURE REQUESTS'
  1. ZABBIX FEATURE REQUESTS
  2. ZBXNEXT-6497

Value cache read/write locking performance

XMLWordPrintable

    • Sprint 73 (Feb 2021), Sprint 74 (Mar 2021), Sprint 75 (Apr 2021), Sprint 76 (May 2021)
    • 2

      Read/write value cache locking would improve value cache concurrent access by history syncers. Currently history syncer locks value cache for every item in trigger expression. While the locks are not long, there are a lot of them. Directly replacing it with read locks is not possible, because of possible history caching and range/statistics updates. Still it could be done with some changes to the processing logic. As the cache is unlocked during database access it would be possible with minor refactoring to first read lock, then if cache update is required, unlock, access database, write lock, update cache. The range/statistics updates could be cached locally and then flushed to cache after the history batch is processed.

      In theory that should improve the value cache concurrency, in practice it's not clear how much improvement it would give.

        1. vcbench.diff
          8 kB
        2. value_cache_rwlock.svg
          16 kB
        3. value_cache_mutex.svg
          11 kB

            wiper Andris Zeila
            wiper Andris Zeila
            Team A
            Votes:
            5 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: