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

feature gate metrics usage in program-runtime #3477

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

kevinheavey
Copy link

@kevinheavey kevinheavey commented Nov 5, 2024

Problem

solana-program-runtime has an annoying solana-metrics dependency that severely impacts build time and dependency hell. It's particularly annoying for litesvm which depends on solana-program-runtime

Summary of Changes

Put solana-metrics behind a feature gate in solana-program-runtime. Activate the metrics feature for crates that should use it

Closes #3390

@buffalojoec
Copy link

@kevinheavey you mentioned doing this doesn't really help your project without breaking up the SVM crate.
#3390 (comment)

Is there another direct reason this change should go into program-runtime?

@kevinheavey
Copy link
Author

Yeah I realised can just copy paste what I need from the svm crate, so this would still be an improvement

@kevinheavey kevinheavey force-pushed the program-runtime-metrics-feature-gate branch from c892653 to 4ec02d1 Compare December 7, 2024 00:34
@kevinheavey kevinheavey requested a review from a team as a code owner December 7, 2024 00:34
@kevinheavey
Copy link
Author

Build times on my machine:

Metrics feature enabled: 31 seconds
Metrics feature disabled: 16 seconds

@kevinheavey kevinheavey force-pushed the program-runtime-metrics-feature-gate branch from 4ec02d1 to fcf7809 Compare December 12, 2024 10:22
@kevinheavey kevinheavey force-pushed the program-runtime-metrics-feature-gate branch from fcf7809 to e9ff84e Compare December 19, 2024 16:58
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