Change default stats reporting endpoint (#3007)

It's the same instance we report to, only using the subdomain.
This commit is contained in:
Till 2023-03-10 12:27:08 +01:00 committed by GitHub
parent c7303cbf76
commit 689b5ee72f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 2 deletions

View File

@ -95,7 +95,7 @@ global:
# We use this information to understand how Dendrite is being used in the wild.
report_stats:
enabled: false
endpoint: https://matrix.org/report-usage-stats/push
endpoint: https://panopticon.matrix.org/push
# Server notices allows server admins to send messages to all users on the server.
server_notices:

View File

@ -319,10 +319,15 @@ type ReportStats struct {
func (c *ReportStats) Defaults() {
c.Enabled = false
c.Endpoint = "https://matrix.org/report-usage-stats/push"
c.Endpoint = "https://panopticon.matrix.org/push"
}
func (c *ReportStats) Verify(configErrs *ConfigErrors) {
// We prefer to hit panopticon (https://github.com/matrix-org/panopticon) directly over
// the "old" matrix.org endpoint.
if c.Endpoint == "https://matrix.org/report-usage-stats/push" {
c.Endpoint = "https://panopticon.matrix.org/push"
}
if c.Enabled {
checkNotEmpty(configErrs, "global.report_stats.endpoint", c.Endpoint)
}