Skip to content

Commit

Permalink
Filter out /info requests from Telemetry (#3950)
Browse files Browse the repository at this point in the history
This endpoint is now being polled by the developer portal, so it'd be good to remove the noise from App Insights + Sentry.
  • Loading branch information
marcus-bcl authored Jun 26, 2024
1 parent 8314e4e commit 5725938
Show file tree
Hide file tree
Showing 48 changed files with 518 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ import org.springframework.context.annotation.Configuration
class SentryConfig {
@Bean
fun ignoreHealthRequests() = SentryOptions.BeforeSendTransactionCallback { transaction, _ ->
transaction.transaction?.let { if (it.startsWith("GET /health")) null else transaction }
transaction.transaction?.let { if (it.startsWith("GET /health") or it.startsWith("GET /info")) null else transaction }
}
}
11 changes: 11 additions & 0 deletions projects/accredited-programmes-and-oasys/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/approved-premises-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/approved-premises-and-oasys/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/arns-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/assessment-summary-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/cas2-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/cas3-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/core-person-record-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/court-case-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/custody-key-dates-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/domain-events-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/dps-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/external-api-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/hdc-licences-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/hmpps-auth-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/make-recall-decisions-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/manage-offences-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/manage-pom-cases-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
11 changes: 11 additions & 0 deletions projects/manage-supervision-and-delius/applicationinsights.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,17 @@
],
"percentage": 0
},
{
"telemetryType": "request",
"attributes": [
{
"key": "http.url",
"value": "https?://[^/]+/info/?.*",
"matchType": "regexp"
}
],
"percentage": 0
},
{
"telemetryType": "dependency",
"attributes": [
Expand Down
Loading

0 comments on commit 5725938

Please sign in to comment.