You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
1.2 KiB
35 lines
1.2 KiB
#include <iostream> |
|
#include <cstdlib> |
|
|
|
#include "api/cds.pb.h" |
|
#include "api/eds.pb.h" |
|
#include "api/hds.pb.h" |
|
#include "api/lds.pb.h" |
|
#include "api/rlds.pb.h" |
|
#include "api/rds.pb.h" |
|
|
|
// Basic C++ build/link validation for the v2 xDS APIs. |
|
int main(int argc, char *argv[]) { |
|
const auto methods = { |
|
"envoy.api.v2.ClusterDiscoveryService.FetchClusters", |
|
"envoy.api.v2.ClusterDiscoveryService.StreamClusters", |
|
"envoy.api.v2.EndpointDiscoveryService.FetchEndpoints", |
|
"envoy.api.v2.EndpointDiscoveryService.StreamEndpoints", |
|
"envoy.api.v2.HealthDiscoveryService.FetchHealthCheck", |
|
"envoy.api.v2.HealthDiscoveryService.StreamHealthCheck", |
|
"envoy.api.v2.ListenerDiscoveryService.FetchListeners", |
|
"envoy.api.v2.ListenerDiscoveryService.StreamListeners", |
|
"envoy.api.v2.RouteDiscoveryService.FetchRoutes", |
|
"envoy.api.v2.RouteDiscoveryService.StreamRoutes", |
|
"envoy.api.v2.RateLimitDiscoveryService.ShouldRateLimit", |
|
}; |
|
|
|
for (const auto& method : methods) { |
|
if (google::protobuf::DescriptorPool::generated_pool()->FindMethodByName(method) == nullptr) { |
|
std::cout << "Unable to find method descriptor for " << method << std::endl; |
|
exit(EXIT_FAILURE); |
|
} |
|
} |
|
|
|
exit(EXIT_SUCCESS); |
|
}
|
|
|