Update GC tests with amended metrics#89
Conversation
Metadata now published directly on +/a/wis2/+/metadata topic GC metrics updated as per PR wmo-im/wis2-metric-hierarchy#55 Fixed 2 errors: Test "Data Integrity Check Failure" ... metric `wmo_wis2_gc_downloaded_errors_total` should not be incremented when there's an integrity check fail - the download was fine. Test "WIS2 Notification Message Deduplication (Alternative 1)" ... metric `wmo_wis2_gc_downloaded_errors_total` should have been "unchanged" because there aren't any download errors in this test. Signed-off-by: Jeremy Tandy <jeremy.tandy@gmail.com>
|
Hi @golfvert and @tomkralidis - please would you check and merge this change. The PR comment is descriptive. I want to refer to these tests during the WIS2 Champions training, so it would be preferable (!) for them to be correct! |
Adding "unchanged" for `wmo_wis2_gc_downloaded_errors_total` - because this is useful to know. Signed-off-by: Jeremy Tandy <jeremy.tandy@gmail.com>
|
|
||
| ====== Purpose | ||
| Where a Global Cache receives a valid WNM, but is unable to download a data item from the location specified in a notification message (i.e., the source data server), the `metric wmo_wis2_gc_dataserver_status_flag` for the source data server should be set to 0 (zero). | ||
| Where a Global Cache receives a valid WNM, but is unable to download a data item from the location specified in a notification message (i.e., the source data server), the metric `wmo_wis2_gc_download_errors_total` is incremented. |
There was a problem hiding this comment.
There has been a discussion on this... If the http endpoint is unreachable, but, for all messages the content is provided. What do we do ? How to understand "download" here ? For me, getting the data out of the embedded content is a "download". Agree ? If yes, we need to amend the text.
but is unable to download a data item from the location specified
to
but is unable to get the content from WNM or cannot download a data item from the location specified
If both content is false (wrong hash) and download fails. What do we do ?
There was a problem hiding this comment.
I thought that based on the discussion here download meant download. If the GC fails to extract embedded data it should attempt to download from the URL. If that also fails, we increment wmo_wis2_gc_download_errors_total. There's a case (but a pretty small edge case) where there is only embedded data. If this fails, there's no URL to try to download from. Perhaps the lack of a URL should cause the wmo_wis2_gc_download_errors_total metric to be incremented too?
Hmmm. Just realised that I'm not answering the question you're asking: what happens when data is successfully extract from the message but the HTTP resource is unreachable (e.g., it's not on the server, or the server is offline). I think we said this wouldn't trigger an error - because the GCs never attempt the download. If we want to change this, we could force the GCs to do a HTTP HEAD request to see if the resource/server are available but not actually download the data. But this would be a change to the GC behaviour.
Thoughts?
Metadata now published directly on +/a/wis2/+/metadata topic
GC metrics updated as per PR wmo-im/wis2-metric-hierarchy#55
Fixed 2 errors:
Test "Data Integrity Check Failure" ... metric
wmo_wis2_gc_downloaded_errors_totalshould not be incremented when there's an integrity check fail - the download was fine.Test "WIS2 Notification Message Deduplication (Alternative 1)" ... metric
wmo_wis2_gc_downloaded_errors_totalshould have been "unchanged" because there aren't any download errors in this test.