Skip to content

Comments

perf: avoid cloning Filter in cache get_logs#3597

Merged
mattsse merged 1 commit intoalloy-rs:mainfrom
ANtutov:perf/cache-get-logs-filter-borrow
Jan 26, 2026
Merged

perf: avoid cloning Filter in cache get_logs#3597
mattsse merged 1 commit intoalloy-rs:mainfrom
ANtutov:perf/cache-get-logs-filter-borrow

Conversation

@ANtutov
Copy link
Contributor

@ANtutov ANtutov commented Jan 26, 2026

CacheProvider::get_logs was cloning the entire Filter just to build a RequestType for parameter hashing, even though the inner provider already uses a borrowed &Filter. This caused unnecessary allocations and CPU work when hashing log filters.

@github-project-automation github-project-automation bot moved this to Reviewed in Alloy Jan 26, 2026
@mattsse mattsse merged commit b9587ca into alloy-rs:main Jan 26, 2026
30 checks passed
@github-project-automation github-project-automation bot moved this from Reviewed to Done in Alloy Jan 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants