-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
grpc-mux: refactor c'tor arguments (#28781)
Following #28273 this is a cleanup requested to pass c'tor parameters in a single struct. Risk Level: low - refactor Testing: N/A Signed-off-by: Adi Suissa-Peleg <[email protected]>
- Loading branch information
Showing
18 changed files
with
437 additions
and
348 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
source/extensions/config_subscription/grpc/grpc_mux_context.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
#pragma once | ||
|
||
#include "envoy/common/backoff_strategy.h" | ||
#include "envoy/config/custom_config_validators.h" | ||
#include "envoy/config/eds_resources_cache.h" | ||
#include "envoy/config/xds_config_tracker.h" | ||
#include "envoy/config/xds_resources_delegate.h" | ||
#include "envoy/event/dispatcher.h" | ||
#include "envoy/grpc/async_client.h" | ||
#include "envoy/local_info/local_info.h" | ||
#include "envoy/stats/scope.h" | ||
|
||
#include "source/common/config/utility.h" | ||
|
||
namespace Envoy { | ||
namespace Config { | ||
|
||
// Context (data) needed for creating a GrpcMux object. | ||
// These are parameters needed for the creation of all GrpcMux objects. | ||
struct GrpcMuxContext { | ||
Grpc::RawAsyncClientPtr async_client_; | ||
Event::Dispatcher& dispatcher_; | ||
const Protobuf::MethodDescriptor& service_method_; | ||
const LocalInfo::LocalInfo& local_info_; | ||
const RateLimitSettings& rate_limit_settings_; | ||
Stats::Scope& scope_; | ||
CustomConfigValidatorsPtr config_validators_; | ||
XdsResourcesDelegateOptRef xds_resources_delegate_; | ||
XdsConfigTrackerOptRef xds_config_tracker_; | ||
BackOffStrategyPtr backoff_strategy_; | ||
const std::string& target_xds_authority_; | ||
EdsResourcesCachePtr eds_resources_cache_; | ||
}; | ||
|
||
} // namespace Config | ||
} // namespace Envoy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.