aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrobot-contrib <robot-contrib@yandex-team.com>2022-12-02 13:24:45 +0300
committerrobot-contrib <robot-contrib@yandex-team.com>2022-12-02 13:24:45 +0300
commit495670c2e9d6c343a0be9c99d5d06963fe410633 (patch)
tree5e8d720a8c6718da4a7b077d6f26dfb1606d7a4b
parent04b9154706b212bfb5eb4dc1cb12a3f52b98756f (diff)
downloadydb-495670c2e9d6c343a0be9c99d5d06963fe410633.tar.gz
Update contrib/libs/googleapis-common-protos to 1.57.0
-rw-r--r--contrib/libs/benchmark/AUTHORS2
-rw-r--r--contrib/libs/benchmark/include/benchmark/benchmark.h24
-rw-r--r--contrib/libs/benchmark/src/benchmark.cc14
-rw-r--r--contrib/libs/benchmark/src/benchmark_name.cc1
-rw-r--r--contrib/libs/benchmark/src/benchmark_register.cc2
-rw-r--r--contrib/libs/benchmark/src/benchmark_register.h1
-rw-r--r--contrib/libs/benchmark/src/benchmark_runner.cc2
-rw-r--r--contrib/libs/benchmark/src/check.cc2
-rw-r--r--contrib/libs/benchmark/src/check.h17
-rw-r--r--contrib/libs/benchmark/src/commandlineflags.cc12
-rw-r--r--contrib/libs/benchmark/src/console_reporter.cc4
-rw-r--r--contrib/libs/benchmark/src/csv_reporter.cc3
-rw-r--r--contrib/libs/benchmark/src/cycleclock.h4
-rw-r--r--contrib/libs/benchmark/src/internal_macros.h4
-rw-r--r--contrib/libs/benchmark/src/json_reporter.cc11
-rw-r--r--contrib/libs/benchmark/src/log.h26
-rw-r--r--contrib/libs/benchmark/src/reporter.cc14
-rw-r--r--contrib/libs/benchmark/src/string_util.h2
-rw-r--r--contrib/libs/benchmark/src/sysinfo.cc58
-rw-r--r--contrib/libs/benchmark/src/timers.cc15
-rw-r--r--contrib/libs/googleapis-common-protos/CHANGELOG.md22
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/auth.proto12
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/backend.proto5
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/client.proto250
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/control.proto14
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/documentation.proto26
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/endpoint.proto23
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/error_reason.proto138
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/launch_stage.proto6
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/metric.proto34
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/monitored_resource.proto11
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/quota.proto12
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/service.proto48
-rw-r--r--contrib/libs/googleapis-common-protos/google/api/visibility.proto20
34 files changed, 702 insertions, 137 deletions
diff --git a/contrib/libs/benchmark/AUTHORS b/contrib/libs/benchmark/AUTHORS
index 7d689350b5..98d2d98b05 100644
--- a/contrib/libs/benchmark/AUTHORS
+++ b/contrib/libs/benchmark/AUTHORS
@@ -50,7 +50,9 @@ Norman Heino <norman.heino@gmail.com>
Oleksandr Sochka <sasha.sochka@gmail.com>
Ori Livneh <ori.livneh@gmail.com>
Paul Redmond <paul.redmond@gmail.com>
+Raghu Raja <raghu@enfabrica.net>
Radoslav Yovchev <radoslav.tm@gmail.com>
+Rainer Orth <ro@cebitec.uni-bielefeld.de>
Roman Lebedev <lebedev.ri@gmail.com>
Sayan Bhattacharjee <aero.sayan@gmail.com>
Shapr3D <google-contributors@shapr3d.com>
diff --git a/contrib/libs/benchmark/include/benchmark/benchmark.h b/contrib/libs/benchmark/include/benchmark/benchmark.h
index b856066561..77dcfbdc2a 100644
--- a/contrib/libs/benchmark/include/benchmark/benchmark.h
+++ b/contrib/libs/benchmark/include/benchmark/benchmark.h
@@ -220,29 +220,18 @@ BENCHMARK(BM_test)->Unit(benchmark::kMillisecond);
#if defined(__GNUC__) || defined(__clang__)
#define BENCHMARK_ALWAYS_INLINE __attribute__((always_inline))
-#define BENCHMARK_NOEXCEPT noexcept
-#define BENCHMARK_NOEXCEPT_OP(x) noexcept(x)
#elif defined(_MSC_VER) && !defined(__clang__)
#define BENCHMARK_ALWAYS_INLINE __forceinline
-#if _MSC_VER >= 1900
-#define BENCHMARK_NOEXCEPT noexcept
-#define BENCHMARK_NOEXCEPT_OP(x) noexcept(x)
-#else
-#define BENCHMARK_NOEXCEPT
-#define BENCHMARK_NOEXCEPT_OP(x)
-#endif
#define __func__ __FUNCTION__
#else
#define BENCHMARK_ALWAYS_INLINE
-#define BENCHMARK_NOEXCEPT
-#define BENCHMARK_NOEXCEPT_OP(x)
#endif
#define BENCHMARK_INTERNAL_TOSTRING2(x) #x
#define BENCHMARK_INTERNAL_TOSTRING(x) BENCHMARK_INTERNAL_TOSTRING2(x)
// clang-format off
-#if defined(__GNUC__) || defined(__clang__)
+#if defined(__GNUC__) && !defined(__NVCC__) || defined(__clang__)
#define BENCHMARK_BUILTIN_EXPECT(x, y) __builtin_expect(x, y)
#define BENCHMARK_DEPRECATED_MSG(msg) __attribute__((deprecated(msg)))
#define BENCHMARK_DISABLE_DEPRECATED_WARNING \
@@ -417,6 +406,8 @@ class Benchmark;
class BenchmarkImp;
class BenchmarkFamilies;
+BENCHMARK_EXPORT std::map<std::string, std::string>*& GetGlobalContext();
+
BENCHMARK_EXPORT
void UseCharPointer(char const volatile*);
@@ -1116,7 +1107,7 @@ class BENCHMARK_EXPORT Benchmark {
// By default, the CPU time is measured only for the main thread, which may
// be unrepresentative if the benchmark uses threads internally. If called,
// the total CPU time spent by all the threads will be measured instead.
- // By default, the only the main thread CPU time will be measured.
+ // By default, only the main thread CPU time will be measured.
Benchmark* MeasureProcessCPUTime();
// If a particular benchmark should use the Wall clock instead of the CPU time
@@ -1543,8 +1534,15 @@ class Fixture : public internal::Benchmark {
#endif
// Helper macro to create a main routine in a test that runs the benchmarks
+// Note the workaround for Hexagon simulator passing argc != 0, argv = NULL.
#define BENCHMARK_MAIN() \
int main(int argc, char** argv) { \
+ char arg0_default[] = "benchmark"; \
+ char* args_default = arg0_default; \
+ if (!argv) { \
+ argc = 1; \
+ argv = &args_default; \
+ } \
::benchmark::Initialize(&argc, argv); \
if (::benchmark::ReportUnrecognizedArguments(argc, argv)) return 1; \
::benchmark::RunSpecifiedBenchmarks(); \
diff --git a/contrib/libs/benchmark/src/benchmark.cc b/contrib/libs/benchmark/src/benchmark.cc
index 6035491413..ff2864804c 100644
--- a/contrib/libs/benchmark/src/benchmark.cc
+++ b/contrib/libs/benchmark/src/benchmark.cc
@@ -19,7 +19,7 @@
#include "internal_macros.h"
#ifndef BENCHMARK_OS_WINDOWS
-#ifndef BENCHMARK_OS_FUCHSIA
+#if !defined(BENCHMARK_OS_FUCHSIA) && !defined(BENCHMARK_OS_QURT)
#include <sys/resource.h>
#endif
#include <sys/time.h>
@@ -137,7 +137,11 @@ BM_DEFINE_int32(v, 0);
namespace internal {
-BENCHMARK_EXPORT std::map<std::string, std::string>* global_context = nullptr;
+std::map<std::string, std::string>* global_context = nullptr;
+
+BENCHMARK_EXPORT std::map<std::string, std::string>*& GetGlobalContext() {
+ return global_context;
+}
// FIXME: wouldn't LTO mess this up?
void UseCharPointer(char const volatile*) {}
@@ -178,7 +182,7 @@ State::State(IterationCount max_iters, const std::vector<int64_t>& ranges,
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Winvalid-offsetof"
#endif
-#if defined(__CUDACC__)
+#if defined(__NVCC__)
#pragma nv_diagnostic push
#pragma nv_diag_suppress 1427
#endif
@@ -192,7 +196,7 @@ State::State(IterationCount max_iters, const std::vector<int64_t>& ranges,
#elif defined(__GNUC__)
#pragma GCC diagnostic pop
#endif
-#if defined(__CUDACC__)
+#if defined(__NVCC__)
#pragma nv_diagnostic pop
#endif
}
@@ -678,9 +682,9 @@ void PrintDefaultHelp() {
}
void Initialize(int* argc, char** argv, void (*HelperPrintf)()) {
+ internal::HelperPrintf = HelperPrintf;
internal::ParseCommandLineFlags(argc, argv);
internal::LogLevel() = FLAGS_v;
- internal::HelperPrintf = HelperPrintf;
}
void Shutdown() { delete internal::global_context; }
diff --git a/contrib/libs/benchmark/src/benchmark_name.cc b/contrib/libs/benchmark/src/benchmark_name.cc
index 4f7386068d..01676bbc84 100644
--- a/contrib/libs/benchmark/src/benchmark_name.cc
+++ b/contrib/libs/benchmark/src/benchmark_name.cc
@@ -51,6 +51,7 @@ std::string join(char delimiter, const Ts&... ts) {
}
} // namespace
+BENCHMARK_EXPORT
std::string BenchmarkName::str() const {
return join('/', function_name, args, min_time, min_warmup_time, iterations,
repetitions, time_type, threads);
diff --git a/contrib/libs/benchmark/src/benchmark_register.cc b/contrib/libs/benchmark/src/benchmark_register.cc
index a42b76689b..eae2c320f6 100644
--- a/contrib/libs/benchmark/src/benchmark_register.cc
+++ b/contrib/libs/benchmark/src/benchmark_register.cc
@@ -15,7 +15,7 @@
#include "benchmark_register.h"
#ifndef BENCHMARK_OS_WINDOWS
-#ifndef BENCHMARK_OS_FUCHSIA
+#if !defined(BENCHMARK_OS_FUCHSIA) && !defined(BENCHMARK_OS_QURT)
#include <sys/resource.h>
#endif
#include <sys/time.h>
diff --git a/contrib/libs/benchmark/src/benchmark_register.h b/contrib/libs/benchmark/src/benchmark_register.h
index a5a250cc70..53367c707c 100644
--- a/contrib/libs/benchmark/src/benchmark_register.h
+++ b/contrib/libs/benchmark/src/benchmark_register.h
@@ -1,6 +1,7 @@
#ifndef BENCHMARK_REGISTER_H
#define BENCHMARK_REGISTER_H
+#include <algorithm>
#include <limits>
#include <vector>
diff --git a/contrib/libs/benchmark/src/benchmark_runner.cc b/contrib/libs/benchmark/src/benchmark_runner.cc
index d30d0449da..f9ffbc5afb 100644
--- a/contrib/libs/benchmark/src/benchmark_runner.cc
+++ b/contrib/libs/benchmark/src/benchmark_runner.cc
@@ -19,7 +19,7 @@
#include "internal_macros.h"
#ifndef BENCHMARK_OS_WINDOWS
-#ifndef BENCHMARK_OS_FUCHSIA
+#if !defined(BENCHMARK_OS_FUCHSIA) && !defined(BENCHMARK_OS_QURT)
#include <sys/resource.h>
#endif
#include <sys/time.h>
diff --git a/contrib/libs/benchmark/src/check.cc b/contrib/libs/benchmark/src/check.cc
index 422b9483a8..5f7526e08d 100644
--- a/contrib/libs/benchmark/src/check.cc
+++ b/contrib/libs/benchmark/src/check.cc
@@ -5,7 +5,7 @@ namespace internal {
static AbortHandlerT* handler = &std::abort;
-AbortHandlerT*& GetAbortHandler() { return handler; }
+BENCHMARK_EXPORT AbortHandlerT*& GetAbortHandler() { return handler; }
} // namespace internal
} // namespace benchmark
diff --git a/contrib/libs/benchmark/src/check.h b/contrib/libs/benchmark/src/check.h
index 1129e81402..c1cd5e85e4 100644
--- a/contrib/libs/benchmark/src/check.h
+++ b/contrib/libs/benchmark/src/check.h
@@ -9,6 +9,23 @@
#include "internal_macros.h"
#include "log.h"
+#if defined(__GNUC__) || defined(__clang__)
+#define BENCHMARK_NOEXCEPT noexcept
+#define BENCHMARK_NOEXCEPT_OP(x) noexcept(x)
+#elif defined(_MSC_VER) && !defined(__clang__)
+#if _MSC_VER >= 1900
+#define BENCHMARK_NOEXCEPT noexcept
+#define BENCHMARK_NOEXCEPT_OP(x) noexcept(x)
+#else
+#define BENCHMARK_NOEXCEPT
+#define BENCHMARK_NOEXCEPT_OP(x)
+#endif
+#define __func__ __FUNCTION__
+#else
+#define BENCHMARK_NOEXCEPT
+#define BENCHMARK_NOEXCEPT_OP(x)
+#endif
+
namespace benchmark {
namespace internal {
diff --git a/contrib/libs/benchmark/src/commandlineflags.cc b/contrib/libs/benchmark/src/commandlineflags.cc
index 9615e351ff..1f555b2757 100644
--- a/contrib/libs/benchmark/src/commandlineflags.cc
+++ b/contrib/libs/benchmark/src/commandlineflags.cc
@@ -121,12 +121,14 @@ static std::string FlagToEnvVar(const char* flag) {
} // namespace
+BENCHMARK_EXPORT
bool BoolFromEnv(const char* flag, bool default_val) {
const std::string env_var = FlagToEnvVar(flag);
const char* const value_str = getenv(env_var.c_str());
return value_str == nullptr ? default_val : IsTruthyFlagValue(value_str);
}
+BENCHMARK_EXPORT
int32_t Int32FromEnv(const char* flag, int32_t default_val) {
const std::string env_var = FlagToEnvVar(flag);
const char* const value_str = getenv(env_var.c_str());
@@ -139,6 +141,7 @@ int32_t Int32FromEnv(const char* flag, int32_t default_val) {
return value;
}
+BENCHMARK_EXPORT
double DoubleFromEnv(const char* flag, double default_val) {
const std::string env_var = FlagToEnvVar(flag);
const char* const value_str = getenv(env_var.c_str());
@@ -151,12 +154,14 @@ double DoubleFromEnv(const char* flag, double default_val) {
return value;
}
+BENCHMARK_EXPORT
const char* StringFromEnv(const char* flag, const char* default_val) {
const std::string env_var = FlagToEnvVar(flag);
const char* const value = getenv(env_var.c_str());
return value == nullptr ? default_val : value;
}
+BENCHMARK_EXPORT
std::map<std::string, std::string> KvPairsFromEnv(
const char* flag, std::map<std::string, std::string> default_val) {
const std::string env_var = FlagToEnvVar(flag);
@@ -201,6 +206,7 @@ const char* ParseFlagValue(const char* str, const char* flag,
return flag_end + 1;
}
+BENCHMARK_EXPORT
bool ParseBoolFlag(const char* str, const char* flag, bool* value) {
// Gets the value of the flag as a string.
const char* const value_str = ParseFlagValue(str, flag, true);
@@ -213,6 +219,7 @@ bool ParseBoolFlag(const char* str, const char* flag, bool* value) {
return true;
}
+BENCHMARK_EXPORT
bool ParseInt32Flag(const char* str, const char* flag, int32_t* value) {
// Gets the value of the flag as a string.
const char* const value_str = ParseFlagValue(str, flag, false);
@@ -225,6 +232,7 @@ bool ParseInt32Flag(const char* str, const char* flag, int32_t* value) {
value);
}
+BENCHMARK_EXPORT
bool ParseDoubleFlag(const char* str, const char* flag, double* value) {
// Gets the value of the flag as a string.
const char* const value_str = ParseFlagValue(str, flag, false);
@@ -237,6 +245,7 @@ bool ParseDoubleFlag(const char* str, const char* flag, double* value) {
value);
}
+BENCHMARK_EXPORT
bool ParseStringFlag(const char* str, const char* flag, std::string* value) {
// Gets the value of the flag as a string.
const char* const value_str = ParseFlagValue(str, flag, false);
@@ -248,6 +257,7 @@ bool ParseStringFlag(const char* str, const char* flag, std::string* value) {
return true;
}
+BENCHMARK_EXPORT
bool ParseKeyValueFlag(const char* str, const char* flag,
std::map<std::string, std::string>* value) {
const char* const value_str = ParseFlagValue(str, flag, false);
@@ -263,10 +273,12 @@ bool ParseKeyValueFlag(const char* str, const char* flag,
return true;
}
+BENCHMARK_EXPORT
bool IsFlag(const char* str, const char* flag) {
return (ParseFlagValue(str, flag, true) != nullptr);
}
+BENCHMARK_EXPORT
bool IsTruthyFlagValue(const std::string& value) {
if (value.size() == 1) {
char v = value[0];
diff --git a/contrib/libs/benchmark/src/console_reporter.cc b/contrib/libs/benchmark/src/console_reporter.cc
index 1711356b9b..3950e49814 100644
--- a/contrib/libs/benchmark/src/console_reporter.cc
+++ b/contrib/libs/benchmark/src/console_reporter.cc
@@ -33,6 +33,7 @@
namespace benchmark {
+BENCHMARK_EXPORT
bool ConsoleReporter::ReportContext(const Context& context) {
name_field_width_ = context.name_field_width;
printed_header_ = false;
@@ -52,6 +53,7 @@ bool ConsoleReporter::ReportContext(const Context& context) {
return true;
}
+BENCHMARK_EXPORT
void ConsoleReporter::PrintHeader(const Run& run) {
std::string str =
FormatString("%-*s %13s %15s %12s", static_cast<int>(name_field_width_),
@@ -69,6 +71,7 @@ void ConsoleReporter::PrintHeader(const Run& run) {
GetOutputStream() << line << "\n" << str << "\n" << line << "\n";
}
+BENCHMARK_EXPORT
void ConsoleReporter::ReportRuns(const std::vector<Run>& reports) {
for (const auto& run : reports) {
// print the header:
@@ -120,6 +123,7 @@ static std::string FormatTime(double time) {
return FormatString("%10.0f", time);
}
+BENCHMARK_EXPORT
void ConsoleReporter::PrintRunData(const Run& result) {
typedef void(PrinterFn)(std::ostream&, LogColor, const char*, ...);
auto& Out = GetOutputStream();
diff --git a/contrib/libs/benchmark/src/csv_reporter.cc b/contrib/libs/benchmark/src/csv_reporter.cc
index 1c5e9fa668..83c94573f5 100644
--- a/contrib/libs/benchmark/src/csv_reporter.cc
+++ b/contrib/libs/benchmark/src/csv_reporter.cc
@@ -52,11 +52,13 @@ std::string CsvEscape(const std::string& s) {
return '"' + tmp + '"';
}
+BENCHMARK_EXPORT
bool CSVReporter::ReportContext(const Context& context) {
PrintBasicContext(&GetErrorStream(), context);
return true;
}
+BENCHMARK_EXPORT
void CSVReporter::ReportRuns(const std::vector<Run>& reports) {
std::ostream& Out = GetOutputStream();
@@ -103,6 +105,7 @@ void CSVReporter::ReportRuns(const std::vector<Run>& reports) {
}
}
+BENCHMARK_EXPORT
void CSVReporter::PrintRunData(const Run& run) {
std::ostream& Out = GetOutputStream();
Out << CsvEscape(run.benchmark_name()) << ",";
diff --git a/contrib/libs/benchmark/src/cycleclock.h b/contrib/libs/benchmark/src/cycleclock.h
index de5e47c548..827f21b927 100644
--- a/contrib/libs/benchmark/src/cycleclock.h
+++ b/contrib/libs/benchmark/src/cycleclock.h
@@ -212,6 +212,10 @@ inline BENCHMARK_ALWAYS_INLINE int64_t Now() {
struct timeval tv;
gettimeofday(&tv, nullptr);
return static_cast<int64_t>(tv.tv_sec) * 1000000 + tv.tv_usec;
+#elif defined(__hexagon__)
+ uint64_t pcycle;
+ asm volatile("%0 = C15:14" : "=r"(pcycle));
+ return static_cast<double>(pcycle);
#else
// The soft failover to a generic implementation is automatic only for ARM.
// For other platforms the developer is expected to make an attempt to create
diff --git a/contrib/libs/benchmark/src/internal_macros.h b/contrib/libs/benchmark/src/internal_macros.h
index 72ba54bad2..396a390afb 100644
--- a/contrib/libs/benchmark/src/internal_macros.h
+++ b/contrib/libs/benchmark/src/internal_macros.h
@@ -1,8 +1,6 @@
#ifndef BENCHMARK_INTERNAL_MACROS_H_
#define BENCHMARK_INTERNAL_MACROS_H_
-#include "benchmark/benchmark.h"
-
/* Needed to detect STL */
#include <cstdlib>
@@ -87,6 +85,8 @@
#define BENCHMARK_OS_QNX 1
#elif defined(__MVS__)
#define BENCHMARK_OS_ZOS 1
+#elif defined(__hexagon__)
+#define BENCHMARK_OS_QURT 1
#endif
#if defined(__ANDROID__) && defined(__GLIBCXX__)
diff --git a/contrib/libs/benchmark/src/json_reporter.cc b/contrib/libs/benchmark/src/json_reporter.cc
index e9999e18ac..d55a0e6f0b 100644
--- a/contrib/libs/benchmark/src/json_reporter.cc
+++ b/contrib/libs/benchmark/src/json_reporter.cc
@@ -28,10 +28,6 @@
#include "timers.h"
namespace benchmark {
-namespace internal {
-extern std::map<std::string, std::string>* global_context;
-}
-
namespace {
std::string StrEscape(const std::string& s) {
@@ -178,8 +174,11 @@ bool JSONReporter::ReportContext(const Context& context) {
#endif
out << indent << FormatKV("library_build_type", build_type);
- if (internal::global_context != nullptr) {
- for (const auto& kv : *internal::global_context) {
+ std::map<std::string, std::string>* global_context =
+ internal::GetGlobalContext();
+
+ if (global_context != nullptr) {
+ for (const auto& kv : *global_context) {
out << ",\n";
out << indent << FormatKV(kv.first, kv.second);
}
diff --git a/contrib/libs/benchmark/src/log.h b/contrib/libs/benchmark/src/log.h
index 48c071aded..45701667a2 100644
--- a/contrib/libs/benchmark/src/log.h
+++ b/contrib/libs/benchmark/src/log.h
@@ -4,7 +4,12 @@
#include <iostream>
#include <ostream>
-#include "benchmark/benchmark.h"
+// NOTE: this is also defined in benchmark.h but we're trying to avoid a
+// dependency.
+// The _MSVC_LANG check should detect Visual Studio 2015 Update 3 and newer.
+#if __cplusplus >= 201103L || (defined(_MSVC_LANG) && _MSVC_LANG >= 201103L)
+#define BENCHMARK_HAS_CXX11
+#endif
namespace benchmark {
namespace internal {
@@ -23,7 +28,16 @@ class LogType {
private:
LogType(std::ostream* out) : out_(out) {}
std::ostream* out_;
- BENCHMARK_DISALLOW_COPY_AND_ASSIGN(LogType);
+
+ // NOTE: we could use BENCHMARK_DISALLOW_COPY_AND_ASSIGN but we shouldn't have
+ // a dependency on benchmark.h from here.
+#ifndef BENCHMARK_HAS_CXX11
+ LogType(const LogType&);
+ LogType& operator=(const LogType&);
+#else
+ LogType(const LogType&) = delete;
+ LogType& operator=(const LogType&) = delete;
+#endif
};
template <class Tp>
@@ -47,13 +61,13 @@ inline int& LogLevel() {
}
inline LogType& GetNullLogInstance() {
- static LogType log(nullptr);
- return log;
+ static LogType null_log((std::ostream*)nullptr);
+ return null_log;
}
inline LogType& GetErrorLogInstance() {
- static LogType log(&std::clog);
- return log;
+ static LogType error_log(&std::clog);
+ return error_log;
}
inline LogType& GetLogInstanceForLevel(int level) {
diff --git a/contrib/libs/benchmark/src/reporter.cc b/contrib/libs/benchmark/src/reporter.cc
index 1d2df17b90..076bc31a2e 100644
--- a/contrib/libs/benchmark/src/reporter.cc
+++ b/contrib/libs/benchmark/src/reporter.cc
@@ -25,9 +25,6 @@
#include "timers.h"
namespace benchmark {
-namespace internal {
-extern std::map<std::string, std::string> *global_context;
-}
BenchmarkReporter::BenchmarkReporter()
: output_stream_(&std::cout), error_stream_(&std::cerr) {}
@@ -39,7 +36,11 @@ void BenchmarkReporter::PrintBasicContext(std::ostream *out,
BM_CHECK(out) << "cannot be null";
auto &Out = *out;
+#ifndef BENCHMARK_OS_QURT
+ // Date/time information is not available on QuRT.
+ // Attempting to get it via this call cause the binary to crash.
Out << LocalDateTimeString() << "\n";
+#endif
if (context.executable_name)
Out << "Running " << context.executable_name << "\n";
@@ -67,8 +68,11 @@ void BenchmarkReporter::PrintBasicContext(std::ostream *out,
Out << "\n";
}
- if (internal::global_context != nullptr) {
- for (const auto &kv : *internal::global_context) {
+ std::map<std::string, std::string> *global_context =
+ internal::GetGlobalContext();
+
+ if (global_context != nullptr) {
+ for (const auto &kv : *global_context) {
Out << kv.first << ": " << kv.second << "\n";
}
}
diff --git a/contrib/libs/benchmark/src/string_util.h b/contrib/libs/benchmark/src/string_util.h
index 4145861835..37bdd2e980 100644
--- a/contrib/libs/benchmark/src/string_util.h
+++ b/contrib/libs/benchmark/src/string_util.h
@@ -4,8 +4,10 @@
#include <sstream>
#include <string>
#include <utility>
+#include <vector>
#include "benchmark/export.h"
+#include "check.h"
#include "internal_macros.h"
namespace benchmark {
diff --git a/contrib/libs/benchmark/src/sysinfo.cc b/contrib/libs/benchmark/src/sysinfo.cc
index 999c4ac79e..e763d5c481 100644
--- a/contrib/libs/benchmark/src/sysinfo.cc
+++ b/contrib/libs/benchmark/src/sysinfo.cc
@@ -23,7 +23,7 @@
#include <codecvt>
#else
#include <fcntl.h>
-#ifndef BENCHMARK_OS_FUCHSIA
+#if !defined(BENCHMARK_OS_FUCHSIA) && !defined(BENCHMARK_OS_QURT)
#include <sys/resource.h>
#endif
#include <sys/time.h>
@@ -38,10 +38,14 @@
#endif
#if defined(BENCHMARK_OS_SOLARIS)
#error #include <kstat.h>
+#include <netdb.h>
#endif
#if defined(BENCHMARK_OS_QNX)
#include <sys/syspage.h>
#endif
+#if defined(BENCHMARK_OS_QURT)
+#error #include <qurt.h>
+#endif
#include <algorithm>
#include <array>
@@ -402,6 +406,8 @@ std::vector<CPUInfo::CacheInfo> GetCacheSizes() {
return GetCacheSizesWindows();
#elif defined(BENCHMARK_OS_QNX)
return GetCacheSizesQNX();
+#elif defined(BENCHMARK_OS_QURT)
+ return std::vector<CPUInfo::CacheInfo>();
#else
return GetCacheSizesFromKVFS();
#endif
@@ -417,14 +423,30 @@ std::string GetSystemName() {
#ifndef UNICODE
str = std::string(hostname, DWCOUNT);
#else
- // Using wstring_convert, Is deprecated in C++17
- using convert_type = std::codecvt_utf8<wchar_t>;
- std::wstring_convert<convert_type, wchar_t> converter;
- std::wstring wStr(hostname, DWCOUNT);
- str = converter.to_bytes(wStr);
+ std::vector<wchar_t> converted;
+ // Find the length first.
+ int len = ::MultiByteToWideChar(CP_UTF8, MB_ERR_INVALID_CHARS, hostname,
+ DWCOUNT, converted.begin(), 0);
+ // TODO: Report error from GetLastError()?
+ if (len == 0) return std::string("");
+ converted.reserve(len + 1);
+
+ len = ::MultiByteToWideChar(CP_UTF8, MB_ERR_INVALID_CHARS, hostname, DWCOUNT,
+ converted.begin(), converted.size());
+ // TODO: Report error from GetLastError()?
+ if (len == 0) return std::string("");
+ str = std::string(converted.data());
#endif
return str;
-#else // defined(BENCHMARK_OS_WINDOWS)
+#elif defined(BENCHMARK_OS_QURT)
+ std::string str = "Hexagon DSP";
+ qurt_arch_version_t arch_version_struct;
+ if (qurt_sysenv_get_arch_version(&arch_version_struct) == QURT_EOK) {
+ str += " v";
+ str += std::to_string(arch_version_struct.arch_version);
+ }
+ return str;
+#else
#ifndef HOST_NAME_MAX
#ifdef BENCHMARK_HAS_SYSCTL // BSD/Mac Doesnt have HOST_NAME_MAX defined
#define HOST_NAME_MAX 64
@@ -434,6 +456,8 @@ std::string GetSystemName() {
#define HOST_NAME_MAX 154
#elif defined(BENCHMARK_OS_RTEMS)
#define HOST_NAME_MAX 256
+#elif defined(BENCHMARK_OS_SOLARIS)
+#define HOST_NAME_MAX MAXHOSTNAMELEN
#else
#pragma message("HOST_NAME_MAX not defined. using 64")
#define HOST_NAME_MAX 64
@@ -463,14 +487,20 @@ int GetNumCPUs() {
// group
#elif defined(BENCHMARK_OS_SOLARIS)
// Returns -1 in case of a failure.
- int num_cpu = sysconf(_SC_NPROCESSORS_ONLN);
+ long num_cpu = sysconf(_SC_NPROCESSORS_ONLN);
if (num_cpu < 0) {
fprintf(stderr, "sysconf(_SC_NPROCESSORS_ONLN) failed with error: %s\n",
strerror(errno));
}
- return num_cpu;
+ return (int)num_cpu;
#elif defined(BENCHMARK_OS_QNX)
return static_cast<int>(_syspage_ptr->num_cpu);
+#elif defined(BENCHMARK_OS_QURT)
+ qurt_sysenv_max_hthreads_t hardware_threads;
+ if (qurt_sysenv_get_max_hw_threads(&hardware_threads) != QURT_EOK) {
+ hardware_threads.max_hthreads = 1;
+ }
+ return hardware_threads.max_hthreads;
#else
int num_cpus = 0;
int max_id = -1;
@@ -644,7 +674,8 @@ double GetCPUCyclesPerSecond(CPUInfo::Scaling scaling) {
std::cerr << "failed to open /dev/kstat\n";
return -1;
}
- kstat_t* ksp = kstat_lookup(kc, (char*)"cpu_info", -1, (char*)"cpu_info0");
+ kstat_t* ksp = kstat_lookup(kc, const_cast<char*>("cpu_info"), -1,
+ const_cast<char*>("cpu_info0"));
if (!ksp) {
std::cerr << "failed to lookup in /dev/kstat\n";
return -1;
@@ -653,8 +684,8 @@ double GetCPUCyclesPerSecond(CPUInfo::Scaling scaling) {
std::cerr << "failed to read from /dev/kstat\n";
return -1;
}
- kstat_named_t* knp =
- (kstat_named_t*)kstat_data_lookup(ksp, (char*)"current_clock_Hz");
+ kstat_named_t* knp = (kstat_named_t*)kstat_data_lookup(
+ ksp, const_cast<char*>("current_clock_Hz"));
if (!knp) {
std::cerr << "failed to lookup data in /dev/kstat\n";
return -1;
@@ -670,6 +701,9 @@ double GetCPUCyclesPerSecond(CPUInfo::Scaling scaling) {
#elif defined(BENCHMARK_OS_QNX)
return static_cast<double>((int64_t)(SYSPAGE_ENTRY(cpuinfo)->speed) *
(int64_t)(1000 * 1000));
+#elif defined(BENCHMARK_OS_QURT)
+ // QuRT doesn't provide any API to query Hexagon frequency.
+ return 1000000000;
#endif
// If we've fallen through, attempt to roughly estimate the CPU clock rate.
static constexpr int estimate_time_ms = 1000;
diff --git a/contrib/libs/benchmark/src/timers.cc b/contrib/libs/benchmark/src/timers.cc
index 97682bdcc7..0a4da83c19 100644
--- a/contrib/libs/benchmark/src/timers.cc
+++ b/contrib/libs/benchmark/src/timers.cc
@@ -23,7 +23,7 @@
#include <windows.h>
#else
#include <fcntl.h>
-#ifndef BENCHMARK_OS_FUCHSIA
+#if !defined(BENCHMARK_OS_FUCHSIA) && !defined(BENCHMARK_OS_QURT)
#include <sys/resource.h>
#endif
#include <sys/time.h>
@@ -38,6 +38,9 @@
#include <mach/mach_port.h>
#include <mach/thread_act.h>
#endif
+#if defined(BENCHMARK_OS_QURT)
+#error #include <qurt.h>
+#endif
#endif
#ifdef BENCHMARK_OS_EMSCRIPTEN
@@ -79,7 +82,7 @@ double MakeTime(FILETIME const& kernel_time, FILETIME const& user_time) {
static_cast<double>(user.QuadPart)) *
1e-7;
}
-#elif !defined(BENCHMARK_OS_FUCHSIA)
+#elif !defined(BENCHMARK_OS_FUCHSIA) && !defined(BENCHMARK_OS_QURT)
double MakeTime(struct rusage const& ru) {
return (static_cast<double>(ru.ru_utime.tv_sec) +
static_cast<double>(ru.ru_utime.tv_usec) * 1e-6 +
@@ -119,6 +122,10 @@ double ProcessCPUUsage() {
&user_time))
return MakeTime(kernel_time, user_time);
DiagnoseAndExit("GetProccessTimes() failed");
+#elif defined(BENCHMARK_OS_QURT)
+ return static_cast<double>(
+ qurt_timer_timetick_to_us(qurt_timer_get_ticks())) *
+ 1.0e-6;
#elif defined(BENCHMARK_OS_EMSCRIPTEN)
// clock_gettime(CLOCK_PROCESS_CPUTIME_ID, ...) returns 0 on Emscripten.
// Use Emscripten-specific API. Reported CPU time would be exactly the
@@ -149,6 +156,10 @@ double ThreadCPUUsage() {
GetThreadTimes(this_thread, &creation_time, &exit_time, &kernel_time,
&user_time);
return MakeTime(kernel_time, user_time);
+#elif defined(BENCHMARK_OS_QURT)
+ return static_cast<double>(
+ qurt_timer_timetick_to_us(qurt_timer_get_ticks())) *
+ 1.0e-6;
#elif defined(BENCHMARK_OS_MACOSX)
// FIXME We want to use clock_gettime, but its not available in MacOS 10.11.
// See https://github.com/google/benchmark/pull/292
diff --git a/contrib/libs/googleapis-common-protos/CHANGELOG.md b/contrib/libs/googleapis-common-protos/CHANGELOG.md
index 119dce92e9..4809b68462 100644
--- a/contrib/libs/googleapis-common-protos/CHANGELOG.md
+++ b/contrib/libs/googleapis-common-protos/CHANGELOG.md
@@ -1,5 +1,27 @@
# Changelog
+## [1.57.0](https://github.com/googleapis/python-api-common-protos/compare/v1.56.4...v1.57.0) (2022-11-15)
+
+
+### Features
+
+* Add support for Python 3.10 ([#143](https://github.com/googleapis/python-api-common-protos/issues/143)) ([63ca888](https://github.com/googleapis/python-api-common-protos/commit/63ca888512be84508fcf95e4d5d40df036a85e18))
+* Add support for Python 3.11 ([#145](https://github.com/googleapis/python-api-common-protos/issues/145)) ([b9dbb21](https://github.com/googleapis/python-api-common-protos/commit/b9dbb219ea46abd9851af1fc41ea37f9d5631c0b))
+* added google.api.JwtLocation.cookie ([6af2132](https://github.com/googleapis/python-api-common-protos/commit/6af21322879cba158e0a5992c9799e68c1744fac))
+* added google.api.Service.publishing and client libraries settings ([6af2132](https://github.com/googleapis/python-api-common-protos/commit/6af21322879cba158e0a5992c9799e68c1744fac))
+* new fields in enum google.api.ErrorReason ([6af2132](https://github.com/googleapis/python-api-common-protos/commit/6af21322879cba158e0a5992c9799e68c1744fac))
+
+
+### Bug Fixes
+
+* deprecate google.api.BackendRule.min_deadline ([6af2132](https://github.com/googleapis/python-api-common-protos/commit/6af21322879cba158e0a5992c9799e68c1744fac))
+* **deps:** Require protobuf &gt;=3.19.5 ([#141](https://github.com/googleapis/python-api-common-protos/issues/141)) ([9ea3530](https://github.com/googleapis/python-api-common-protos/commit/9ea3530b459269e964fcc98db1c5025e05d6495f))
+
+
+### Documentation
+
+* minor updates to comments ([6af2132](https://github.com/googleapis/python-api-common-protos/commit/6af21322879cba158e0a5992c9799e68c1744fac))
+
## [1.56.4](https://github.com/googleapis/python-api-common-protos/compare/v1.56.3...v1.56.4) (2022-07-12)
diff --git a/contrib/libs/googleapis-common-protos/google/api/auth.proto b/contrib/libs/googleapis-common-protos/google/api/auth.proto
index 54026e1a5d..21a8ce1b0a 100644
--- a/contrib/libs/googleapis-common-protos/google/api/auth.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/auth.proto
@@ -84,6 +84,9 @@ message JwtLocation {
// Specifies URL query parameter name to extract JWT token.
string query = 2;
+
+ // Specifies cookie name to extract JWT token.
+ string cookie = 4;
}
// The value prefix. The value format is "value_prefix{token}"
@@ -152,11 +155,12 @@ message AuthProvider {
// Implement authorizationUrl of securityDefinitions in OpenAPI spec.
string authorization_url = 5;
- // Defines the locations to extract the JWT.
+ // Defines the locations to extract the JWT. For now it is only used by the
+ // Cloud Endpoints to store the OpenAPI extension [x-google-jwt-locations]
+ // (https://cloud.google.com/endpoints/docs/openapi/openapi-extensions#x-google-jwt-locations)
//
- // JWT locations can be either from HTTP headers or URL query parameters.
- // The rule is that the first match wins. The checking order is: checking
- // all headers first, then URL query parameters.
+ // JWT locations can be one of HTTP headers, URL query parameters or
+ // cookies. The rule is that the first match wins.
//
// If not specified, default to use following 3 locations:
// 1) Authorization: Bearer
diff --git a/contrib/libs/googleapis-common-protos/google/api/backend.proto b/contrib/libs/googleapis-common-protos/google/api/backend.proto
index da38786989..1a3b705f62 100644
--- a/contrib/libs/googleapis-common-protos/google/api/backend.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/backend.proto
@@ -120,9 +120,8 @@ message BackendRule {
// varies based on the request protocol and deployment environment.
double deadline = 3;
- // Minimum deadline in seconds needed for this method. Calls having deadline
- // value lower than this will be rejected.
- double min_deadline = 4;
+ // Deprecated, do not use.
+ double min_deadline = 4 [deprecated = true];
// The number of seconds to wait for the completion of a long running
// operation. The default is no deadline.
diff --git a/contrib/libs/googleapis-common-protos/google/api/client.proto b/contrib/libs/googleapis-common-protos/google/api/client.proto
index 3b3fd0c401..323846f44d 100644
--- a/contrib/libs/googleapis-common-protos/google/api/client.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/client.proto
@@ -16,7 +16,9 @@ syntax = "proto3";
package google.api;
+import "google/api/launch_stage.proto";
import "google/protobuf/descriptor.proto";
+import "google/protobuf/duration.proto";
option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
option java_multiple_files = true;
@@ -97,3 +99,251 @@ extend google.protobuf.ServiceOptions {
// }
string oauth_scopes = 1050;
}
+
+// Required information for every language.
+message CommonLanguageSettings {
+ // Link to automatically generated reference documentation. Example:
+ // https://cloud.google.com/nodejs/docs/reference/asset/latest
+ string reference_docs_uri = 1;
+
+ // The destination where API teams want this client library to be published.
+ repeated ClientLibraryDestination destinations = 2;
+}
+
+// Details about how and where to publish client libraries.
+message ClientLibrarySettings {
+ // Version of the API to apply these settings to.
+ string version = 1;
+
+ // Launch stage of this version of the API.
+ LaunchStage launch_stage = 2;
+
+ // When using transport=rest, the client request will encode enums as
+ // numbers rather than strings.
+ bool rest_numeric_enums = 3;
+
+ // Settings for legacy Java features, supported in the Service YAML.
+ JavaSettings java_settings = 21;
+
+ // Settings for C++ client libraries.
+ CppSettings cpp_settings = 22;
+
+ // Settings for PHP client libraries.
+ PhpSettings php_settings = 23;
+
+ // Settings for Python client libraries.
+ PythonSettings python_settings = 24;
+
+ // Settings for Node client libraries.
+ NodeSettings node_settings = 25;
+
+ // Settings for .NET client libraries.
+ DotnetSettings dotnet_settings = 26;
+
+ // Settings for Ruby client libraries.
+ RubySettings ruby_settings = 27;
+
+ // Settings for Go client libraries.
+ GoSettings go_settings = 28;
+}
+
+// This message configures the settings for publishing [Google Cloud Client
+// libraries](https://cloud.google.com/apis/docs/cloud-client-libraries)
+// generated from the service config.
+message Publishing {
+ // A list of API method settings, e.g. the behavior for methods that use the
+ // long-running operation pattern.
+ repeated MethodSettings method_settings = 2;
+
+ // Link to a place that API users can report issues. Example:
+ // https://issuetracker.google.com/issues/new?component=190865&template=1161103
+ string new_issue_uri = 101;
+
+ // Link to product home page. Example:
+ // https://cloud.google.com/asset-inventory/docs/overview
+ string documentation_uri = 102;
+
+ // Used as a tracking tag when collecting data about the APIs developer
+ // relations artifacts like docs, packages delivered to package managers,
+ // etc. Example: "speech".
+ string api_short_name = 103;
+
+ // GitHub label to apply to issues and pull requests opened for this API.
+ string github_label = 104;
+
+ // GitHub teams to be added to CODEOWNERS in the directory in GitHub
+ // containing source code for the client libraries for this API.
+ repeated string codeowner_github_teams = 105;
+
+ // A prefix used in sample code when demarking regions to be included in
+ // documentation.
+ string doc_tag_prefix = 106;
+
+ // For whom the client library is being published.
+ ClientLibraryOrganization organization = 107;
+
+ // Client library settings. If the same version string appears multiple
+ // times in this list, then the last one wins. Settings from earlier
+ // settings with the same version string are discarded.
+ repeated ClientLibrarySettings library_settings = 109;
+}
+
+// Settings for Java client libraries.
+message JavaSettings {
+ // The package name to use in Java. Clobbers the java_package option
+ // set in the protobuf. This should be used **only** by APIs
+ // who have already set the language_settings.java.package_name" field
+ // in gapic.yaml. API teams should use the protobuf java_package option
+ // where possible.
+ //
+ // Example of a YAML configuration::
+ //
+ // publishing:
+ // java_settings:
+ // library_package: com.google.cloud.pubsub.v1
+ string library_package = 1;
+
+ // Configure the Java class name to use instead of the service's for its
+ // corresponding generated GAPIC client. Keys are fully-qualified
+ // service names as they appear in the protobuf (including the full
+ // the language_settings.java.interface_names" field in gapic.yaml. API
+ // teams should otherwise use the service name as it appears in the
+ // protobuf.
+ //
+ // Example of a YAML configuration::
+ //
+ // publishing:
+ // java_settings:
+ // service_class_names:
+ // - google.pubsub.v1.Publisher: TopicAdmin
+ // - google.pubsub.v1.Subscriber: SubscriptionAdmin
+ map<string, string> service_class_names = 2;
+
+ // Some settings.
+ CommonLanguageSettings common = 3;
+}
+
+// Settings for C++ client libraries.
+message CppSettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Settings for Php client libraries.
+message PhpSettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Settings for Python client libraries.
+message PythonSettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Settings for Node client libraries.
+message NodeSettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Settings for Dotnet client libraries.
+message DotnetSettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Settings for Ruby client libraries.
+message RubySettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Settings for Go client libraries.
+message GoSettings {
+ // Some settings.
+ CommonLanguageSettings common = 1;
+}
+
+// Describes the generator configuration for a method.
+message MethodSettings {
+ // Describes settings to use when generating API methods that use the
+ // long-running operation pattern.
+ // All default values below are from those used in the client library
+ // generators (e.g.
+ // [Java](https://github.com/googleapis/gapic-generator-java/blob/04c2faa191a9b5a10b92392fe8482279c4404803/src/main/java/com/google/api/generator/gapic/composer/common/RetrySettingsComposer.java)).
+ message LongRunning {
+ // Initial delay after which the first poll request will be made.
+ // Default value: 5 seconds.
+ google.protobuf.Duration initial_poll_delay = 1;
+
+ // Multiplier to gradually increase delay between subsequent polls until it
+ // reaches max_poll_delay.
+ // Default value: 1.5.
+ float poll_delay_multiplier = 2;
+
+ // Maximum time between two subsequent poll requests.
+ // Default value: 45 seconds.
+ google.protobuf.Duration max_poll_delay = 3;
+
+ // Total polling timeout.
+ // Default value: 5 minutes.
+ google.protobuf.Duration total_poll_timeout = 4;
+ }
+
+ // The fully qualified name of the method, for which the options below apply.
+ // This is used to find the method to apply the options.
+ string selector = 1;
+
+ // Describes settings to use for long-running operations when generating
+ // API methods for RPCs. Complements RPCs that use the annotations in
+ // google/longrunning/operations.proto.
+ //
+ // Example of a YAML configuration::
+ //
+ // publishing:
+ // method_behavior:
+ // - selector: CreateAdDomain
+ // long_running:
+ // initial_poll_delay:
+ // seconds: 60 # 1 minute
+ // poll_delay_multiplier: 1.5
+ // max_poll_delay:
+ // seconds: 360 # 6 minutes
+ // total_poll_timeout:
+ // seconds: 54000 # 90 minutes
+ LongRunning long_running = 2;
+}
+
+// The organization for which the client libraries are being published.
+// Affects the url where generated docs are published, etc.
+enum ClientLibraryOrganization {
+ // Not useful.
+ CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED = 0;
+
+ // Google Cloud Platform Org.
+ CLOUD = 1;
+
+ // Ads (Advertising) Org.
+ ADS = 2;
+
+ // Photos Org.
+ PHOTOS = 3;
+
+ // Street View Org.
+ STREET_VIEW = 4;
+}
+
+// To where should client libraries be published?
+enum ClientLibraryDestination {
+ // Client libraries will neither be generated nor published to package
+ // managers.
+ CLIENT_LIBRARY_DESTINATION_UNSPECIFIED = 0;
+
+ // Generate the client library in a repo under github.com/googleapis,
+ // but don't publish it to package managers.
+ GITHUB = 10;
+
+ // Publish the library to package managers like nuget.org and npmjs.com.
+ PACKAGE_MANAGER = 20;
+}
diff --git a/contrib/libs/googleapis-common-protos/google/api/control.proto b/contrib/libs/googleapis-common-protos/google/api/control.proto
index 6eb1958e3c..5e14dee30f 100644
--- a/contrib/libs/googleapis-common-protos/google/api/control.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/control.proto
@@ -22,11 +22,15 @@ option java_outer_classname = "ControlProto";
option java_package = "com.google.api";
option objc_class_prefix = "GAPI";
-// Selects and configures the service controller used by the service. The
-// service controller handles features like abuse, quota, billing, logging,
-// monitoring, etc.
+// Selects and configures the service controller used by the service.
+//
+// Example:
+//
+// control:
+// environment: servicecontrol.googleapis.com
message Control {
- // The service control environment to use. If empty, no control plane
- // feature (like quota and billing) will be enabled.
+ // The service controller environment to use. If empty, no control plane
+ // feature (like quota and billing) will be enabled. The recommended value for
+ // most services is servicecontrol.googleapis.com
string environment = 1;
}
diff --git a/contrib/libs/googleapis-common-protos/google/api/documentation.proto b/contrib/libs/googleapis-common-protos/google/api/documentation.proto
index 7288169be5..d15562db50 100644
--- a/contrib/libs/googleapis-common-protos/google/api/documentation.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/documentation.proto
@@ -78,8 +78,10 @@ option objc_class_prefix = "GAPI";
// The directive `suppress_warning` does not directly affect documentation
// and is documented together with service config validation.
message Documentation {
- // A short summary of what the service does. Can only be provided by
- // plain text.
+ // A short description of what the service does. The summary must be plain
+ // text. It becomes the overview of the service displayed in Google Cloud
+ // Console.
+ // NOTE: This field is equivalent to the standard field `description`.
string summary = 1;
// The top level pages for the documentation set.
@@ -117,15 +119,18 @@ message Documentation {
// A documentation rule provides information about individual API elements.
message DocumentationRule {
- // The selector is a comma-separated list of patterns. Each pattern is a
- // qualified name of the element which may end in "*", indicating a wildcard.
- // Wildcards are only allowed at the end and for a whole component of the
- // qualified name, i.e. "foo.*" is ok, but not "foo.b*" or "foo.*.bar". A
- // wildcard will match one or more components. To specify a default for all
- // applicable elements, the whole pattern "*" is used.
+ // The selector is a comma-separated list of patterns for any element such as
+ // a method, a field, an enum value. Each pattern is a qualified name of the
+ // element which may end in "*", indicating a wildcard. Wildcards are only
+ // allowed at the end and for a whole component of the qualified name,
+ // i.e. "foo.*" is ok, but not "foo.b*" or "foo.*.bar". A wildcard will match
+ // one or more components. To specify a default for all applicable elements,
+ // the whole pattern "*" is used.
string selector = 1;
- // Description of the selected API(s).
+ // Description of the selected proto element (e.g. a message, a method, a
+ // 'service' definition, or a field). Defaults to leading & trailing comments
+ // taken from the proto source definition of the proto element.
string description = 2;
// Deprecation description of the selected element(s). It can be provided if
@@ -153,7 +158,8 @@ message Page {
string name = 1;
// The Markdown content of the page. You can use <code>&#40;== include {path}
- // ==&#41;</code> to include content from a Markdown file.
+ // ==&#41;</code> to include content from a Markdown file. The content can be
+ // used to produce the documentation page such as HTML format page.
string content = 2;
// Subpages of this page. The order of subpages specified here will be
diff --git a/contrib/libs/googleapis-common-protos/google/api/endpoint.proto b/contrib/libs/googleapis-common-protos/google/api/endpoint.proto
index a434e8e745..3b9f6a16c1 100644
--- a/contrib/libs/googleapis-common-protos/google/api/endpoint.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/endpoint.proto
@@ -22,21 +22,26 @@ option java_outer_classname = "EndpointProto";
option java_package = "com.google.api";
option objc_class_prefix = "GAPI";
-// `Endpoint` describes a network endpoint of a service that serves a set of
+// `Endpoint` describes a network address of a service that serves a set of
// APIs. It is commonly known as a service endpoint. A service may expose
// any number of service endpoints, and all service endpoints share the same
// service definition, such as quota limits and monitoring metrics.
//
-// Example service configuration:
+// Example:
//
+// type: google.api.Service
// name: library-example.googleapis.com
// endpoints:
-// # Below entry makes 'google.example.library.v1.Library'
-// # API be served from endpoint address library-example.googleapis.com.
-// # It also allows HTTP OPTIONS calls to be passed to the backend, for
-// # it to decide whether the subsequent cross-origin request is
-// # allowed to proceed.
+// # Declares network address `https://library-example.googleapis.com`
+// # for service `library-example.googleapis.com`. The `https` scheme
+// # is implicit for all service endpoints. Other schemes may be
+// # supported in the future.
// - name: library-example.googleapis.com
+// allow_cors: false
+// - name: content-staging-library-example.googleapis.com
+// # Allows HTTP OPTIONS calls to be passed to the API frontend, for it
+// # to decide whether the subsequent cross-origin request is allowed
+// # to proceed.
// allow_cors: true
message Endpoint {
// The canonical name of this endpoint.
@@ -45,8 +50,8 @@ message Endpoint {
// Unimplemented. Dot not use.
//
// DEPRECATED: This field is no longer supported. Instead of using aliases,
- // please specify multiple [google.api.Endpoint][google.api.Endpoint] for each of the intended
- // aliases.
+ // please specify multiple [google.api.Endpoint][google.api.Endpoint] for each
+ // of the intended aliases.
//
// Additional names that this endpoint will be hosted on.
repeated string aliases = 2 [deprecated = true];
diff --git a/contrib/libs/googleapis-common-protos/google/api/error_reason.proto b/contrib/libs/googleapis-common-protos/google/api/error_reason.proto
index 393c808bec..3b1d0e2123 100644
--- a/contrib/libs/googleapis-common-protos/google/api/error_reason.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/error_reason.proto
@@ -394,4 +394,142 @@ enum ErrorReason {
// }
// }
ACCESS_TOKEN_TYPE_UNSUPPORTED = 19;
+
+ // The request is denied because the request doesn't have any authentication
+ // credentials. For more information regarding the supported authentication
+ // strategies for Google Cloud APIs, see
+ // https://cloud.google.com/docs/authentication.
+ //
+ // Example of an ErrorInfo when the request is to the Cloud Storage API
+ // without any authentication credentials.
+ //
+ // { "reason": "CREDENTIALS_MISSING",
+ // "domain": "googleapis.com",
+ // "metadata": {
+ // "service": "storage.googleapis.com",
+ // "method": "google.storage.v1.Storage.GetObject"
+ // }
+ // }
+ CREDENTIALS_MISSING = 20;
+
+ // The request is denied because the provided project owning the resource
+ // which acts as the [API
+ // consumer](https://cloud.google.com/apis/design/glossary#api_consumer) is
+ // invalid. It may be in a bad format or empty.
+ //
+ // Example of an ErrorInfo when the request is to the Cloud Functions API,
+ // but the offered resource project in the request in a bad format which can't
+ // perform the ListFunctions method.
+ //
+ // { "reason": "RESOURCE_PROJECT_INVALID",
+ // "domain": "googleapis.com",
+ // "metadata": {
+ // "service": "cloudfunctions.googleapis.com",
+ // "method":
+ // "google.cloud.functions.v1.CloudFunctionsService.ListFunctions"
+ // }
+ // }
+ RESOURCE_PROJECT_INVALID = 21;
+
+ // The request is denied because the provided session cookie is missing,
+ // invalid or failed to decode.
+ //
+ // Example of an ErrorInfo when the request is calling Cloud Storage service
+ // with a SID cookie which can't be decoded.
+ //
+ // { "reason": "SESSION_COOKIE_INVALID",
+ // "domain": "googleapis.com",
+ // "metadata": {
+ // "service": "storage.googleapis.com",
+ // "method": "google.storage.v1.Storage.GetObject",
+ // "cookie": "SID"
+ // }
+ // }
+ SESSION_COOKIE_INVALID = 23;
+
+ // The request is denied because the user is from a Google Workspace customer
+ // that blocks their users from accessing a particular service.
+ //
+ // Example scenario: https://support.google.com/a/answer/9197205?hl=en
+ //
+ // Example of an ErrorInfo when access to Google Cloud Storage service is
+ // blocked by the Google Workspace administrator:
+ //
+ // { "reason": "USER_BLOCKED_BY_ADMIN",
+ // "domain": "googleapis.com",
+ // "metadata": {
+ // "service": "storage.googleapis.com",
+ // "method": "google.storage.v1.Storage.GetObject",
+ // }
+ // }
+ USER_BLOCKED_BY_ADMIN = 24;
+
+ // The request is denied because the resource service usage is restricted
+ // by administrators according to the organization policy constraint.
+ // For more information see
+ // https://cloud.google.com/resource-manager/docs/organization-policy/restricting-services.
+ //
+ // Example of an ErrorInfo when access to Google Cloud Storage service is
+ // restricted by Resource Usage Restriction policy:
+ //
+ // { "reason": "RESOURCE_USAGE_RESTRICTION_VIOLATED",
+ // "domain": "googleapis.com",
+ // "metadata": {
+ // "consumer": "projects/project-123",
+ // "service": "storage.googleapis.com"
+ // }
+ // }
+ RESOURCE_USAGE_RESTRICTION_VIOLATED = 25;
+
+ // Unimplemented. Do not use.
+ //
+ // The request is denied because it contains unsupported system parameters in
+ // URL query parameters or HTTP headers. For more information,
+ // see https://cloud.google.com/apis/docs/system-parameters
+ //
+ // Example of an ErrorInfo when access "pubsub.googleapis.com" service with
+ // a request header of "x-goog-user-ip":
+ //
+ // { "reason": "SYSTEM_PARAMETER_UNSUPPORTED",
+ // "domain": "googleapis.com",
+ // "metadata": {
+ // "service": "pubsub.googleapis.com"
+ // "parameter": "x-goog-user-ip"
+ // }
+ // }
+ SYSTEM_PARAMETER_UNSUPPORTED = 26;
+
+ // The request is denied because it violates Org Restriction: the requested
+ // resource does not belong to allowed organizations specified in
+ // "X-Goog-Allowed-Resources" header.
+ //
+ // Example of an ErrorInfo when accessing a GCP resource that is restricted by
+ // Org Restriction for "pubsub.googleapis.com" service.
+ //
+ // {
+ // reason: "ORG_RESTRICTION_VIOLATION"
+ // domain: "googleapis.com"
+ // metadata {
+ // "consumer":"projects/123456"
+ // "service": "pubsub.googleapis.com"
+ // }
+ // }
+ ORG_RESTRICTION_VIOLATION = 27;
+
+ // The request is denied because "X-Goog-Allowed-Resources" header is in a bad
+ // format.
+ //
+ // Example of an ErrorInfo when
+ // accessing "pubsub.googleapis.com" service with an invalid
+ // "X-Goog-Allowed-Resources" request header.
+ //
+ // {
+ // reason: "ORG_RESTRICTION_HEADER_INVALID"
+ // domain: "googleapis.com"
+ // metadata {
+ // "consumer":"projects/123456"
+ // "service": "pubsub.googleapis.com"
+ // }
+ // }
+ ORG_RESTRICTION_HEADER_INVALID = 28;
}
diff --git a/contrib/libs/googleapis-common-protos/google/api/launch_stage.proto b/contrib/libs/googleapis-common-protos/google/api/launch_stage.proto
index cca8419a96..6524db5756 100644
--- a/contrib/libs/googleapis-common-protos/google/api/launch_stage.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/launch_stage.proto
@@ -23,7 +23,7 @@ option java_package = "com.google.api";
option objc_class_prefix = "GAPI";
// The launch stage as defined by [Google Cloud Platform
-// Launch Stages](http://cloud.google.com/terms/launch-stages).
+// Launch Stages](https://cloud.google.com/terms/launch-stages).
enum LaunchStage {
// Do not use this default value.
LAUNCH_STAGE_UNSPECIFIED = 0;
@@ -45,7 +45,7 @@ enum LaunchStage {
// for widespread use. By Alpha, all significant design issues are resolved
// and we are in the process of verifying functionality. Alpha customers
// need to apply for access, agree to applicable terms, and have their
- // projects allowlisted. Alpha releases don’t have to be feature complete,
+ // projects allowlisted. Alpha releases don't have to be feature complete,
// no SLAs are provided, and there are no technical support obligations, but
// they will be far enough along that customers can actually use them in
// test environments or for limited-use tests -- just like they would in
@@ -64,7 +64,7 @@ enum LaunchStage {
GA = 4;
// Deprecated features are scheduled to be shut down and removed. For more
- // information, see the “Deprecation Policy” section of our [Terms of
+ // information, see the "Deprecation Policy" section of our [Terms of
// Service](https://cloud.google.com/terms/)
// and the [Google Cloud Platform Subject to the Deprecation
// Policy](https://cloud.google.com/terms/deprecation) documentation.
diff --git a/contrib/libs/googleapis-common-protos/google/api/metric.proto b/contrib/libs/googleapis-common-protos/google/api/metric.proto
index aadc19677d..c206666f63 100644
--- a/contrib/libs/googleapis-common-protos/google/api/metric.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/metric.proto
@@ -31,23 +31,6 @@ option objc_class_prefix = "GAPI";
// existing data unusable.
//
message MetricDescriptor {
- // Additional annotations that can be used to guide the usage of a metric.
- message MetricDescriptorMetadata {
- // Deprecated. Must use the [MetricDescriptor.launch_stage][google.api.MetricDescriptor.launch_stage] instead.
- LaunchStage launch_stage = 1 [deprecated = true];
-
- // The sampling period of metric data points. For metrics which are written
- // periodically, consecutive data points are stored at this time interval,
- // excluding data loss due to errors. Metrics with a higher granularity have
- // a smaller sampling period.
- google.protobuf.Duration sample_period = 2;
-
- // The delay of data points caused by ingestion. Data points older than this
- // age are guaranteed to be ingested and available to be read, excluding
- // data loss due to errors.
- google.protobuf.Duration ingest_delay = 3;
- }
-
// The kind of measurement. It describes how the data is reported.
// For information on setting the start time and end time based on
// the MetricKind, see [TimeInterval][google.monitoring.v3.TimeInterval].
@@ -95,6 +78,23 @@ message MetricDescriptor {
MONEY = 6;
}
+ // Additional annotations that can be used to guide the usage of a metric.
+ message MetricDescriptorMetadata {
+ // Deprecated. Must use the [MetricDescriptor.launch_stage][google.api.MetricDescriptor.launch_stage] instead.
+ LaunchStage launch_stage = 1 [deprecated = true];
+
+ // The sampling period of metric data points. For metrics which are written
+ // periodically, consecutive data points are stored at this time interval,
+ // excluding data loss due to errors. Metrics with a higher granularity have
+ // a smaller sampling period.
+ google.protobuf.Duration sample_period = 2;
+
+ // The delay of data points caused by ingestion. Data points older than this
+ // age are guaranteed to be ingested and available to be read, excluding
+ // data loss due to errors.
+ google.protobuf.Duration ingest_delay = 3;
+ }
+
// The resource name of the metric descriptor.
string name = 1;
diff --git a/contrib/libs/googleapis-common-protos/google/api/monitored_resource.proto b/contrib/libs/googleapis-common-protos/google/api/monitored_resource.proto
index bd5be4e4e8..8b97baa104 100644
--- a/contrib/libs/googleapis-common-protos/google/api/monitored_resource.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/monitored_resource.proto
@@ -48,6 +48,10 @@ message MonitoredResourceDescriptor {
// Required. The monitored resource type. For example, the type
// `"cloudsql_database"` represents databases in Google Cloud SQL.
+ // For a list of types, see [Monitoring resource
+ // types](https://cloud.google.com/monitoring/api/resources)
+ // and [Logging resource
+ // types](https://cloud.google.com/logging/docs/api/v2/resource-list).
string type = 1;
// Optional. A concise name for the monitored resource type that might be
@@ -77,15 +81,18 @@ message MonitoredResourceDescriptor {
// its attributes according to the schema. For example, a particular Compute
// Engine VM instance could be represented by the following object, because the
// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] for `"gce_instance"` has labels
-// `"instance_id"` and `"zone"`:
+// `"project_id"`, `"instance_id"` and `"zone"`:
//
// { "type": "gce_instance",
-// "labels": { "instance_id": "12345678901234",
+// "labels": { "project_id": "my-project",
+// "instance_id": "12345678901234",
// "zone": "us-central1-a" }}
message MonitoredResource {
// Required. The monitored resource type. This field must match
// the `type` field of a [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] object. For
// example, the type of a Compute Engine VM instance is `gce_instance`.
+ // Some descriptors include the service name in the type; for example,
+ // the type of a Datastream stream is `datastream.googleapis.com/Stream`.
string type = 1;
// Required. Values for all of the labels listed in the associated monitored
diff --git a/contrib/libs/googleapis-common-protos/google/api/quota.proto b/contrib/libs/googleapis-common-protos/google/api/quota.proto
index dae89de304..3272cdae5c 100644
--- a/contrib/libs/googleapis-common-protos/google/api/quota.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/quota.proto
@@ -44,10 +44,10 @@ option objc_class_prefix = "GAPI";
// STANDARD: 10000
//
//
-// # The metric rules bind all methods to the read_calls metric,
-// # except for the UpdateBook and DeleteBook methods. These two methods
-// # are mapped to the write_calls metric, with the UpdateBook method
-// # consuming at twice rate as the DeleteBook method.
+// (The metric rules bind all methods to the read_calls metric,
+// except for the UpdateBook and DeleteBook methods. These two methods
+// are mapped to the write_calls metric, with the UpdateBook method
+// consuming at twice rate as the DeleteBook method.)
// metric_rules:
// - selector: "*"
// metric_costs:
@@ -74,10 +74,10 @@ option objc_class_prefix = "GAPI";
//
//
message Quota {
- // List of `QuotaLimit` definitions for the service.
+ // List of QuotaLimit definitions for the service.
repeated QuotaLimit limits = 3;
- // List of `MetricRule` definitions, each one mapping a selected method to one
+ // List of MetricRule definitions, each one mapping a selected method to one
// or more metrics.
repeated MetricRule metric_rules = 4;
}
diff --git a/contrib/libs/googleapis-common-protos/google/api/service.proto b/contrib/libs/googleapis-common-protos/google/api/service.proto
index 7cae8a9444..a901863428 100644
--- a/contrib/libs/googleapis-common-protos/google/api/service.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/service.proto
@@ -19,6 +19,7 @@ package google.api;
import "google/api/auth.proto";
import "google/api/backend.proto";
import "google/api/billing.proto";
+import "google/api/client.proto";
import "google/api/context.proto";
import "google/api/control.proto";
import "google/api/documentation.proto";
@@ -43,11 +44,12 @@ option java_outer_classname = "ServiceProto";
option java_package = "com.google.api";
option objc_class_prefix = "GAPI";
-// `Service` is the root object of Google service configuration schema. It
-// describes basic information about a service, such as the name and the
-// title, and delegates other aspects to sub-sections. Each sub-section is
-// either a proto message or a repeated proto message that configures a
-// specific aspect, such as auth. See each proto message definition for details.
+// `Service` is the root object of Google API service configuration (service
+// config). It describes the basic information about a logical service,
+// such as the service name and the user-facing title, and delegates other
+// aspects to sub-sections. Each sub-section is either a proto message or a
+// repeated proto message that configures a specific aspect, such as auth.
+// For more information, see each proto message definition.
//
// Example:
//
@@ -56,6 +58,16 @@ option objc_class_prefix = "GAPI";
// title: Google Calendar API
// apis:
// - name: google.calendar.v3.Calendar
+//
+// visibility:
+// rules:
+// - selector: "google.calendar.v3.*"
+// restriction: PREVIEW
+// backend:
+// rules:
+// - selector: "google.calendar.v3.*"
+// address: calendar.example.com
+//
// authentication:
// providers:
// - id: google_calendar_auth
@@ -72,7 +84,8 @@ message Service {
// of the service also owns the DNS name.
string name = 1;
- // The product title for this service.
+ // The product title for this service, it is the name displayed in Google
+ // Cloud Console.
string title = 2;
// The Google project that owns this service.
@@ -92,19 +105,19 @@ message Service {
repeated google.protobuf.Api apis = 3;
// A list of all proto message types included in this API service.
- // Types referenced directly or indirectly by the `apis` are
- // automatically included. Messages which are not referenced but
- // shall be included, such as types used by the `google.protobuf.Any` type,
- // should be listed here by name. Example:
+ // Types referenced directly or indirectly by the `apis` are automatically
+ // included. Messages which are not referenced but shall be included, such as
+ // types used by the `google.protobuf.Any` type, should be listed here by
+ // name by the configuration author. Example:
//
// types:
// - name: google.protobuf.Int32
repeated google.protobuf.Type types = 4;
- // A list of all enum types included in this API service. Enums
- // referenced directly or indirectly by the `apis` are automatically
- // included. Enums which are not referenced but shall be included
- // should be listed here by name. Example:
+ // A list of all enum types included in this API service. Enums referenced
+ // directly or indirectly by the `apis` are automatically included. Enums
+ // which are not referenced but shall be included should be listed here by
+ // name by the configuration author. Example:
//
// enums:
// - name: google.someapi.v1.SomeEnum
@@ -164,9 +177,14 @@ message Service {
// Output only. The source information for this configuration if available.
SourceInfo source_info = 37;
+ // Settings for [Google Cloud Client
+ // libraries](https://cloud.google.com/apis/docs/cloud-client-libraries)
+ // generated from APIs defined as protocol buffers.
+ Publishing publishing = 45;
+
// Obsolete. Do not use.
//
// This field has no semantic meaning. The service config compiler always
// sets this field to `3`.
- google.protobuf.UInt32Value config_version = 20 [deprecated = true];
+ google.protobuf.UInt32Value config_version = 20;
}
diff --git a/contrib/libs/googleapis-common-protos/google/api/visibility.proto b/contrib/libs/googleapis-common-protos/google/api/visibility.proto
index bde48dd20c..0be4581d14 100644
--- a/contrib/libs/googleapis-common-protos/google/api/visibility.proto
+++ b/contrib/libs/googleapis-common-protos/google/api/visibility.proto
@@ -55,16 +55,17 @@ extend google.protobuf.ServiceOptions {
google.api.VisibilityRule api_visibility = 72295727;
}
-// `Visibility` defines restrictions for the visibility of service
-// elements. Restrictions are specified using visibility labels
-// (e.g., PREVIEW) that are elsewhere linked to users and projects.
+// `Visibility` restricts service consumer's access to service elements,
+// such as whether an application can call a visibility-restricted method.
+// The restriction is expressed by applying visibility labels on service
+// elements. The visibility labels are elsewhere linked to service consumers.
//
-// Users and projects can have access to more than one visibility label. The
-// effective visibility for multiple labels is the union of each label's
-// elements, plus any unrestricted elements.
+// A service can define multiple visibility labels, but a service consumer
+// should be granted at most one visibility label. Multiple visibility
+// labels for a single service consumer are not supported.
//
-// If an element and its parents have no restrictions, visibility is
-// unconditionally granted.
+// If an element and all its parents have no visibility label, its visibility
+// is unconditionally granted.
//
// Example:
//
@@ -89,7 +90,8 @@ message Visibility {
message VisibilityRule {
// Selects methods, messages, fields, enums, etc. to which this rule applies.
//
- // Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
+ // Refer to [selector][google.api.DocumentationRule.selector] for syntax
+ // details.
string selector = 1;
// A comma-separated list of visibility labels that apply to the `selector`.