Skip to content

Commit

Permalink
WWT.Web: don't report missing tour blobs as App Insights errors
Browse files Browse the repository at this point in the history
Relevant to WorldWideTelescope#276. This is external user input so there will be bogus
values.
  • Loading branch information
pkgw committed Mar 26, 2021
1 parent ffc9889 commit b7f5e8a
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions src/WWT.Web/WwtTelemetryProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,19 @@ private void MaybeModify(ITelemetry item)
if (dep == null)
return;

// Don't report missing thumbnails as App Insights errors. That's
// just how our system works. The docs for `DependencyTelemetry` are
// not helpful on their own, but you can go into the Azure Logs
// interface for App Insights and do queries on the `dependencies`
// table to see what fields correspond to what UI elements.
// Don't report missing thumbnails or tours as App Insights errors.
// That's just how our system works. The docs for
// `DependencyTelemetry` are not helpful on their own, but you can
// go into the Azure Logs interface for App Insights and do queries
// on the `dependencies` table to see what fields correspond to what
// UI elements.

if (dep.ResultCode == "404" && dep.Data.StartsWith("https://wwtfiles.blob.core.windows.net/thumbnails/"))
dep.Success = true;

if (dep.ResultCode == "404" && dep.Data.StartsWith("https://wwtfiles.blob.core.windows.net/coretours/"))
dep.Success = true;

if (dep.Name == "BlobBaseClient.Exists")
// Unfortunately I don't see a way to make this filter more specific.
dep.Success = true;
Expand Down

0 comments on commit b7f5e8a

Please sign in to comment.