I’m currently using
/service/r2/getstatistic.jsp to get energy generated in watt hours for a range of dates, or for the current day. However, I’m noticing that if I pass the current date to date from and date to (
dt), it sometimes caches data for the current day. For instance, I’ll make a request and it gives me statistical data that was valid 20 minutes ago, but not right now.
Is this a bug in the API, or is
getstatistic not something I should be using for getting real time data? And if it’s not something that should be used for real time data, I think that there should be a note in the API specification that the server caches statistics and that it’s not real time like
I know this is not client side caching because I tested this on two different computers and get the same result. I also tried passing “Cache-Control: no-store” and “Cache-Control: no-cache” for my headers, but that doesn’t seem to do anything.