implement rudimentary caching for yahoo finance to avoid http 429 rate limiting
continuous-integration/drone/push Build is passing

This commit is contained in:
steven committed 2025-05-07 19:59:30 -06:00
1 parent 13291da691
commit 61074bfd80
3 files changed
+31 -5

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
package staticjsonYahooFinance
import (
"time"
)
const cacheAgeSeconds = 900
// intialized in providerImpl.go's Configure
var chartCache map[string]chartCacheEntry
type chartCacheEntry struct {
Chart chartResponse
LastUpdated time.Time
}