nghttpx: Set client_handler to special frontend objects
This commit is contained in:
parent
e9465f0ee5
commit
62411f5a6e
|
@ -902,10 +902,16 @@ ClientHandler::get_downstream_connection(int &err, Downstream *downstream) {
|
||||||
err = 0;
|
err = 0;
|
||||||
|
|
||||||
switch (faddr_->alt_mode) {
|
switch (faddr_->alt_mode) {
|
||||||
case UpstreamAltMode::API:
|
case UpstreamAltMode::API: {
|
||||||
return std::make_unique<APIDownstreamConnection>(worker_);
|
auto dconn = std::make_unique<APIDownstreamConnection>(worker_);
|
||||||
case UpstreamAltMode::HEALTHMON:
|
dconn->set_client_handler(this);
|
||||||
return std::make_unique<HealthMonitorDownstreamConnection>();
|
return dconn;
|
||||||
|
}
|
||||||
|
case UpstreamAltMode::HEALTHMON: {
|
||||||
|
auto dconn = std::make_unique<HealthMonitorDownstreamConnection>();
|
||||||
|
dconn->set_client_handler(this);
|
||||||
|
return dconn;
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue