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

GrainDirectoryOptions are ignored when using IGrainDirectory #8843

Closed
Mostafa-Goher opened this issue Feb 7, 2024 · 1 comment
Closed

GrainDirectoryOptions are ignored when using IGrainDirectory #8843

Mostafa-Goher opened this issue Feb 7, 2024 · 1 comment

Comments

@Mostafa-Goher
Copy link
Contributor

Hello
For certain grain types, we use Redis as a GrainDirectory which forces GrainLocatorResolver to use CachedGrainLocator in which there is a hardcoded LRUBasedGrainDirectoryCache with a hardcoded GrainDirectoryOptions
and that is problematic as the current LRU implementation has an issue, see #8736.

We would like to add a custom implementation of IGrainDirectoryCache to work around the current issue with LRU. However, as far as I can see, that is not possible with a non-default grain directory.

Proposed solution:
Use GrainDirectoryCacheFactory.CreateGrainDirectoryCache to construct the IGrainDirectoryCache in CachedGrainLocator similar to LocalGrainDirectory

Thanks in advance

@Mostafa-Goher
Copy link
Contributor Author

I also noticed the metric orleans-directory-cache-size.Current only works with the default grain directory, my guess by design? then maybe the name can be more explicit?

@github-actions github-actions bot locked and limited conversation to collaborators Apr 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant