Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix totalMemory calculation used for garbage collection #1658

Closed
kladkogex opened this issue Sep 20, 2023 · 2 comments · Fixed by #1660
Closed

Fix totalMemory calculation used for garbage collection #1658

kladkogex opened this issue Sep 20, 2023 · 2 comments · Fixed by #1660
Assignees

Comments

@kladkogex
Copy link
Collaborator

Total memory calculation in garbage collection loop should not take into account
blockHashes since they are treated separately

To Reproduce
Set cache size to a small value (2000 bytes)
Run the tests in tests/historic_state

SKALED will hang forever in garbage collection while loop

@DmytroNazarenko
Copy link
Collaborator

skaled: 3.17.0-beta.11

@DmytroNazarenko DmytroNazarenko moved this from Ready For Release Candidate to Merged To Release Candidate in SKALE Engineering 🚀 Sep 23, 2023
@EvgeniyZZ EvgeniyZZ moved this from Merged To Release Candidate to QA in SKALE Engineering 🚀 Oct 4, 2023
@oleksandrSydorenkoJ
Copy link

Not reproducible without changing the cache size

3.17.0-beta.12

No crashes or hangs after removing contract with 10k key-value pairs

CacheMemoryM:12349187


2023-10-06 14:01:50.166919   Dropping good txn b3c6d1899eb080dccfb2ce758c2721557d4c19ef983ebe09b8cd768d13a7b880

2023-10-06 14:01:50.166976   m_received = 1459

2023-10-06 14:01:50.167425   Self-destructing#41ef2f90…
2023-10-06 14:01:50.167445   Iterating over the LevelDB prefix: A�/��__1��`�
                                                                            ���
2023-10-06 14:01:50.234165   Self-destruct cleared values:10007

2023-10-06 14:01:50.277758   Block sealed #74704 (#72eaec25…)
2023-10-06 14:01:50.277796   Block stats:BN:74703:BTS:1696600901:TXS:291:HDRS:11:LOGS:10798:SENGS:1:TXRS:10817:BLCKS:3:ACCS:150:BQS:1:BDS:815:TSS:1:UTX:0:VTX:288:CMM:12349187:KDS:51520
2023-10-06 14:01:50.278018   Block 74704 DB usage is 1857. Piece DB usage is 186449812 bytes
2023-10-06 14:01:50.278341   noteChanged: {chain}
2023-10-06 14:01:50.278865   SWT:112:BFT:7993
2023-10-06 14:01:50.278886   Successfully imported 1 of 1 transactions

@EvgeniyZZ EvgeniyZZ moved this from QA to Done in SKALE Engineering 🚀 Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment