mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-20 05:13:11 -06:00
Updates
This commit is contained in:
parent
e2d9f86569
commit
566d37ec01
|
|
@ -72,15 +72,11 @@ func createFederationClient(
|
||||||
yggdialerctx := func(ctx context.Context, network, address string) (net.Conn, error) {
|
yggdialerctx := func(ctx context.Context, network, address string) (net.Conn, error) {
|
||||||
return yggdialer(network, address)
|
return yggdialer(network, address)
|
||||||
}
|
}
|
||||||
|
tr := &http.Transport{}
|
||||||
tr := &http.Transport{
|
|
||||||
MaxConnsPerHost: 1,
|
|
||||||
}
|
|
||||||
tr.RegisterProtocol(
|
tr.RegisterProtocol(
|
||||||
"matrix", &yggroundtripper{
|
"matrix", &yggroundtripper{
|
||||||
inner: &http.Transport{
|
inner: &http.Transport{
|
||||||
DialContext: yggdialerctx,
|
DialContext: yggdialerctx,
|
||||||
MaxConnsPerHost: 1,
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -1,32 +0,0 @@
|
||||||
package yggconn
|
|
||||||
|
|
||||||
import (
|
|
||||||
"github.com/libp2p/go-yamux"
|
|
||||||
)
|
|
||||||
|
|
||||||
type stream struct {
|
|
||||||
*yamux.Stream
|
|
||||||
//conn net.Conn
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
func (c *stream) LocalAddr() net.Addr {
|
|
||||||
return c.LocalAddr()
|
|
||||||
}
|
|
||||||
|
|
||||||
func (c *stream) RemoteAddr() net.Addr {
|
|
||||||
return c.conn.RemoteAddr()
|
|
||||||
}
|
|
||||||
|
|
||||||
func (c *stream) SetDeadline(t time.Time) error {
|
|
||||||
return c.conn.SetDeadline(t)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (c *stream) SetReadDeadline(t time.Time) error {
|
|
||||||
return c.conn.SetReadDeadline(t)
|
|
||||||
}
|
|
||||||
|
|
||||||
func (c *stream) SetWriteDeadline(t time.Time) error {
|
|
||||||
return c.conn.SetWriteDeadline(t)
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
Loading…
Reference in a new issue