Add additional debug messages.

This commit is contained in:
Peter Johnson
2015-11-01 22:46:51 -08:00
parent 9200b7c78c
commit 03ee425e5f
3 changed files with 16 additions and 8 deletions

View File

@@ -232,14 +232,15 @@ void DispatcherBase::DispatchThreadMain() {
if (err) WARNING("periodic persistent save: " << err);
}
if (++count > 10) {
DEBUG("dispatch running");
count = 0;
}
{
std::lock_guard<std::mutex> user_lock(m_user_mutex);
bool reconnect = false;
if (++count > 10) {
DEBUG("dispatch running " << m_connections.size() << " connections");
count = 0;
}
for (auto& conn : m_connections) {
// post outgoing messages if connection is active
// only send keep-alives on client
@@ -458,6 +459,7 @@ bool DispatcherBase::ServerHandshake(
if (proto_rev >= 0x0300) conn.set_remote_id(msg->str());
// Set the proto version to the client requested version
DEBUG("server: client protocol " << proto_rev);
conn.set_proto_rev(proto_rev);
// Send initial set of assignments