forked from envoyproxy/envoy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstance_impl.cc
25 lines (20 loc) · 941 Bytes
/
instance_impl.cc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#include "source/server/instance_impl.h"
#include "source/server/guarddog_impl.h"
#include "source/server/overload_manager_impl.h"
namespace Envoy {
namespace Server {
void InstanceImpl::maybeCreateHeapShrinker() {
heap_shrinker_ =
std::make_unique<Memory::HeapShrinker>(dispatcher(), overloadManager(), *stats().rootScope());
}
std::unique_ptr<OverloadManager> InstanceImpl::createOverloadManager() {
return std::make_unique<OverloadManagerImpl>(
dispatcher(), *stats().rootScope(), threadLocal(), bootstrap().overload_manager(),
messageValidationContext().staticValidationVisitor(), api(), options());
}
std::unique_ptr<Server::GuardDog> InstanceImpl::maybeCreateGuardDog(absl::string_view name) {
return std::make_unique<Server::GuardDogImpl>(*stats().rootScope(),
config().mainThreadWatchdogConfig(), api(), name);
}
} // namespace Server
} // namespace Envoy