func (i *ConnectionInfo) AddMessageTokens(delta map[string]uint64) {
	i.messageTokensLock.Lock()
	defer i.messageTokensLock.Unlock()
	if i.messageTokens == nil {
		i.messageTokens = make(map[string]uint64)
	}
	for k, v := range delta {
		i.messageTokens[k] += v
	}
}
AddMessageTokens changes the tokens available count according
to the provided delta.
package comms
import (
	"crypto"
	"errors"
	"net"
	"sync"
	"time"
	"context"
	log "github.com/golang/glog"
	"github.com/google/fleetspeak/fleetspeak/src/common"
	"github.com/google/fleetspeak/fleetspeak/src/server/authorizer"
	"github.com/google/fleetspeak/fleetspeak/src/server/db"
	"github.com/google/fleetspeak/fleetspeak/src/server/stats"
	fspb "github.com/google/fleetspeak/fleetspeak/src/common/proto/fleetspeak"
)
type Communicator interface {
	Setup(Context) error  
	Start() error         
	Stop()                
}
type ClientInfo struct {
	ID          common.ClientID
	Key         crypto.PublicKey
	Labels      []*fspb.Label
	Blacklisted bool
	Cached      bool  
}
type ConnectionInfo struct {
	Addr                     net.Addr
	Client                   ClientInfo
	ContactID                db.ContactID
	NonceSent, NonceReceived uint64
	AuthClientInfo           authorizer.ClientInfo
	messageTokens     map[string]uint64
	messageTokensLock sync.RWMutex
	Notices <-chan struct{}  
	Fin     func()           
}
func (i *ConnectionInfo) MessageTokens() map[string]uint64 {
	i.messageTokensLock.RLock()
	defer i.messageTokensLock.RUnlock()
	if i.messageTokens == nil {
		return nil
	}
	ret := make(map[string]uint64)
	for k, v := range i.messageTokens {
		ret[k] = v
	}
	return ret
}