public class RocksDbMetricsWriter extends Object implements Runnable, AutoCloseable
Class designed to perform all metrics inserts into RocksDB. Metrics are processed from a blocking queue. Inserts to RocksDB are done using a single thread to simplify design (such as looking up existing metric data for aggregation, and fetching/evicting metadata from the cache). This class is not thread safe.A writable LRU StringMetadataCache is used to minimize looking up metadata string Ids. As entries are added to the full cache, older entries are evicted from the cache and need to be written to the database. This happens as the handleEvictedMetadata() method callback. The following issues would need to be addressed to implement a multithreaded metrics writer:
|Modifier and Type
|Method and Description
Run routine to wait for metrics on a queue and insert into RocksDB.
Copyright © 2022 The Apache Software Foundation. All rights reserved.