Skip to content

Conversation

@dangershony
Copy link
Member

Not sure if this is very useful really

{
var cacheKey = GetCacheKey(request.ProjectId);

if (memoryCache.TryGetValue(cacheKey, out ProjectStatisticsDto? cachedResult) && cachedResult != null)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should compare the header of the current block to the one we have in the cache instead of just a time limit, so we only refresh if something new happened

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no but we can still get new items in mempool

@dangershony
Copy link
Member Author

Closing this as the latest changes by @SuperJMN made it much more performant

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants