if (!listener)
return Empty;
+ String objType = params->Get("type");
+ String objName = params->Get("name");
+
if (!listener->GetAcceptConfig()) {
Log(LogWarning, "ApiListener")
- << "Ignoring config update. '" << listener->GetName() << "' does not accept config.";
+ << "Ignoring config update for object '" << objName << "' of type '" << objType << "'. '" << listener->GetName() << "' does not accept config.";
return Empty;
}
}
/* update the object */
- String objType = params->Get("type");
- String objName = params->Get("name");
int objVersion = Convert::ToLong(params->Get("version"));
ConfigType::Ptr dtype = ConfigType::GetByName(objType);
}
if (ctype == ClientJsonRpc) {
- Log(LogInformation, "ApiListener", "New JSON-RPC client");
+ Log(LogNotice, "ApiListener", "New JSON-RPC client");
JsonRpcConnection::Ptr aclient = new JsonRpcConnection(identity, verify_ok, tlsStream, role);
aclient->Start();
} else
AddAnonymousClient(aclient);
} else {
- Log(LogInformation, "ApiListener", "New HTTP client");
+ Log(LogNotice, "ApiListener", "New HTTP client");
HttpServerConnection::Ptr aclient = new HttpServerConnection(identity, verify_ok, tlsStream);
aclient->Start();
void HttpServerConnection::ProcessMessageAsync(HttpRequest& request)
{
- Log(LogInformation, "HttpServerConnection", "Processing Http message");
-
String auth_header = request.Headers->Get("authorization");
String::SizeType pos = auth_header.FindFirstOf(" ");
user.reset();
}
+ Log(LogInformation, "HttpServerConnection")
+ << "Request: " << request.RequestMethod << " " << request.RequestUrl->Format()
+ << " (" << (user ? user->GetName() : "<unauthenticated>") << ")";
+
HttpResponse response(m_Stream, request);
if (!user) {