chromium/third_party/grpc/src/src/core/ext/filters/client_channel/resolver/dns/native/dns_resolver.cc

//
// Copyright 2015 gRPC authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

#include <grpc/support/port_platform.h>

#include <algorithm>
#include <memory>
#include <string>
#include <utility>
#include <vector>

#include "absl/functional/bind_front.h"
#include "absl/status/status.h"
#include "absl/status/statusor.h"
#include "absl/strings/str_cat.h"
#include "absl/strings/string_view.h"
#include "absl/strings/strip.h"
#include "absl/types/optional.h"

#include <grpc/grpc.h>
#include <grpc/support/log.h>

#include "src/core/ext/filters/client_channel/resolver/dns/dns_resolver_selection.h"
#include "src/core/ext/filters/client_channel/resolver/polling_resolver.h"
#include "src/core/lib/backoff/backoff.h"
#include "src/core/lib/channel/channel_args.h"
#include "src/core/lib/config/core_configuration.h"
#include "src/core/lib/debug/trace.h"
#include "src/core/lib/gpr/string.h"
#include "src/core/lib/gprpp/debug_location.h"
#include "src/core/lib/gprpp/global_config_generic.h"
#include "src/core/lib/gprpp/memory.h"
#include "src/core/lib/gprpp/orphanable.h"
#include "src/core/lib/gprpp/ref_counted_ptr.h"
#include "src/core/lib/gprpp/time.h"
#include "src/core/lib/iomgr/resolve_address.h"
#include "src/core/lib/iomgr/resolved_address.h"
#include "src/core/lib/resolver/resolver.h"
#include "src/core/lib/resolver/resolver_factory.h"
#include "src/core/lib/resolver/server_address.h"
#include "src/core/lib/uri/uri_parser.h"

#define GRPC_DNS_INITIAL_CONNECT_BACKOFF_SECONDS
#define GRPC_DNS_RECONNECT_BACKOFF_MULTIPLIER
#define GRPC_DNS_RECONNECT_MAX_BACKOFF_SECONDS
#define GRPC_DNS_RECONNECT_JITTER

namespace grpc_core {

namespace {

TraceFlag grpc_trace_dns_resolver(false, "dns_resolver");

class NativeClientChannelDNSResolver : public PollingResolver {};

NativeClientChannelDNSResolver::NativeClientChannelDNSResolver(
    ResolverArgs args, Duration min_time_between_resolutions)
    :{}

NativeClientChannelDNSResolver::~NativeClientChannelDNSResolver() {}

OrphanablePtr<Orphanable> NativeClientChannelDNSResolver::StartRequest() {}

void NativeClientChannelDNSResolver::OnResolved(
    absl::StatusOr<std::vector<grpc_resolved_address>> addresses_or) {}

//
// Factory
//

class NativeClientChannelDNSResolverFactory : public ResolverFactory {};

}  // namespace

void RegisterNativeDnsResolver(CoreConfiguration::Builder* builder) {}

}  // namespace grpc_core