fix: modbus/read service cache key ignores read parameters (#32499)

This commit is contained in:
github-actions[bot] 2026-08-04 06:57:21 +00:00 • committed by GitHub
parent 7f2aee0725
commit 4635fe04dd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -68,8 +68,8 @@ func modbusRead(w http.ResponseWriter, req *http.Request) {
return
}
// Create cache key from connection string and register address
cacheKey := fmt.Sprintf("%s:%s:%d", query.URI, query.Device, query.Address)
// Cache per exact request: distinct id/encoding/scale/resulttype must not share a converted value
cacheKey := req.URL.Query().Encode()
// Check cache first
mu.RLock()