dataRetrieval
dataRetrieval copied to clipboard
user-friendly chunking of service calls?
In order to make it more common for supporting smaller, more manageable queries and then aggregating them on the client side, I wonder if it is within scope to support a few chunking options in WQP calls, such as time or space. An example of this would be:
readWQPdata(statecode="US:MN", siteType="Lake, Reservoir, Impoundment",
characteristicName=charName, startDateLo='01-01-1990', startDateHi='12-31-2010', timeChunk='5y')
Not sure about the syntax, but a way to have an individual aggregate call that is too big automatically handled by a chunking feature within dataRet. So this particular example would call readWQPdata
5 times using intervals of 5 years to set startDateHi
and startDateLo
values, and then bind them and return the full result to the user.
Would this be better as a blog example?
maybe?
On second thought....you could use the header response to decide if splitting up the calls would make sense. Especially WQP
agreed. My thoughts are that you need maybe a bit too much insider knowledge to use the WQP service calls right now. without calls getting out of hand.
Revisit after POST + sampling activity work to see if still necessary.
Ask WQP team if there's an optimal way to do things.