You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for creating an issue! Please fill out this form so we can be
sure to have all the information we need, and to minimize back and forth.
What are you trying to do?
Similar to nancy, you can cache the results of reaching out to OSSIndex, to prevent rate limiting. These results should be cached for 12 hours, and then removed from the cache if that TTL has expired.
What feature or behavior is this required for?
It will hopefully help people avoid hitting rate limits.
How could we solve this issue? (Not knowing is okay!)
@jdillon can likely share some info on this, there's a generic implementation for what Jason did with our Java tooling, this can likely follow that.
At a minimum your API probably needs:
Ability to clean the cache (and a new flag for the cli to let someone do this)
An ability to insert an item into the cache (will likely check if it exists before inserting)
An ability to get from the cache (will error if item is expired, so someone knows to update it)
Likely it would be nice to make the TTL configurable, but the default should be 12 hours.
The cache should be saved at ~/.ossindex/cargo-pants so that it's in a common location.
Thanks for creating an issue! Please fill out this form so we can be
sure to have all the information we need, and to minimize back and forth.
Similar to
nancy
, you can cache the results of reaching out to OSSIndex, to prevent rate limiting. These results should be cached for 12 hours, and then removed from the cache if that TTL has expired.It will hopefully help people avoid hitting rate limits.
@jdillon can likely share some info on this, there's a generic implementation for what Jason did with our Java tooling, this can likely follow that.
At a minimum your API probably needs:
Likely it would be nice to make the TTL configurable, but the default should be 12 hours.
The cache should be saved at
~/.ossindex/cargo-pants
so that it's in a common location.Potentially look at: https://docs.rs/pickledb/0.4.1/pickledb/ or https://docs.rs/tinydb/0.0.7/tinydb/
The text was updated successfully, but these errors were encountered: