diff options
author | Wim <wim@42.be> | 2020-11-22 17:20:20 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-22 17:20:20 +0100 |
commit | eff41759bccd513ecd9af6385534ad3b858e7208 (patch) | |
tree | 0d763d66fa57bc50b45173286dd860153275fb13 | |
parent | c23252ab53182cc6e68086f29c7137fbc27917ee (diff) | |
download | matterbridge-msglm-eff41759bccd513ecd9af6385534ad3b858e7208.tar.gz matterbridge-msglm-eff41759bccd513ecd9af6385534ad3b858e7208.tar.bz2 matterbridge-msglm-eff41759bccd513ecd9af6385534ad3b858e7208.zip |
Add extra debug to log time spent sending a message per bridge (#1299)
-rw-r--r-- | gateway/gateway.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gateway/gateway.go b/gateway/gateway.go index 6a46ecf8..c1440c05 100644 --- a/gateway/gateway.go +++ b/gateway/gateway.go @@ -477,6 +477,10 @@ func (gw *Gateway) SendMessage( gw.Router.MattermostPlugin <- msg } + defer func(t time.Time) { + gw.logger.Debugf("=> Send from %s (%s) to %s (%s) took %s", msg.Account, rmsg.Channel, dest.Account, channel.Name, time.Since(t)) + }(time.Now()) + mID, err := dest.Send(msg) if err != nil { return mID, err |