This archive is retained to ensure existing URLs remain functional. It will not contain any emails sent to this mailing list after July 1, 2024. For all messages, including those sent before and after this date, please visit the new location of the archive at https://mailman.ripe.net/archives/list/ripe-atlas@ripe.net/
[atlas] Feature Request - Atlas Latest
- Previous message (by thread): [atlas] Building a "My Measurement" list via the API
- Next message (by thread): [atlas] Feature Request - Atlas Latest
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
John Bond
mail at johnbond.org
Fri Mar 14 16:34:15 CET 2014
Hello Atlas,
I would like to request an additional API call which just returns the
latest results for a specific measurement. For use cases I would point
you to the "RIPE Atlas - Map Visualisations²[1]. I have also seen places
in the dnsmon beta where you only show the latest results. this would
also be very useful for trouble shooting, if I see an issue its
inconvenient to download xMB of json data just to see the whats going on
now.
An additional feature would be to ask for a result for X seconds in the
past, the call would return a result closest to that time. This is for
investigating historic events, if I have an issue that lasts one hour I
would normally only need one result to perform the initial investigation.
This would also be useful to have a history/timeline function to the
maps[1].
The following code at the end of this mail does something similar to what
I would like using the current API. By setting GO_BACK_IN_TIME=0 you
should get the most recent measurement. However this is not perfect,
depending on what value one sets the INTERVAL do you may get multiple
results or now may get none and as far as I can tell this dose not relate
to the measurement Interval.
The other issue with queuing the results like this is that you get a lot
of superfluous data. I.e. For the dns measurement in the script below you
get result[answers][RDATA] and result-rdata which both seem to have the
same data. Furthermore when in a script im not to interested in the probe
and measurement details. If I am, I will request that information from
the appropriate probe or measurement api call. For the DNS measurement a
structure like the following would suite my needs
{
probe_id: {
abuf: str,
timestamp: int,
result: {
additional: str,
question: str,
authority: str,
opcode: str,
answer: str,
flags: str,
rcode: str,
id: int
},
response_time: float
}
}
Thanks John
#/bin/sh
GO_BACK_IN_TIME=86400
INTERVAL=240
NOW=$(date +%s)
MSG_ID=1423370
URL="https://atlas.ripe.net/api/v1/measurement/${MSG_ID}/result/?stop=$((NO
W - GO_BACK_IN_TIME))&start=$((NOW - GO_BACK_IN_TIME -
FREQUENCY))&format=json"
echo ${URL}
wget -q "${URL}" -O -
[1]https://atlas.ripe.net/results/maps/
- Previous message (by thread): [atlas] Building a "My Measurement" list via the API
- Next message (by thread): [atlas] Feature Request - Atlas Latest
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]