Skip to content

Conversation

@TheDivic
Copy link
Contributor

📖 Context

Type of change

  • Non-breaking change (backwards compatible)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Why are we doing this?

This enhancement aims to reduce unnecessary RPC calls and improve resource utilization by adapting caching strategies to actual network usage.

What did we do?

  • Implemented the ActivityTracker class to monitor network activity per chain and optimize RPC call frequency.
  • Added methods to record activity, retrieve activity levels, and recommend caching intervals based on usage patterns.
  • Created unit tests for ActivityTracker to ensure correct functionality of activity recording and interval recommendations.
  • Integrated ActivityTracker into GasPriceService and CacheFeesJob to dynamically adjust caching intervals based on recorded activity.

How Has This Been Tested?

  • Covered with unit tests

…work activity

- Implemented the ActivityTracker class to monitor network activity per chain and optimize RPC call frequency.
- Added methods to record activity, retrieve activity levels, and recommend caching intervals based on usage patterns.
- Created unit tests for ActivityTracker to ensure correct functionality of activity recording and interval recommendations.
- Integrated ActivityTracker into GasPriceService and CacheFeesJob to dynamically adjust caching intervals based on recorded activity.

This enhancement aims to reduce unnecessary RPC calls and improve resource utilization by adapting caching strategies to actual network usage.
@TheDivic TheDivic self-assigned this Apr 29, 2025
@TheDivic TheDivic added the ⬆️ Enhancement Enhancement to an existing feature or capability label Apr 29, 2025
Comment on lines +24 to +25
log.info(`Decrypted config: ${JSON.stringify(decryptedConfig)}`);

Copy link
Contributor

Choose a reason for hiding this comment

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

Why do we need to log the decrypted config ? This will expose the encrypted data to logs

Copy link
Contributor

@vr16x vr16x left a comment

Choose a reason for hiding this comment

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

All looks good for me. Except logging the decrypted data to logs

@TheDivic
Copy link
Contributor Author

TheDivic commented May 1, 2025

All looks good for me. Except logging the decrypted data to logs

Nice catch, I was having some problems with that so I added a debug statement and forgot to delete it

@vr16x
Copy link
Contributor

vr16x commented May 1, 2025

@TheDivic Are you pushing the change for this ?

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

Labels

⬆️ Enhancement Enhancement to an existing feature or capability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants