Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-7275

Prototype lock-free metrics

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: metrics, streams
    • Labels:
      None

      Description

      Currently, we have to be a little conservative in how granularly we measure things to avoid heavy synchronization costs in the metrics.

      It should be possible to refactor the thread-safe implementation to use volatile and java.util.concurrent.atomic instead and realize a pretty large performance improvement.

      However, before investing too much time in it, we should run some benchmarks to gauge how much improvement we can expect.

      I'd propose to run the benchmarks on trunk with debug turned on, and then to just remove all synchronization and run again to get an upper-bound performance improvement.

      If the results are promising, we can start prototyping a lock-free implementation.

        Attachments

          Activity

            People

            • Assignee:
              vvcephei John Roesler
              Reporter:
              vvcephei John Roesler
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: