mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-20 05:13:11 -06:00
Fix comments, don't use federation sender URL in polylith mode
This commit is contained in:
parent
e182cb524c
commit
11de37e2a7
|
|
@ -154,11 +154,11 @@ func (b *BaseDendrite) CreateHTTPFederationSenderAPIs() federationSenderAPI.Fede
|
|||
return f
|
||||
}
|
||||
|
||||
// CreateHTTPFederationSenderAPIs returns FederationSenderInternalAPI for hitting
|
||||
// the federation sender over HTTP
|
||||
// CreateHTTPServerKeyAPIs returns ServerKeyInternalAPI for hitting the server key
|
||||
// API over HTTP
|
||||
func (b *BaseDendrite) CreateHTTPServerKeyAPIs() serverKeyAPI.ServerKeyInternalAPI {
|
||||
f, err := serverKeyAPI.NewServerKeyInternalAPIHTTP(
|
||||
b.Cfg.FederationSenderURL(),
|
||||
b.Cfg.ServerKeyAPIURL(),
|
||||
b.httpClient,
|
||||
b.ImmutableCache,
|
||||
)
|
||||
|
|
|
|||
|
|
@ -753,6 +753,15 @@ func (config *Dendrite) FederationSenderURL() string {
|
|||
return "http://" + string(config.Listen.FederationSender)
|
||||
}
|
||||
|
||||
// FederationSenderURL returns an HTTP URL for where the federation sender is listening.
|
||||
func (config *Dendrite) ServerKeyAPIURL() string {
|
||||
// Hard code the server key API server to talk HTTP for now.
|
||||
// If we support HTTPS we need to think of a practical way to do certificate validation.
|
||||
// People setting up servers shouldn't need to get a certificate valid for the public
|
||||
// internet for an internal API.
|
||||
return "http://" + string(config.Listen.ServerKeyAPI)
|
||||
}
|
||||
|
||||
// SetupTracing configures the opentracing using the supplied configuration.
|
||||
func (config *Dendrite) SetupTracing(serviceName string) (closer io.Closer, err error) {
|
||||
if !config.Tracing.Enabled {
|
||||
|
|
|
|||
Loading…
Reference in a new issue