Skip to content

Conversation

@aduffeck
Copy link

Cache internal path and the disabled flag on node object, sparing lots of requests to the ID cache (nats by default).

Caching the internal path also prevents nodes from changing their identity mid-flight, e.g. when assimilation alters the cache in the background.

Speeds up directory listings with posix fs by a factor of 2-3 on my machine.

InternalPath() is called multiple times during the lifetime of node
objects. For space root nodes it's even called once per child when
listing a dir, causing a huge amount of calls to the cache in case
of the posix driver.
It is used a lot for spaceroot nodes and is relatively expensive.
@aduffeck aduffeck changed the title Cache internal path Cache internal path and disabled flag Mar 31, 2025
@aduffeck aduffeck merged commit b5c7cbc into opencloud-eu:main Apr 1, 2025
14 checks passed
@aduffeck aduffeck deleted the cache-internal-path branch April 1, 2025 09:30
@openclouders openclouders mentioned this pull request Apr 1, 2025
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants