[ 
https://issues.apache.org/jira/browse/FLINK-41696?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18151854#comment-18151854
 ] 

Naveen Joseph commented on FLINK-41696:
---------------------------------------

Re-enabling the check shows that block cache usage regularly exceeds the 200 MB 
limit on CI. E2E group 3 on my fork 
([run|https://github.com/naveencodet/flink/actions/runs/45865136283], Java 17) 
failed 4 of 6 attempts:

||Attempt||Result||Slot 0||Slot 1||
|1|fail|300.4 MB|321.4 MB|
|2|fail|301.7 MB|319.4 MB|
|3|pass|119.0 MB|105.8 MB|
|4|fail|346.9 MB|341.2 MB|
|5|fail|278.4 MB|261.6 MB|
|6|pass|114.9 MB|116.7 MB|

The configured cache per slot is 150 MB as expected. Locally the test peaks at 
~110 MB. CI results are bimodal (~105-120 MB or ~260-350 MB), and in failing 
runs usage stays above the limit for most of the job.

The PR (https://github.com/apache/flink/pull/30157) is in draft until it is 
decided whether the limit/measurement should change or whether this points to a 
RocksDB memory control issue. Related: FLINK-17511 (limit exceeded in 2020, 
when the check still worked).

> RocksDB Memory Management e2e test never checks block cache usage because of 
> metric filter mismatch
> ---------------------------------------------------------------------------------------------------
>
>                 Key: FLINK-41696
>                 URL: https://issues.apache.org/jira/browse/FLINK-41696
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Runtime / State Backends, Tests
>    Affects Versions: 2.3.0, 2.2.1, 1.20.5
>            Reporter: Naveen Joseph
>            Priority: Major
>              Labels: pull-request-available
>
> test_rocksdb_state_memory_control.sh configures the slf4j reporter with
> the filter "numRecordsIn,block-cache-usage". RocksDB native metrics are
> registered as "rocksdb.<property>" (RocksDBProperty#ROCKS_DB_PROPERTY_FORMAT),
> and DefaultMetricFilter requires a full match on the metric name, so
> "rocksdb.block-cache-usage" is filtered out and never logged.
> As a result find_max_block_cache_usage always returns 0 and the
> EXPECTED_MAX_MEMORY_USAGE assertion has not been effective since the
> filter was introduced in FLINK-21585. CI logs show
> "Current block cache usage for RocksDB instance in slot was 0" on
> passing runs.
> Fix: include "rocksdb.block-cache-usage" in the filter. Verified locally
> (release-1.20, Java 21): usage is now reported as ~125-129 MB per slot,
> below the 200 MB limit, and the test passes in ~1 minute.
> Found while investigating FLINK-41622.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to