Bug 232928 - NetWorkCache size more than 1GB
Summary: NetWorkCache size more than 1GB
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Local Build
Hardware: iPhone / iPad Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-11-10 01:13 PST by pi He
Modified: 2021-11-17 01:14 PST (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pi He 2021-11-10 01:13:30 PST
source code In WebKit/NetworkProcess/NetworkCacheStorage.cpp Line 1142:

        if (approximateSize() > m_capacity)
              shrink();

and m_capacity MAX_SIZE is 1 * GB, but, my log shows that the size of this folder is nearly 2GB, I want to know the reason. THANKS!
Comment 1 pi He 2021-11-10 01:33:55 PST
sorry, my log shows that the size of this folder is nearly 1266MB, not 2GB
Comment 2 Antti Koivisto 2021-11-10 09:47:30 PST
The capacity computation is not exact, 1.2GB is not too far. Also the cache uses hard links and depending on how you measure the size it is easy to double count entries.
Comment 3 pi He 2021-11-10 23:05:17 PST
(In reply to Antti Koivisto from comment #2)
> The capacity computation is not exact, 1.2GB is not too far. Also the cache
> uses hard links and depending on how you measure the size it is easy to
> double count entries.

Thanks!There are two pieces of abnormal data in my logs. They show that the size of the 'Version 16/Records' folder is 2.5GB and 4.2GB respectively, while the size of their corresponding fields folder 'Version 16/Blods' is 4.6GB and 8.6GB respectively. These data are far greater than 1GB. I'm not sure if this is real data or dirty data. Do you know why? THANKS!
Comment 4 Radar WebKit Bug Importer 2021-11-17 01:14:30 PST
<rdar://problem/85494718>