diff --git a/.github/scripts/tests/transform_ya_junit.py b/.github/scripts/tests/transform_ya_junit.py index 05d6927d38f3..5efb47b73871 100755 --- a/.github/scripts/tests/transform_ya_junit.py +++ b/.github/scripts/tests/transform_ya_junit.py @@ -186,7 +186,10 @@ def transform(fp, mute_check: YaMuteCheck, ya_out_dir, save_inplace, log_url_pre for case in suite.findall("testcase"): test_name = case.get("name") + test_classname = case.get("classname") + '.' + test_name + case.set("name", test_classname) case.set("classname", suite_name) + test_name = test_classname is_fail = is_faulty_testcase(case) has_fail_tests |= is_fail @@ -269,6 +272,5 @@ def main(): test_stuff_prefix, ) - if __name__ == "__main__": main() diff --git a/build/export_generators/cmake/dir_targets.jinja b/build/export_generators/cmake/dir_targets.jinja index fa0b43e6793d..1c35b4d511bd 100644 --- a/build/export_generators/cmake/dir_targets.jinja +++ b/build/export_generators/cmake/dir_targets.jinja @@ -4,8 +4,12 @@ {%- set args = list_of_dict|selectattr(macro_field, 'eq', macro)|map(attribute=args_field)|sum -%} {%- if args|length %} {{ macro }}({{ target_name }}{{ macro_suffix }} -{%- for arg in args %} +{%- for arg in args -%} +{%- if ('"' in arg) and (arg[0] != '"') %} + [=[{{ arg }}]=] +{%- else %} {{ arg }} +{%- endif -%} {%- endfor %} ) {% endif %} diff --git a/build/external_resources/go_tools/ya.make b/build/external_resources/go_tools/ya.make index 5b16d56efa01..4c564184d31f 100644 --- a/build/external_resources/go_tools/ya.make +++ b/build/external_resources/go_tools/ya.make @@ -5,6 +5,12 @@ TOOLCHAIN(go) IF(GOSTD_VERSION == 1.23) VERSION(1.23) DECLARE_EXTERNAL_HOST_RESOURCES_BUNDLE_BY_JSON(GO_TOOLS go1.23.json) +ELSEIF(GOSTD_VERSION == 1.24) + VERSION(1.24) + DECLARE_EXTERNAL_HOST_RESOURCES_BUNDLE_BY_JSON(GO_TOOLS go1.24.json) +ELSEIF(GOSTD_VERSION == 1.25) + VERSION(1.25) + DECLARE_EXTERNAL_HOST_RESOURCES_BUNDLE_BY_JSON(GO_TOOLS go1.25.json) ELSE() MESSAGE(FATAL_ERROR Unsupported version [${GOSTD_VERSION}] of Go Standard Library) ENDIF() diff --git a/build/mapping.conf.json b/build/mapping.conf.json index de2196b3d6ea..86118aeb4909 100644 --- a/build/mapping.conf.json +++ b/build/mapping.conf.json @@ -571,6 +571,7 @@ "8944928850": "{registry_endpoint}/8944928850", "8980584272": "{registry_endpoint}/8980584272", "9029509511": "{registry_endpoint}/9029509511", + "9059000402": "{registry_endpoint}/9059000402", "5486731632": "{registry_endpoint}/5486731632", "5514350352": "{registry_endpoint}/5514350352", "5514360398": "{registry_endpoint}/5514360398", @@ -2072,6 +2073,7 @@ "8944928850": "devtools/ya/test/programs/test_tool/bin/test_tool for linux", "8980584272": "devtools/ya/test/programs/test_tool/bin/test_tool for linux", "9029509511": "devtools/ya/test/programs/test_tool/bin/test_tool for linux", + "9059000402": "devtools/ya/test/programs/test_tool/bin/test_tool for linux", "5486731632": "devtools/ya/test/programs/test_tool/bin3/test_tool3 for linux", "5514350352": "devtools/ya/test/programs/test_tool/bin3/test_tool3 for linux", "5514360398": "devtools/ya/test/programs/test_tool/bin3/test_tool3 for linux", diff --git a/build/platform/test_tool/host.ya.make.inc b/build/platform/test_tool/host.ya.make.inc index 9ed99c24548c..47d688dcb01e 100644 --- a/build/platform/test_tool/host.ya.make.inc +++ b/build/platform/test_tool/host.ya.make.inc @@ -1,12 +1,12 @@ IF (HOST_OS_DARWIN AND HOST_ARCH_X86_64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029515707) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9059043122) ELSEIF (HOST_OS_DARWIN AND HOST_ARCH_ARM64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029513855) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9059040296) ELSEIF (HOST_OS_LINUX AND HOST_ARCH_X86_64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029519042) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9059050710) ELSEIF (HOST_OS_LINUX AND HOST_ARCH_AARCH64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029512688) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9059037599) ELSEIF (HOST_OS_WINDOWS AND HOST_ARCH_X86_64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029517384) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9059047042) ENDIF() diff --git a/build/platform/test_tool/host_os.ya.make.inc b/build/platform/test_tool/host_os.ya.make.inc index 5602ea6cabe8..6be493df5e5d 100644 --- a/build/platform/test_tool/host_os.ya.make.inc +++ b/build/platform/test_tool/host_os.ya.make.inc @@ -1,12 +1,12 @@ IF (HOST_OS_DARWIN AND HOST_ARCH_X86_64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029506769) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9058995494) ELSEIF (HOST_OS_DARWIN AND HOST_ARCH_ARM64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029504959) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9058993203) ELSEIF (HOST_OS_LINUX AND HOST_ARCH_X86_64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029509511) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9059000402) ELSEIF (HOST_OS_LINUX AND HOST_ARCH_AARCH64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029503739) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9058991328) ELSEIF (HOST_OS_WINDOWS AND HOST_ARCH_X86_64) - DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9029508202) + DECLARE_EXTERNAL_RESOURCE(TEST_TOOL_HOST sbr:9058997687) ENDIF() diff --git a/contrib/libs/icu/.yandex_meta/__init__.py b/contrib/libs/icu/.yandex_meta/__init__.py index 3b791b3892df..e738a26bc421 100644 --- a/contrib/libs/icu/.yandex_meta/__init__.py +++ b/contrib/libs/icu/.yandex_meta/__init__.py @@ -6,17 +6,23 @@ from devtools.yamaker.project import NixProject +def _get_major_version(version: str) -> str: + return version.split('.')[0] + + def post_build(self): # copying icudt.dat file from original repository - icu_dat_path = f"{self.srcdir}/data/in/icudt76l.dat" - rodata_path = f"{self.dstdir}/icudt76_dat.rodata" + major_version = _get_major_version(self.version) + icu_dat_path = f"{self.srcdir}/data/in/icudt{major_version}l.dat" + rodata_path = f"{self.dstdir}/icudt{major_version}_dat.rodata" shutil.copy(icu_dat_path, rodata_path) def post_install(self): result_target = self.yamakes["."] - result_target.SRCS.add("icudt76_dat.rodata") + major_version = _get_major_version(self.version) + result_target.SRCS.add(f"icudt{major_version}_dat.rodata") result_target.CFLAGS = [ "-DU_COMMON_IMPLEMENTATION", @@ -84,7 +90,7 @@ def post_install(self): "g:cpp-contrib", ], arcdir="contrib/libs/icu", - nixattr="icu74", + nixattr="icu", put_with={ "icuio": [ "icuuc", diff --git a/contrib/libs/icu/.yandex_meta/devtools.copyrights.report b/contrib/libs/icu/.yandex_meta/devtools.copyrights.report index 6917fcfd0b94..0e33c102bff3 100644 --- a/contrib/libs/icu/.yandex_meta/devtools.copyrights.report +++ b/contrib/libs/icu/.yandex_meta/devtools.copyrights.report @@ -336,6 +336,17 @@ BELONGS ya.make Files with this license: readme.html [7:10] +KEEP COPYRIGHT_SERVICE_LABEL 15a10786a52ce6e33763c52348c47981 +BELONGS ya.make + License text: + Copyright © 2016-2025 Unicode, Inc. + Scancode info: + Original SPDX id: COPYRIGHT_SERVICE_LABEL + Score : 100.00 + Match type : COPYRIGHT + Files with this license: + LICENSE [5:5] + KEEP COPYRIGHT_SERVICE_LABEL 15d83207399227b14a1044b1cba00a64 BELONGS ya.make License text: @@ -761,17 +772,6 @@ BELONGS ya.make include/unicode/selfmt.h [4:6] include/unicode/umsg.h [4:6] -KEEP COPYRIGHT_SERVICE_LABEL 2a4e27e8d5d46fb305aaa9ee946c9903 -BELONGS ya.make - License text: - Copyright © 2016-2024 Unicode, Inc. - Scancode info: - Original SPDX id: COPYRIGHT_SERVICE_LABEL - Score : 100.00 - Match type : COPYRIGHT - Files with this license: - LICENSE [5:5] - KEEP COPYRIGHT_SERVICE_LABEL 2b694c7444010b1b84ed2710400fe3ef BELONGS ya.make Note: matched license text is too long. Read it in the source files. @@ -3450,7 +3450,7 @@ BELONGS ya.make Score : 100.00 Match type : COPYRIGHT Files with this license: - i18n/messageformat2.cpp [523:525] + i18n/messageformat2.cpp [505:507] KEEP COPYRIGHT_SERVICE_LABEL a021d3bd6d6cbb97cbccc0ab1586c491 BELONGS ya.make @@ -3840,7 +3840,7 @@ BELONGS ya.make Score : 100.00 Match type : COPYRIGHT Files with this license: - APIChangeReport.html [1173:1175] + APIChangeReport.html [566:568] KEEP COPYRIGHT_SERVICE_LABEL c1b7297fc443f46a1d1de36f8b788822 BELONGS ya.make @@ -4354,7 +4354,7 @@ BELONGS ya.make Score : 100.00 Match type : COPYRIGHT Files with this license: - i18n/messageformat2.cpp [581:591] + i18n/messageformat2.cpp [563:573] KEEP COPYRIGHT_SERVICE_LABEL eed7e8b3d80757822970ac3a50dd6716 BELONGS ya.make diff --git a/contrib/libs/icu/.yandex_meta/devtools.licenses.report b/contrib/libs/icu/.yandex_meta/devtools.licenses.report index 7d9aaeee7e67..023831e28d10 100644 --- a/contrib/libs/icu/.yandex_meta/devtools.licenses.report +++ b/contrib/libs/icu/.yandex_meta/devtools.licenses.report @@ -28,7 +28,7 @@ # FILE_IGNORE - ignore file (do nothing) # FILE_INCLUDE - include all file data into licenses text file # ======================= -IGNORE_FILES icudt76_dat.rodata +IGNORE_FILES icudt77_dat.rodata KEEP Unicode 0285f1da3a441f34fd441c30fe7aa87e BELONGS ya.make @@ -111,7 +111,7 @@ BELONGS ya.make Match type : INTRO Links : https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/free-unknown.LICENSE Files with this license: - i18n/messageformat2_parser.cpp [338:338] + i18n/messageformat2_parser.cpp [585:585] KEEP MIT 399584035c417b91040964779555dfac BELONGS ya.make @@ -1217,7 +1217,7 @@ BELONGS ya.make Match type : REFERENCE Links : http://unicode.org/, http://unicode.org/copyright.html, https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unicode.LICENSE Files with this license: - APIChangeReport.html [1175:1175] + APIChangeReport.html [568:568] KEEP BSD-3-Clause 8324f1990c82a65667a0b4767115a5fa BELONGS ya.make diff --git a/contrib/libs/icu/.yandex_meta/licenses.list.txt b/contrib/libs/icu/.yandex_meta/licenses.list.txt index 1dead784d2c9..511cca952c3f 100644 --- a/contrib/libs/icu/.yandex_meta/licenses.list.txt +++ b/contrib/libs/icu/.yandex_meta/licenses.list.txt @@ -205,7 +205,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // 5iii(c)(a). Assert that `key` is a literal. // (Not needed) // 5iii(c)(b). Let `ks` be the resolved value of `key`. - UnicodeString ks = key.asLiteral().unquoted(); + UnicodeString ks = normalizeNFC(key.asLiteral().unquoted()); // 5iii(c)(c) Let matchpref be the integer position of ks in `matches`. matchpref = vectorFind(matches, ks); U_ASSERT(matchpref >= 0); @@ -1355,7 +1355,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ====================COPYRIGHT==================== -Contents generated by StableAPI tool on Mon Sep 30 11:33:51 PDT 2024
+Contents generated by StableAPI tool on Wed Feb 19 16:09:53 PST 2025
Copyright © 2017 and later: Unicode, Inc. and others.
License & terms of use: http://www.unicode.org/copyright.html @@ -1383,7 +1383,7 @@ Copyright © 2012-2015 Dan Nicholson ====================COPYRIGHT==================== -Copyright © 2016-2024 Unicode, Inc. +Copyright © 2016-2025 Unicode, Inc. ====================Custom-punycode==================== diff --git a/contrib/libs/icu/.yandex_meta/override.nix b/contrib/libs/icu/.yandex_meta/override.nix index 25a885fdad78..fd87fb070250 100644 --- a/contrib/libs/icu/.yandex_meta/override.nix +++ b/contrib/libs/icu/.yandex_meta/override.nix @@ -1,11 +1,11 @@ self: super: with self; rec { - version = "76.1"; + version = "77.1"; version_dash = "${lib.replaceStrings [ "." ] [ "-" ] version}"; version_us = "${lib.replaceStrings [ "." ] [ "_" ] version}"; src = fetchurl { url = "https://github.com/unicode-org/icu/releases/download/release-${version_dash}/icu4c-${version_us}-src.tgz"; - hash = "sha256-36y0a/5HR0EEcs4+EUS/KKEC/uqk44dbrJtMbPMPTz4="; + hash = "sha256-WI5DH3cyfDkDH/u4hDwOO8EiwhE3RIX6h9xfP6/yQGE="; }; sourceRoot = "icu/source"; diff --git a/contrib/libs/icu/APIChangeReport.html b/contrib/libs/icu/APIChangeReport.html index d1df4b100410..d99b133871e1 100644 --- a/contrib/libs/icu/APIChangeReport.html +++ b/contrib/libs/icu/APIChangeReport.html @@ -5,31 +5,31 @@ --> -ICU4C API Comparison: ICU 75 with ICU 76 +ICU4C API Comparison: ICU 76 with ICU 77 -

ICU4C API Comparison: ICU 75 with ICU 76

+

ICU4C API Comparison: ICU 76 with ICU 77

-

Removed from ICU 75

+

Removed from ICU 76

- + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileAPIICU 75ICU 76FileAPIICU 76ICU 77
messageformat2_data_model.hBuilder& icu::message2::MFDataModel::Builder::addUnsupportedStatement(UnsupportedStatement&&, UErrorCode&)Internal
ICU 75
(missing)
+
messageformat2_data_model.hBuilder& icu::message2::MFDataModel::Builder::addSelector(Expression&&, UErrorCode&)Internal
ICU 75
(missing)
messageformat2_data_model.hBuilder& icu::message2::data_model::Operator::Builder::setReserved(Reserved&&)Internal
ICU 75
(missing)
+
resbund.hconst Locale icu::ResourceBundle::getLocale(ULocDataLocaleType, UErrorCode&) constStable
ICU 2.8
(missing)
messageformat2_data_model.hBuilder& icu::message2::data_model::Reserved::Builder::add(Literal&&, UErrorCode&)Internal
ICU 75
(missing)
+
timezone.hstatic const UnicodeString icu::TimeZone::getEquivalentID(const UnicodeString&, int32_t)Stable
ICU 2.0
(missing)
messageformat2_data_model.hBuilder& icu::message2::data_model::Reserved::Builder::operator=(Builder&&)=delete(untagged)(missing)
-
messageformat2_data_model.hBuilder& icu::message2::data_model::Reserved::Builder::operator=(const Builder&)=delete(untagged)(missing)
-
messageformat2_data_model.hBuilder& icu::message2::data_model::UnsupportedStatement::Builder::addExpression(Expression&&, UErrorCode&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hBuilder& icu::message2::data_model::UnsupportedStatement::Builder::operator=(Builder&&)=delete(untagged)(missing)
-
messageformat2_data_model.hBuilder& icu::message2::data_model::UnsupportedStatement::Builder::operator=(const Builder&)=delete(untagged)(missing)
-
messageformat2_data_model.hBuilder& icu::message2::data_model::UnsupportedStatement::Builder::setBody(Reserved&&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hBuilder& icu::message2::data_model::UnsupportedStatement::Builder::setKeyword(const UnicodeString&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hReserved icu::message2::data_model::Reserved::Builder::build(UErrorCode&) constInternal
ICU 75
(missing)
-
messageformat2_data_model.hReserved& icu::message2::data_model::Reserved::operator=(Reserved)Internal
ICU 75
(missing)
-
messageformat2_data_model.hUnsupportedStatement icu::message2::data_model::UnsupportedStatement::Builder::build(UErrorCode&) constInternal
ICU 75
(missing)
-
messageformat2_data_model.hUnsupportedStatement& icu::message2::data_model::UnsupportedStatement::operator=(UnsupportedStatement)Internal
ICU 75
(missing)
-
messageformat2_data_model.hbool icu::message2::data_model::Expression::isReserved() constInternal
ICU 75
(missing)
-
messageformat2_data_model.hconst Literal& icu::message2::data_model::Reserved::getPart(int32_t) constInternal
ICU 75
(missing)
-
messageformat2_data_model.hconst Reserved* icu::message2::data_model::UnsupportedStatement::getBody(UErrorCode&) constInternal
ICU 75
(missing)
-
messageformat2_data_model.hconst UnicodeString & icu::message2::data_model::UnsupportedStatement::getKeyword() constInternal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::Builder::Builder(Builder&&)=delete(untagged)(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::Builder::Builder(UErrorCode&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::Builder::Builder(const Builder&)=delete(untagged)(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::Builder::~Builder()Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::Reserved()Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::Reserved(const Reserved&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::Reserved::~Reserved()Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::Builder::Builder(Builder&&)=delete(untagged)(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::Builder::Builder(UErrorCode&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::Builder::Builder(const Builder&)=delete(untagged)(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::Builder::~Builder()Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::UnsupportedStatement()Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::UnsupportedStatement(const UnsupportedStatement&)Internal
ICU 75
(missing)
-
messageformat2_data_model.hicu::message2::data_model::UnsupportedStatement::~UnsupportedStatement()Internal
ICU 75
(missing)
-
messageformat2_data_model.hint32_t icu::message2::data_model::Reserved::numParts() constInternal
ICU 75
(missing)
-
messageformat2_data_model.hstd::vector< Expression > icu::message2::data_model::UnsupportedStatement::getExpressions() constInternal
ICU 75
(missing)
-
simplenumberformatter.hvoid icu::number::SimpleNumber::truncateStart(uint32_t, UErrorCode&)Deprecated
ICU 75
(missing)
-
unistr.hUNISTR_FROM_STRING_EXPLICIT icu::UnicodeString::UnicodeString(const char16_t*)Stable
ICU 2.0
(missing)
-
unistr.hUNISTR_FROM_STRING_EXPLICIT icu::UnicodeString::UnicodeString(const uint16_t*)Stable
ICU 59
(missing)
-
unistr.hUNISTR_FROM_STRING_EXPLICIT icu::UnicodeString::UnicodeString(const wchar_t*)Stable
ICU 59
(missing)
-
unistr.hUnicodeString& icu::UnicodeString::remove(int32_t, int32_t length=(int32_t))Stable
ICU 2.0
(missing)
-
unistr.hUnicodeString& icu::UnicodeString::removeBetween(int32_t, int32_t limit=(int32_t))Stable
ICU 2.0
(missing)
-
usimplenumberformatter.hvoid usnum_truncateStart(USimpleNumber*, int32_t, UErrorCode*)Deprecated
ICU 75
(missing)
-
utypes.henum UErrorCode::U_MF_UNSUPPORTED_EXPRESSION_ERRORInternal
ICU 75
(missing)
-
utypes.henum UErrorCode::U_MF_UNSUPPORTED_STATEMENT_ERRORInternal
ICU 75
(missing)
+
uset.hUnicodeString U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator* () constDraft
ICU 76
(missing)
@@ -222,11 +66,11 @@

Removed from ICU 75

(jump back to top)
-

Deprecated or Obsoleted in ICU 76

+

Deprecated or Obsoleted in ICU 77

- +
FileAPIICU 75ICU 76FileAPIICU 76ICU 77
@@ -234,925 +78,474 @@

Deprecated or Obsoleted in ICU 76

(jump back to top)
-

Changed in ICU 76 (old, new)

+

Changed in ICU 77 (old, new)

- + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - - - - - - +
FileAPIICU 75ICU 76FileAPIICU 76ICU 77
measunit.hstatic MeasureUnit icu::MeasureUnit::getGasolineEnergyDensity()Draft→Stable
ICU 74
measunit.hstatic MeasureUnit* icu::MeasureUnit::createGasolineEnergyDensity(UErrorCode&)Draft→Stable
ICU 74
measure.hbool icu::Measure::operator!=(const UObject&) constDraft→Stable
ICU 74
normalizer2.hstatic const Normalizer2* icu::Normalizer2::getNFKCSimpleCasefoldInstance(UErrorCode&)Draft→Stable
ICU 74
timezone.hstatic UnicodeString& icu::TimeZone::getIanaID(const UnicodeString&, UnicodeString&, UErrorCode&)Draft→Stable
ICU 74
ucal.hint32_t ucal_getIanaTimeZoneID(const UChar*, int32_t, UChar*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UProperty::UCHAR_IDS_UNARY_OPERATORDraft→Stable
ICU 74
uchar.henum UProperty::UCHAR_ID_COMPAT_MATH_CONTINUEDraft→Stable
ICU 74
uchar.henum UProperty::UCHAR_ID_COMPAT_MATH_STARTDraft→Stable
ICU 74
ulocale.hUEnumeration* ulocale_getKeywords(const ULocale*, UErrorCode*)Draft→Stable
ICU 74
ulocale.hUEnumeration* ulocale_getUnicodeKeywords(const ULocale*, UErrorCode*)Draft→Stable
ICU 74
ulocale.hULocale* ulocale_openForLanguageTag(const char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocale.hULocale* ulocale_openForLocaleID(const char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
numberformatter.hUnlocalizedNumberFormatter icu::number::LocalizedNumberFormatter::withoutLocale() &&Draft→Stable
ICU 75
ulocale.hbool ulocale_isBogus(const ULocale*)Draft→Stable
ICU 74
numberformatter.hUnlocalizedNumberFormatter icu::number::LocalizedNumberFormatter::withoutLocale() const &Draft→Stable
ICU 75
ulocale.hconst char* ulocale_getBaseName(const ULocale*)Draft→Stable
ICU 74
numberrangeformatter.hUnlocalizedNumberRangeFormatter icu::number::LocalizedNumberRangeFormatter::withoutLocale() &&Draft→Stable
ICU 75
ulocale.hconst char* ulocale_getLanguage(const ULocale*)Draft→Stable
ICU 74
numberrangeformatter.hUnlocalizedNumberRangeFormatter icu::number::LocalizedNumberRangeFormatter::withoutLocale() const &Draft→Stable
ICU 75
ulocale.hconst char* ulocale_getLocaleID(const ULocale*)Draft→Stable
ICU 74
simplenumberformatter.hvoid icu::number::SimpleNumber::setMaximumIntegerDigits(uint32_t, UErrorCode&)Draft→Stable
ICU 75
ulocale.hconst char* ulocale_getRegion(const ULocale*)Draft→Stable
ICU 74
uchar.hbool u_hasIDType(UChar32, UIdentifierType)Draft→Stable
ICU 75
ulocale.hconst char* ulocale_getScript(const ULocale*)Draft→Stable
ICU 74
uchar.henum UIdentifierStatus::U_ID_STATUS_ALLOWEDDraft→Stable
ICU 75
ulocale.hconst char* ulocale_getVariant(const ULocale*)Draft→Stable
ICU 74
uchar.henum UIdentifierStatus::U_ID_STATUS_RESTRICTEDDraft→Stable
ICU 75
ulocale.hint32_t ulocale_getKeywordValue(const ULocale*, const char*, int32_t, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_DEFAULT_IGNORABLEDraft→Stable
ICU 75
ulocale.hint32_t ulocale_getUnicodeKeywordValue(const ULocale*, const char*, int32_t, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_DEPRECATEDDraft→Stable
ICU 75
ulocale.hvoid ulocale_close(ULocale*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_EXCLUSIONDraft→Stable
ICU 75
ulocbuilder.hULocale* ulocbld_buildULocale(ULocaleBuilder*, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_INCLUSIONDraft→Stable
ICU 75
ulocbuilder.hULocaleBuilder* ulocbld_open()Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_LIMITED_USEDraft→Stable
ICU 75
ulocbuilder.hbool ulocbld_copyErrorTo(const ULocaleBuilder*, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_NOT_CHARACTERDraft→Stable
ICU 75
ulocbuilder.hint32_t ulocbld_buildLanguageTag(ULocaleBuilder*, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_NOT_NFKCDraft→Stable
ICU 75
ulocbuilder.hint32_t ulocbld_buildLocaleID(ULocaleBuilder*, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_NOT_XIDDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_addUnicodeLocaleAttribute(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_OBSOLETEDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_adoptULocale(ULocaleBuilder*, ULocale*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_RECOMMENDEDDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_clear(ULocaleBuilder*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_TECHNICALDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_clearExtensions(ULocaleBuilder*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_UNCOMMON_USEDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_close(ULocaleBuilder*)Draft→Stable
ICU 74
uchar.henum UProperty::UCHAR_IDENTIFIER_STATUSDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_removeUnicodeLocaleAttribute(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uchar.henum UProperty::UCHAR_IDENTIFIER_TYPEDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setExtension(ULocaleBuilder*, char, const char*, int32_t)Draft→Stable
ICU 74
uchar.hint32_t u_getIDTypes(UChar32, UIdentifierType*, int32_t, UErrorCode*)Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setLanguage(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uniset.hU_HEADER_NESTED_NAMESPACE::USetElementIterator icu::UnicodeSet::begin() constDraft
ICU 76
Draft
+ICU 77
ulocbuilder.hvoid ulocbld_setLanguageTag(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uniset.hU_HEADER_NESTED_NAMESPACE::USetElementIterator icu::UnicodeSet::end() constDraft
ICU 76
Draft
+ICU 77
ulocbuilder.hvoid ulocbld_setLocale(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uset.hUSetElementIterator & U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator++()Draft
ICU 76
Draft
+ICU 77
ulocbuilder.hvoid ulocbld_setRegion(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uset.hUSetElementIterator U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator++(int)Draft
ICU 76
Draft
+ICU 77
ulocbuilder.hvoid ulocbld_setScript(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uset.hUSetElementIterator U_HEADER_ONLY_NAMESPACE::USetElements::begin() constDraft
ICU 76
Draft
+ICU 77
ulocbuilder.hvoid ulocbld_setUnicodeLocaleKeyword(ULocaleBuilder*, const char*, int32_t, const char*, int32_t)Draft→Stable
ICU 74
uset.hUSetElementIterator U_HEADER_ONLY_NAMESPACE::USetElements::end() constDraft
ICU 76
Draft
+ICU 77
ulocbuilder.hvoid ulocbld_setVariant(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uset.hU_HEADER_ONLY_NAMESPACE::USetElementIterator::USetElementIterator(const USetElementIterator&)=defaultDraft
ICU 76
Draft
+ICU 77
unorm2.hconst UNormalizer2* unorm2_getNFKCSimpleCasefoldInstance(UErrorCode*)Draft→Stable
ICU 74
uset.hU_HEADER_ONLY_NAMESPACE::USetElements::USetElements(const USet*)Draft
ICU 76
Draft
+ICU 77
uspoof.hicu::UnicodeString& uspoof_getBidiSkeletonUnicodeString(const USpoofChecker*, UBiDiDirection, const icu::UnicodeString&, icu::UnicodeString&, UErrorCode*)Draft→Stable
ICU 74
uset.hU_HEADER_ONLY_NAMESPACE::USetElements::USetElements(const USetElements&)=defaultDraft
ICU 76
Draft
+ICU 77
uspoof.hint32_t uspoof_getBidiSkeleton(const USpoofChecker*, UBiDiDirection, const UChar*, int32_t, UChar*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uset.hbool U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator!=(const USetElementIterator&) constDraft
ICU 76
Draft
+ICU 77
uspoof.hint32_t uspoof_getBidiSkeletonUTF8(const USpoofChecker*, UBiDiDirection, const char*, int32_t, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uset.hbool U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator==(const USetElementIterator&) constDraft
ICU 76
Draft
+ICU 77
uspoof.huint32_t uspoof_areBidiConfusable(const USpoofChecker*, UBiDiDirection, const UChar*, int32_t, const UChar*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uspoof.huint32_t uspoof_areBidiConfusableUTF8(const USpoofChecker*, UBiDiDirection, const char*, int32_t, const char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uspoof.huint32_t uspoof_areBidiConfusableUnicodeString(const USpoofChecker*, UBiDiDirection, const icu::UnicodeString&, const icu::UnicodeString&, UErrorCode*)Draft→Stable
ICU 74
usimplenumberformatter.hvoid usnum_setMaximumIntegerDigits(USimpleNumber*, int32_t, UErrorCode*)Draft→Stable
ICU 75

(jump back to top)
-

Promoted to stable in ICU 76

+

Promoted to stable in ICU 77

- + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - +
FileAPIICU 75ICU 76FileAPIICU 76ICU 77
measunit.hstatic MeasureUnit icu::MeasureUnit::getGasolineEnergyDensity()Draft→Stable
ICU 74
measunit.hstatic MeasureUnit* icu::MeasureUnit::createGasolineEnergyDensity(UErrorCode&)Draft→Stable
ICU 74
measure.hbool icu::Measure::operator!=(const UObject&) constDraft→Stable
ICU 74
normalizer2.hstatic const Normalizer2* icu::Normalizer2::getNFKCSimpleCasefoldInstance(UErrorCode&)Draft→Stable
ICU 74
timezone.hstatic UnicodeString& icu::TimeZone::getIanaID(const UnicodeString&, UnicodeString&, UErrorCode&)Draft→Stable
ICU 74
ucal.hint32_t ucal_getIanaTimeZoneID(const UChar*, int32_t, UChar*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UBlockCode::UBLOCK_EGYPTIAN_HIEROGLYPHS_EXTENDED_A(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_GARAY(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_GURUNG_KHEMA(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_KIRAT_RAI(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_MYANMAR_EXTENDED_C(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_OL_ONAL(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_SUNUWAR(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_SYMBOLS_FOR_LEGACY_COMPUTING_SUPPLEMENT(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_TODHRI(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_TULU_TIGALARI(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UIndicSyllabicCategory::U_INSC_REORDERING_KILLER(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UJoiningGroup::U_JG_KASHMIRI_YEH(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UProperty::UCHAR_IDS_UNARY_OPERATORDraft→Stable
ICU 74
uchar.henum UProperty::UCHAR_ID_COMPAT_MATH_CONTINUEDraft→Stable
ICU 74
uchar.henum UProperty::UCHAR_ID_COMPAT_MATH_STARTDraft→Stable
ICU 74
ulocale.hUEnumeration* ulocale_getKeywords(const ULocale*, UErrorCode*)Draft→Stable
ICU 74
ulocale.hUEnumeration* ulocale_getUnicodeKeywords(const ULocale*, UErrorCode*)Draft→Stable
ICU 74
ulocale.hULocale* ulocale_openForLanguageTag(const char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocale.hULocale* ulocale_openForLocaleID(const char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocale.hbool ulocale_isBogus(const ULocale*)Draft→Stable
ICU 74
ulocale.hconst char* ulocale_getBaseName(const ULocale*)Draft→Stable
ICU 74
ulocale.hconst char* ulocale_getLanguage(const ULocale*)Draft→Stable
ICU 74
ulocale.hconst char* ulocale_getLocaleID(const ULocale*)Draft→Stable
ICU 74
ulocale.hconst char* ulocale_getRegion(const ULocale*)Draft→Stable
ICU 74
ulocale.hconst char* ulocale_getScript(const ULocale*)Draft→Stable
ICU 74
ulocale.hconst char* ulocale_getVariant(const ULocale*)Draft→Stable
ICU 74
ulocale.hint32_t ulocale_getKeywordValue(const ULocale*, const char*, int32_t, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocale.hint32_t ulocale_getUnicodeKeywordValue(const ULocale*, const char*, int32_t, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocale.hvoid ulocale_close(ULocale*)Draft→Stable
ICU 74
ulocbuilder.hULocale* ulocbld_buildULocale(ULocaleBuilder*, UErrorCode*)Draft→Stable
ICU 74
ulocbuilder.hULocaleBuilder* ulocbld_open()Draft→Stable
ICU 74
ulocbuilder.hbool ulocbld_copyErrorTo(const ULocaleBuilder*, UErrorCode*)Draft→Stable
ICU 74
ulocbuilder.hint32_t ulocbld_buildLanguageTag(ULocaleBuilder*, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocbuilder.hint32_t ulocbld_buildLocaleID(ULocaleBuilder*, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
ulocbuilder.hvoid ulocbld_addUnicodeLocaleAttribute(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
ulocbuilder.hvoid ulocbld_adoptULocale(ULocaleBuilder*, ULocale*)Draft→Stable
ICU 74
ulocbuilder.hvoid ulocbld_clear(ULocaleBuilder*)Draft→Stable
ICU 74
ulocbuilder.hvoid ulocbld_clearExtensions(ULocaleBuilder*)Draft→Stable
ICU 74
ulocbuilder.hvoid ulocbld_close(ULocaleBuilder*)Draft→Stable
ICU 74
numberformatter.hUnlocalizedNumberFormatter icu::number::LocalizedNumberFormatter::withoutLocale() &&Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_removeUnicodeLocaleAttribute(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
numberformatter.hUnlocalizedNumberFormatter icu::number::LocalizedNumberFormatter::withoutLocale() const &Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setExtension(ULocaleBuilder*, char, const char*, int32_t)Draft→Stable
ICU 74
numberrangeformatter.hUnlocalizedNumberRangeFormatter icu::number::LocalizedNumberRangeFormatter::withoutLocale() &&Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setLanguage(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
numberrangeformatter.hUnlocalizedNumberRangeFormatter icu::number::LocalizedNumberRangeFormatter::withoutLocale() const &Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setLanguageTag(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
resbund.hLocale icu::ResourceBundle::getLocale(ULocDataLocaleType, UErrorCode&) const(missing)Stable
+ICU 2.8
ulocbuilder.hvoid ulocbld_setLocale(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
simplenumberformatter.hvoid icu::number::SimpleNumber::setMaximumIntegerDigits(uint32_t, UErrorCode&)Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setRegion(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
timezone.hstatic UnicodeString icu::TimeZone::getEquivalentID(const UnicodeString&, int32_t)(missing)Stable
+ICU 2.0
ulocbuilder.hvoid ulocbld_setScript(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uchar.hbool u_hasIDType(UChar32, UIdentifierType)Draft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setUnicodeLocaleKeyword(ULocaleBuilder*, const char*, int32_t, const char*, int32_t)Draft→Stable
ICU 74
uchar.henum UIdentifierStatus::U_ID_STATUS_ALLOWEDDraft→Stable
ICU 75
ulocbuilder.hvoid ulocbld_setVariant(ULocaleBuilder*, const char*, int32_t)Draft→Stable
ICU 74
uchar.henum UIdentifierStatus::U_ID_STATUS_RESTRICTEDDraft→Stable
ICU 75
unistr.hUnicodeString& icu::UnicodeString::remove(int32_t, int32_t length=static_cast< int32_t >(INT32_MAX))(missing)Stable
-ICU 2.0
uchar.henum UIdentifierType::U_ID_TYPE_DEFAULT_IGNORABLEDraft→Stable
ICU 75
unistr.hUnicodeString& icu::UnicodeString::removeBetween(int32_t, int32_t limit=static_cast< int32_t >(INT32_MAX))(missing)Stable
-ICU 2.0
uchar.henum UIdentifierType::U_ID_TYPE_DEPRECATEDDraft→Stable
ICU 75
unorm2.hconst UNormalizer2* unorm2_getNFKCSimpleCasefoldInstance(UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_EXCLUSIONDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_GARAY(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_INCLUSIONDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_GURUNG_KHEMA(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_LIMITED_USEDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_KIRAT_RAI(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_NOT_CHARACTERDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_OL_ONAL(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_NOT_NFKCDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_SUNUWAR(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_NOT_XIDDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_TODHRI(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_OBSOLETEDraft→Stable
ICU 75
uscript.henum UScriptCode::USCRIPT_TULU_TIGALARI(missing)Stable
-ICU 76
(Born Stable)uchar.henum UIdentifierType::U_ID_TYPE_RECOMMENDEDDraft→Stable
ICU 75
uspoof.hicu::UnicodeString& uspoof_getBidiSkeletonUnicodeString(const USpoofChecker*, UBiDiDirection, const icu::UnicodeString&, icu::UnicodeString&, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_TECHNICALDraft→Stable
ICU 75
uspoof.hint32_t uspoof_getBidiSkeleton(const USpoofChecker*, UBiDiDirection, const UChar*, int32_t, UChar*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UIdentifierType::U_ID_TYPE_UNCOMMON_USEDraft→Stable
ICU 75
uspoof.hint32_t uspoof_getBidiSkeletonUTF8(const USpoofChecker*, UBiDiDirection, const char*, int32_t, char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UProperty::UCHAR_IDENTIFIER_STATUSDraft→Stable
ICU 75
uspoof.huint32_t uspoof_areBidiConfusable(const USpoofChecker*, UBiDiDirection, const UChar*, int32_t, const UChar*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.henum UProperty::UCHAR_IDENTIFIER_TYPEDraft→Stable
ICU 75
uspoof.huint32_t uspoof_areBidiConfusableUTF8(const USpoofChecker*, UBiDiDirection, const char*, int32_t, const char*, int32_t, UErrorCode*)Draft→Stable
ICU 74
uchar.hint32_t u_getIDTypes(UChar32, UIdentifierType*, int32_t, UErrorCode*)Draft→Stable
ICU 75
uspoof.huint32_t uspoof_areBidiConfusableUnicodeString(const USpoofChecker*, UBiDiDirection, const icu::UnicodeString&, const icu::UnicodeString&, UErrorCode*)Draft→Stable
ICU 74
usimplenumberformatter.hvoid usnum_setMaximumIntegerDigits(USimpleNumber*, int32_t, UErrorCode*)Draft→Stable
ICU 75

(jump back to top)
-

Added in ICU 76

+

Added in ICU 77

- + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - + - + - + - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - +
FileAPIICU 75ICU 76FileAPIICU 76ICU 77
coll.hauto icu::Collator::equal_to() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::greater() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::greater_equal() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::less() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::less_equal() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::not_equal_to() const(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit icu::MeasureUnit::getLightSpeed()(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit icu::MeasureUnit::getNight()(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit* icu::MeasureUnit::createLightSpeed(UErrorCode&)(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit* icu::MeasureUnit::createNight(UErrorCode&)(missing)Draft
-ICU 76
messageformat2.hBuilder& icu::message2::MessageFormatter::Builder::setErrorHandlingBehavior(UMFErrorHandlingBehavior)(missing)Internal
-ICU 76
messageformat2.henum icu::message2::MessageFormatter::UMFErrorHandlingBehavior {}(missing)Internal
-ICU 76
messageformat2.henum icu::message2::MessageFormatter::UMFErrorHandlingBehavior::U_MF_BEST_EFFORT(missing)Internal
-ICU 76
messageformat2.henum icu::message2::MessageFormatter::UMFErrorHandlingBehavior::U_MF_STRICT(missing)Internal
-ICU 76
platform.h#define U_PF_HAIKU(missing)Internal
-
stringpiece.hicu::StringPiece::operator std::string_view() const(missing)Internal
+
locid.hstatic Locale icu::Locale::createFromName(StringPiece)(missing)Internal
uchar.henum UBlockCode::UBLOCK_EGYPTIAN_HIEROGLYPHS_EXTENDED_A(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_GARAY(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_GURUNG_KHEMA(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_KIRAT_RAI(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_MYANMAR_EXTENDED_C(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_OL_ONAL(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_SUNUWAR(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UBlockCode::UBLOCK_SYMBOLS_FOR_LEGACY_COMPUTING_SUPPLEMENT(missing)Stable
-ICU 76
(Born Stable)measunit.hMeasureUnit icu::MeasureUnit::withConstantDenominator(uint64_t, UErrorCode&) const(missing)Draft
+ICU 77
uchar.henum UBlockCode::UBLOCK_TODHRI(missing)Stable
-ICU 76
(Born Stable)measunit.hstatic MeasureUnit icu::MeasureUnit::getPortionPer1E9()(missing)Draft
+ICU 77
uchar.henum UBlockCode::UBLOCK_TULU_TIGALARI(missing)Stable
-ICU 76
(Born Stable)measunit.hstatic MeasureUnit* icu::MeasureUnit::createPortionPer1E9(UErrorCode&)(missing)Draft
+ICU 77
uchar.henum UIndicConjunctBreak::U_INCB_CONSONANT(missing)Draft
-ICU 76
measunit.huint64_t icu::MeasureUnit::getConstantDenominator(UErrorCode&) const(missing)Draft
+ICU 77
uchar.henum UIndicConjunctBreak::U_INCB_EXTEND(missing)Draft
-ICU 76
messageformat2_data_model.hBuilder& icu::message2::MFDataModel::Builder::addSelector(VariableName&&, UErrorCode&)(missing)Internal
+ICU 75
uchar.henum UIndicConjunctBreak::U_INCB_LINKER(missing)Draft
-ICU 76
resbund.hLocale icu::ResourceBundle::getLocale(ULocDataLocaleType, UErrorCode&) const(missing)Stable
+ICU 2.8
uchar.henum UIndicConjunctBreak::U_INCB_NONE(missing)Draft
-ICU 76
uchar.henum UIndicSyllabicCategory::U_INSC_REORDERING_KILLER(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UJoiningGroup::U_JG_KASHMIRI_YEH(missing)Stable
-ICU 76
(Born Stable)
uchar.henum UProperty::UCHAR_INDIC_CONJUNCT_BREAK(missing)Draft
-ICU 76
uchar.henum UProperty::UCHAR_MODIFIER_COMBINING_MARK(missing)Draft
-ICU 76
ucol.hU_HEADER_ONLY_NAMESPACE::collator::internal::Predicate< Compare, result >::Predicate(const UCollator*)(missing)Internal
-
ucol.hbool U_HEADER_ONLY_NAMESPACE::collator::internal::Predicate< Compare, result >::operator()(const T&, const U&) const(missing)Internal
-
ucol.hbool U_HEADER_ONLY_NAMESPACE::collator::internal::Predicate< Compare, result >::operator()(std::string_view, std::string_view) const(missing)Internal
-
uniset.hU_HEADER_NESTED_NAMESPACE::USetCodePoints icu::UnicodeSet::codePoints() const(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetElementIterator icu::UnicodeSet::begin() const(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetElementIterator icu::UnicodeSet::end() const(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetRanges icu::UnicodeSet::ranges() const(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetStrings icu::UnicodeSet::strings() const(missing)Draft
-ICU 76
unistr.hUNISTR_FROM_STRING_EXPLICIT icu::UnicodeString::UnicodeString(const S&)(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::append(const S&)(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::operator+=(const S&)(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::operator=(const S&)(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::remove(int32_t, int32_t length=static_cast< int32_t >(INT32_MAX))(missing)Stable
-ICU 2.0
unistr.hUnicodeString& icu::UnicodeString::removeBetween(int32_t, int32_t limit=static_cast< int32_t >(INT32_MAX))(missing)Stable
+
timezone.hstatic UnicodeString icu::TimeZone::getEquivalentID(const UnicodeString&, int32_t)(missing)Stable
ICU 2.0
unistr.hbool icu::UnicodeString::operator!=(const S&) const(missing)Draft
-ICU 76
unistr.hbool icu::UnicodeString::operator==(const S&) const(missing)Draft
-ICU 76
unistr.hicu::UnicodeString::operator std::u16string_view() const(missing)Draft
-ICU 76
unistr.hicu::UnicodeString::operator std::wstring_view() const(missing)Draft
-ICU 76
unistr.hstatic UnicodeString icu::UnicodeString::readOnlyAlias(const S&)(missing)Draft
-ICU 76
uset.hstd::u16string U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator* () const(missing)Draft
+ICU 77
unistr.hstatic UnicodeString icu::UnicodeString::readOnlyAlias(const UnicodeString&)(missing)Draft
-ICU 76
uscript.henum UScriptCode::USCRIPT_GARAY(missing)Stable
-ICU 76
(Born Stable)
uscript.henum UScriptCode::USCRIPT_GURUNG_KHEMA(missing)Stable
-ICU 76
(Born Stable)
uscript.henum UScriptCode::USCRIPT_KIRAT_RAI(missing)Stable
-ICU 76
(Born Stable)utypes.henum UErrorCode::U_MF_BAD_OPTION(missing)Internal
+ICU 77
uscript.henum UScriptCode::USCRIPT_OL_ONAL(missing)Stable
-ICU 76
(Born Stable)
uscript.henum UScriptCode::USCRIPT_SUNUWAR(missing)Stable
-ICU 76
(Born Stable)
uscript.henum UScriptCode::USCRIPT_TODHRI(missing)Stable
-ICU 76
(Born Stable)
uscript.henum UScriptCode::USCRIPT_TULU_TIGALARI(missing)Stable
-ICU 76
(Born Stable)
uset.hCodePointRange U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator* () const(missing)Draft
-ICU 76
uset.hUSetCodePointIterator & U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator++()(missing)Draft
-ICU 76
uset.hUSetCodePointIterator U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator++(int)(missing)Draft
-ICU 76
uset.hUSetCodePointIterator U_HEADER_ONLY_NAMESPACE::USetCodePoints::begin() const(missing)Draft
-ICU 76
uset.hUSetCodePointIterator U_HEADER_ONLY_NAMESPACE::USetCodePoints::end() const(missing)Draft
-ICU 76
+

+(jump back to top) +
+ +

Other existing drafts in ICU 77

+
+ + + + + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - -
FileAPIICU 76ICU 77
uset.hUSetElementIterator & U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator++()(missing)Draft
-ICU 76
coll.hauto icu::Collator::equal_to() constDraft
ICU 76
uset.hUSetElementIterator U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator++(int)(missing)Draft
-ICU 76
coll.hauto icu::Collator::greater() constDraft
ICU 76
uset.hUSetElementIterator U_HEADER_ONLY_NAMESPACE::USetElements::begin() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::greater_equal() constDraft
ICU 76
uset.hUSetElementIterator U_HEADER_ONLY_NAMESPACE::USetElements::end() const(missing)Draft
-ICU 76
coll.hauto icu::Collator::less() constDraft
ICU 76
uset.hUSetRangeIterator & U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator++()(missing)Draft
-ICU 76
coll.hauto icu::Collator::less_equal() constDraft
ICU 76
uset.hUSetRangeIterator U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator++(int)(missing)Draft
-ICU 76
coll.hauto icu::Collator::not_equal_to() constDraft
ICU 76
uset.hUSetRangeIterator U_HEADER_ONLY_NAMESPACE::USetRanges::begin() const(missing)Draft
-ICU 76
measfmt.hvoid icu::MeasureFormat::parseObject(const UnicodeString&, Formattable&, ParsePosition&) constDraft
ICU 53
uset.hUSetRangeIterator U_HEADER_ONLY_NAMESPACE::USetRanges::end() const(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit icu::MeasureUnit::getLightSpeed()Draft
ICU 76
uset.hUSetStringIterator & U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator++()(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit icu::MeasureUnit::getNight()Draft
ICU 76
uset.hUSetStringIterator U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator++(int)(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit* icu::MeasureUnit::createLightSpeed(UErrorCode&)Draft
ICU 76
uset.hUSetStringIterator U_HEADER_ONLY_NAMESPACE::USetStrings::begin() const(missing)Draft
-ICU 76
measunit.hstatic MeasureUnit* icu::MeasureUnit::createNight(UErrorCode&)Draft
ICU 76
uset.hUSetStringIterator U_HEADER_ONLY_NAMESPACE::USetStrings::end() const(missing)Draft
-ICU 76
uchar.henum UIndicConjunctBreak::U_INCB_CONSONANTDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetCodePointIterator::USetCodePointIterator(const USetCodePointIterator&)=default(missing)Draft
-ICU 76
uchar.henum UIndicConjunctBreak::U_INCB_EXTENDDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetCodePoints::USetCodePoints(const USet*)(missing)Draft
-ICU 76
uchar.henum UIndicConjunctBreak::U_INCB_LINKERDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetCodePoints::USetCodePoints(const USetCodePoints&)=default(missing)Draft
-ICU 76
uchar.henum UIndicConjunctBreak::U_INCB_NONEDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetElementIterator::USetElementIterator(const USetElementIterator&)=default(missing)Draft
-ICU 76
uchar.henum UProperty::UCHAR_INDIC_CONJUNCT_BREAKDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetElements::USetElements(const USet*)(missing)Draft
-ICU 76
uchar.henum UProperty::UCHAR_MODIFIER_COMBINING_MARKDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetElements::USetElements(const USetElements&)=default(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetCodePoints icu::UnicodeSet::codePoints() constDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetRangeIterator::USetRangeIterator(const USetRangeIterator&)=default(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetRanges icu::UnicodeSet::ranges() constDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetRanges::USetRanges(const USet*)(missing)Draft
-ICU 76
uniset.hU_HEADER_NESTED_NAMESPACE::USetStrings icu::UnicodeSet::strings() constDraft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetRanges::USetRanges(const USetRanges&)=default(missing)Draft
-ICU 76
unistr.hUNISTR_FROM_STRING_EXPLICIT icu::UnicodeString::UnicodeString(const S&)Draft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetStringIterator::USetStringIterator(const USetStringIterator&)=default(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::append(const S&)Draft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetStrings::USetStrings(const USet*)(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::operator+=(const S&)Draft
ICU 76
uset.hU_HEADER_ONLY_NAMESPACE::USetStrings::USetStrings(const USetStrings&)=default(missing)Draft
-ICU 76
unistr.hUnicodeString& icu::UnicodeString::operator=(const S&)Draft
ICU 76
uset.hUnicodeString U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator* () const(missing)Draft
-ICU 76
unistr.hbool icu::UnicodeString::operator!=(const S&) constDraft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator!=(const USetCodePointIterator&) const(missing)Draft
-ICU 76
unistr.hbool icu::UnicodeString::operator==(const S&) constDraft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator==(const USetCodePointIterator&) const(missing)Draft
-ICU 76
unistr.hicu::UnicodeString::operator std::u16string_view() constDraft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator!=(const USetElementIterator&) const(missing)Draft
-ICU 76
unistr.hicu::UnicodeString::operator std::wstring_view() constDraft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetElementIterator::operator==(const USetElementIterator&) const(missing)Draft
-ICU 76
unistr.hstatic UnicodeString icu::UnicodeString::readOnlyAlias(const S&)Draft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator!=(const USetRangeIterator&) const(missing)Draft
-ICU 76
unistr.hstatic UnicodeString icu::UnicodeString::readOnlyAlias(const UnicodeString&)Draft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator==(const USetRangeIterator&) const(missing)Draft
-ICU 76
uregex.henum URegexpFlag::UREGEX_CANON_EQDraft
ICU 2.4
uset.hbool U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator!=(const USetStringIterator&) const(missing)Draft
-ICU 76
uset.hCodePointRange U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator* () constDraft
ICU 76
uset.hbool U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator==(const USetStringIterator&) const(missing)Draft
-ICU 76
uset.hUSetCodePointIterator & U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator++()Draft
ICU 76
uset.hUChar32 U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator* () const(missing)Draft
-ICU 76
uset.hUSetCodePointIterator U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator++(int)Draft
ICU 76
uset.hconst UChar* uset_getString(const USet*, int32_t, int32_t*)(missing)Draft
-ICU 76
uset.hUSetCodePointIterator U_HEADER_ONLY_NAMESPACE::USetCodePoints::begin() constDraft
ICU 76
uset.hint32_t uset_getStringCount(const USet*)(missing)Draft
-ICU 76
uset.hUSetCodePointIterator U_HEADER_ONLY_NAMESPACE::USetCodePoints::end() constDraft
ICU 76
uset.hstd::u16string_view U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator* () const(missing)Draft
-ICU 76
uset.hUSetRangeIterator & U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator++()Draft
ICU 76
utypes.h#define U_SHOW_CPLUSPLUS_HEADER_API(missing)Internal
-
uset.hUSetRangeIterator U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator++(int)Draft
ICU 76
utypes.henum UErrorCode::U_MF_DUPLICATE_VARIANT_ERROR(missing)Internal
-ICU 76
-

-(jump back to top) -
- -

Other existing drafts in ICU 76

-
- - - - - - - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - - - +
FileAPIICU 75ICU 76
measfmt.hvoid icu::MeasureFormat::parseObject(const UnicodeString&, Formattable&, ParsePosition&) constDraft
ICU 53
uset.hUSetRangeIterator U_HEADER_ONLY_NAMESPACE::USetRanges::begin() constDraft
ICU 76
numberformatter.hUnlocalizedNumberFormatter icu::number::LocalizedNumberFormatter::withoutLocale() &&Draft
ICU 75
uset.hUSetRangeIterator U_HEADER_ONLY_NAMESPACE::USetRanges::end() constDraft
ICU 76
numberformatter.hUnlocalizedNumberFormatter icu::number::LocalizedNumberFormatter::withoutLocale() const &Draft
ICU 75
uset.hUSetStringIterator & U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator++()Draft
ICU 76
numberrangeformatter.hUnlocalizedNumberRangeFormatter icu::number::LocalizedNumberRangeFormatter::withoutLocale() &&Draft
ICU 75
uset.hUSetStringIterator U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator++(int)Draft
ICU 76
numberrangeformatter.hUnlocalizedNumberRangeFormatter icu::number::LocalizedNumberRangeFormatter::withoutLocale() const &Draft
ICU 75
uset.hUSetStringIterator U_HEADER_ONLY_NAMESPACE::USetStrings::begin() constDraft
ICU 76
simplenumberformatter.hvoid icu::number::SimpleNumber::setMaximumIntegerDigits(uint32_t, UErrorCode&)Draft
ICU 75
uset.hUSetStringIterator U_HEADER_ONLY_NAMESPACE::USetStrings::end() constDraft
ICU 76
uchar.hbool u_hasIDType(UChar32, UIdentifierType)Draft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetCodePointIterator::USetCodePointIterator(const USetCodePointIterator&)=defaultDraft
ICU 76
uchar.henum UIdentifierStatus::U_ID_STATUS_ALLOWEDDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetCodePoints::USetCodePoints(const USet*)Draft
ICU 76
uchar.henum UIdentifierStatus::U_ID_STATUS_RESTRICTEDDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetCodePoints::USetCodePoints(const USetCodePoints&)=defaultDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_DEFAULT_IGNORABLEDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetRangeIterator::USetRangeIterator(const USetRangeIterator&)=defaultDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_DEPRECATEDDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetRanges::USetRanges(const USet*)Draft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_EXCLUSIONDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetRanges::USetRanges(const USetRanges&)=defaultDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_INCLUSIONDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetStringIterator::USetStringIterator(const USetStringIterator&)=defaultDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_LIMITED_USEDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetStrings::USetStrings(const USet*)Draft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_NOT_CHARACTERDraft
ICU 75
uset.hU_HEADER_ONLY_NAMESPACE::USetStrings::USetStrings(const USetStrings&)=defaultDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_NOT_NFKCDraft
ICU 75
uset.hbool U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator!=(const USetCodePointIterator&) constDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_NOT_XIDDraft
ICU 75
uset.hbool U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator==(const USetCodePointIterator&) constDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_OBSOLETEDraft
ICU 75
uset.hbool U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator!=(const USetRangeIterator&) constDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_RECOMMENDEDDraft
ICU 75
uset.hbool U_HEADER_ONLY_NAMESPACE::USetRangeIterator::operator==(const USetRangeIterator&) constDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_TECHNICALDraft
ICU 75
uset.hbool U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator!=(const USetStringIterator&) constDraft
ICU 76
uchar.henum UIdentifierType::U_ID_TYPE_UNCOMMON_USEDraft
ICU 75
uset.hbool U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator==(const USetStringIterator&) constDraft
ICU 76
uchar.henum UProperty::UCHAR_IDENTIFIER_STATUSDraft
ICU 75
uset.hUChar32 U_HEADER_ONLY_NAMESPACE::USetCodePointIterator::operator* () constDraft
ICU 76
uchar.henum UProperty::UCHAR_IDENTIFIER_TYPEDraft
ICU 75
uset.hconst UChar* uset_getString(const USet*, int32_t, int32_t*)Draft
ICU 76
uchar.hint32_t u_getIDTypes(UChar32, UIdentifierType*, int32_t, UErrorCode*)Draft
ICU 75
uset.hint32_t uset_getStringCount(const USet*)Draft
ICU 76
uregex.henum URegexpFlag::UREGEX_CANON_EQDraft
ICU 2.4
usimplenumberformatter.hvoid usnum_setMaximumIntegerDigits(USimpleNumber*, int32_t, UErrorCode*)Draft
ICU 75
uset.hstd::u16string_view U_HEADER_ONLY_NAMESPACE::USetStringIterator::operator* () constDraft
ICU 76
@@ -1170,7 +563,7 @@

Signature Simplifications

(jump back to top)

-Contents generated by StableAPI tool on Mon Sep 30 11:33:51 PDT 2024
+Contents generated by StableAPI tool on Wed Feb 19 16:09:53 PST 2025
Copyright © 2017 and later: Unicode, Inc. and others.
License & terms of use: http://www.unicode.org/copyright.html
diff --git a/contrib/libs/icu/LICENSE b/contrib/libs/icu/LICENSE index 180db98fcc66..0b9efcd9092f 100644 --- a/contrib/libs/icu/LICENSE +++ b/contrib/libs/icu/LICENSE @@ -2,7 +2,7 @@ UNICODE LICENSE V3 COPYRIGHT AND PERMISSION NOTICE -Copyright © 2016-2024 Unicode, Inc. +Copyright © 2016-2025 Unicode, Inc. NOTICE TO USER: Carefully read the following legal agreement. BY DOWNLOADING, INSTALLING, COPYING OR OTHERWISE USING DATA FILES, AND/OR diff --git a/contrib/libs/icu/common/brkiter.cpp b/contrib/libs/icu/common/brkiter.cpp index 4d945cc17e2b..44a13ee6a2ac 100644 --- a/contrib/libs/icu/common/brkiter.cpp +++ b/contrib/libs/icu/common/brkiter.cpp @@ -59,7 +59,7 @@ BreakIterator::buildInstance(const Locale& loc, const char *type, UErrorCode &st { char fnbuff[256]; char ext[4]={'\0'}; - CharString actualLocale; + CharString actual; int32_t size; const char16_t* brkfname = nullptr; UResourceBundle brkRulesStack; @@ -94,7 +94,7 @@ BreakIterator::buildInstance(const Locale& loc, const char *type, UErrorCode &st // Use the string if we found it if (U_SUCCESS(status) && brkfname) { - actualLocale.append(ures_getLocaleInternal(brkName, &status), -1, status); + actual.append(ures_getLocaleInternal(brkName, &status), -1, status); char16_t* extStart=u_strchr(brkfname, 0x002e); int len = 0; @@ -123,10 +123,9 @@ BreakIterator::buildInstance(const Locale& loc, const char *type, UErrorCode &st if (U_SUCCESS(status) && result != nullptr) { U_LOCALE_BASED(locBased, *(BreakIterator*)result); - locBased.setLocaleIDs(ures_getLocaleByType(b, ULOC_VALID_LOCALE, &status), - actualLocale.data()); - uprv_strncpy(result->requestLocale, loc.getName(), ULOC_FULLNAME_CAPACITY); - result->requestLocale[ULOC_FULLNAME_CAPACITY-1] = 0; // always terminate + locBased.setLocaleIDs(ures_getLocaleByType(b, ULOC_VALID_LOCALE, &status), + actual.data(), status); + LocaleBased::setLocaleID(loc.getName(), result->requestLocale, status); } ures_close(b); @@ -206,26 +205,32 @@ BreakIterator::getAvailableLocales(int32_t& count) BreakIterator::BreakIterator() { - *validLocale = *actualLocale = *requestLocale = 0; } BreakIterator::BreakIterator(const BreakIterator &other) : UObject(other) { - uprv_strncpy(actualLocale, other.actualLocale, sizeof(actualLocale)); - uprv_strncpy(validLocale, other.validLocale, sizeof(validLocale)); - uprv_strncpy(requestLocale, other.requestLocale, sizeof(requestLocale)); + UErrorCode status = U_ZERO_ERROR; + U_LOCALE_BASED(locBased, *this); + locBased.setLocaleIDs(other.validLocale, other.actualLocale, status); + LocaleBased::setLocaleID(other.requestLocale, requestLocale, status); + U_ASSERT(U_SUCCESS(status)); } BreakIterator &BreakIterator::operator =(const BreakIterator &other) { if (this != &other) { - uprv_strncpy(actualLocale, other.actualLocale, sizeof(actualLocale)); - uprv_strncpy(validLocale, other.validLocale, sizeof(validLocale)); - uprv_strncpy(requestLocale, other.requestLocale, sizeof(requestLocale)); + UErrorCode status = U_ZERO_ERROR; + U_LOCALE_BASED(locBased, *this); + locBased.setLocaleIDs(other.validLocale, other.actualLocale, status); + LocaleBased::setLocaleID(other.requestLocale, requestLocale, status); + U_ASSERT(U_SUCCESS(status)); } return *this; } BreakIterator::~BreakIterator() { + delete validLocale; + delete actualLocale; + delete requestLocale; } // ------------------------------------------ @@ -394,7 +399,7 @@ BreakIterator::createInstance(const Locale& loc, int32_t kind, UErrorCode& statu // revisit this in ICU 3.0 and clean it up/fix it/remove it. if (U_SUCCESS(status) && (result != nullptr) && *actualLoc.getName() != 0) { U_LOCALE_BASED(locBased, *result); - locBased.setLocaleIDs(actualLoc.getName(), actualLoc.getName()); + locBased.setLocaleIDs(actualLoc.getName(), actualLoc.getName(), status); } return result; } @@ -488,6 +493,7 @@ BreakIterator::makeInstance(const Locale& loc, int32_t kind, UErrorCode& status) } if (U_FAILURE(status)) { + delete result; return nullptr; } @@ -496,20 +502,25 @@ BreakIterator::makeInstance(const Locale& loc, int32_t kind, UErrorCode& status) Locale BreakIterator::getLocale(ULocDataLocaleType type, UErrorCode& status) const { + if (U_FAILURE(status)) { + return Locale::getRoot(); + } if (type == ULOC_REQUESTED_LOCALE) { - return {requestLocale}; + return requestLocale == nullptr ? + Locale::getRoot() : Locale(requestLocale->data()); } - U_LOCALE_BASED(locBased, *this); - return locBased.getLocale(type, status); + return LocaleBased::getLocale(validLocale, actualLocale, type, status); } const char * BreakIterator::getLocaleID(ULocDataLocaleType type, UErrorCode& status) const { + if (U_FAILURE(status)) { + return nullptr; + } if (type == ULOC_REQUESTED_LOCALE) { - return requestLocale; + return requestLocale == nullptr ? "" : requestLocale->data(); } - U_LOCALE_BASED(locBased, *this); - return locBased.getLocaleID(type, status); + return LocaleBased::getLocaleID(validLocale, actualLocale, type, status); } @@ -536,8 +547,10 @@ int32_t BreakIterator::getRuleStatusVec(int32_t *fillInVec, int32_t capacity, UE } BreakIterator::BreakIterator (const Locale& valid, const Locale& actual) { + UErrorCode status = U_ZERO_ERROR; U_LOCALE_BASED(locBased, (*this)); - locBased.setLocaleIDs(valid, actual); + locBased.setLocaleIDs(valid.getName(), actual.getName(), status); + U_ASSERT(U_SUCCESS(status)); } U_NAMESPACE_END diff --git a/contrib/libs/icu/common/charstr.cpp b/contrib/libs/icu/common/charstr.cpp index f76cc8a4dc90..dadc829b0b56 100644 --- a/contrib/libs/icu/common/charstr.cpp +++ b/contrib/libs/icu/common/charstr.cpp @@ -70,6 +70,15 @@ CharString &CharString::copyFrom(const CharString &s, UErrorCode &errorCode) { return *this; } +CharString &CharString::copyFrom(StringPiece s, UErrorCode &errorCode) { + if (U_FAILURE(errorCode)) { + return *this; + } + len = 0; + append(s, errorCode); + return *this; +} + int32_t CharString::lastIndexOf(char c) const { for(int32_t i=len; i>0;) { if(buffer[--i]==c) { @@ -143,7 +152,7 @@ CharString &CharString::append(const char *s, int32_t sLength, UErrorCode &error return *this; } -CharString &CharString::appendNumber(int32_t number, UErrorCode &status) { +CharString &CharString::appendNumber(int64_t number, UErrorCode &status) { if (number < 0) { this->append('-', status); if (U_FAILURE(status)) { diff --git a/contrib/libs/icu/common/charstr.h b/contrib/libs/icu/common/charstr.h index 08283ca452ce..ea54ede735cd 100644 --- a/contrib/libs/icu/common/charstr.h +++ b/contrib/libs/icu/common/charstr.h @@ -74,6 +74,7 @@ class U_COMMON_API CharString : public UMemory { * use a UErrorCode where memory allocations might be needed. */ CharString ©From(const CharString &other, UErrorCode &errorCode); + CharString ©From(StringPiece s, UErrorCode &errorCode); UBool isEmpty() const { return len==0; } int32_t length() const { return len; } @@ -135,7 +136,7 @@ class U_COMMON_API CharString : public UMemory { } CharString &append(const char *s, int32_t sLength, UErrorCode &status); - CharString &appendNumber(int32_t number, UErrorCode &status); + CharString &appendNumber(int64_t number, UErrorCode &status); /** * Returns a writable buffer for appending and writes the buffer's capacity to diff --git a/contrib/libs/icu/common/localefallback_data.h b/contrib/libs/icu/common/localefallback_data.h index 0accf0324d7e..3b8ad8a3f398 100644 --- a/contrib/libs/icu/common/localefallback_data.h +++ b/contrib/libs/icu/common/localefallback_data.h @@ -11,11 +11,11 @@ //====================================================================== // Default script table const char scriptCodeChars[] = - "Aghb\0Ahom\0Arab\0Armi\0Armn\0Avst\0Bamu\0Bass\0Batk\0Beng\0Bopo\0" - "Brah\0Cakm\0Cans\0Cari\0Cham\0Cher\0Chrs\0Copt\0Cprt\0Cyrl\0Deva\0" - "Egyp\0Elym\0Ethi\0Geor\0Gong\0Gonm\0Goth\0Gran\0Grek\0Gujr\0Guru\0" - "Hang\0Hani\0Hans\0Hant\0Hebr\0Hluw\0Hmnp\0Ital\0Java\0Jpan\0Kali\0" - "Kana\0Kawi\0Khar\0Khmr\0Kits\0Knda\0Kore\0Lana\0Laoo\0Latf\0Latg\0" + "Aghb\0Ahom\0Arab\0Armi\0Armn\0Avst\0Bali\0Bamu\0Bass\0Batk\0Beng\0" + "Bopo\0Brah\0Cakm\0Cans\0Cari\0Cham\0Cher\0Chrs\0Copt\0Cprt\0Cyrl\0" + "Deva\0Egyp\0Elym\0Ethi\0Geor\0Gong\0Gonm\0Goth\0Gran\0Grek\0Gujr\0" + "Guru\0Hang\0Hani\0Hans\0Hant\0Hebr\0Hluw\0Hmnp\0Ital\0Java\0Jpan\0" + "Kali\0Kana\0Khar\0Khmr\0Kits\0Knda\0Kore\0Lana\0Laoo\0Latf\0Latg\0" "Lepc\0Lina\0Linb\0Lisu\0Lyci\0Lydi\0Mand\0Mani\0Marc\0Medf\0Merc\0" "Mlym\0Modi\0Mong\0Mroo\0Mtei\0Mymr\0Narb\0Newa\0Nkoo\0Nshu\0Ogam\0" "Olck\0Orkh\0Orya\0Osge\0Ougr\0Pauc\0Phli\0Phnx\0Plrd\0Prti\0Rjng\0" @@ -48,70 +48,71 @@ const char dsLocaleIDChars[] = "gbz\0gdb\0gdo\0gdx\0gez\0ggg\0gha\0ghe\0gho\0ghr\0ght\0gig\0gin\0" "gjk\0gju\0gld\0glh\0glk\0gml\0gmv\0gmy\0goe\0gof\0goj\0gok\0gon\0" "got\0gra\0grc\0grt\0gru\0gu\0gvr\0gwc\0gwf\0gwt\0gyo\0gzi\0ha_CM\0" - "ha_SD\0hac\0hak\0har\0haz\0hbo\0hdy\0he\0hi\0hif\0hii\0hit\0hkh\0" - "hlb\0hlu\0hmd\0hmj\0hmq\0hnd\0hne\0hnj\0hno\0hoc\0hoh\0hoj\0how\0" - "hoy\0hpo\0hrt\0hrz\0hsn\0hss\0htx\0hut\0huy\0huz\0hy\0hyw\0ii\0" - "imy\0inh\0int\0ior\0iru\0isk\0itk\0itl\0iu\0iw\0ja\0jad\0jat\0" - "jbe\0jbn\0jct\0jda\0jdg\0jdt\0jee\0jge\0ji\0jje\0jkm\0jml\0jna\0" - "jnd\0jnl\0jns\0jog\0jpa\0jpr\0jrb\0jul\0jun\0juy\0jya\0jye\0ka\0" - "kaa\0kap\0kaw\0kbd\0kbg\0kbu\0kby\0kca\0kcy\0kdq\0kdt\0ket\0kev\0" - "kex\0key\0kfa\0kfb\0kfc\0kfd\0kfe\0kfg\0kfh\0kfi\0kfk\0kfm\0kfp\0" - "kfq\0kfr\0kfs\0kfu\0kfx\0kfy\0kgj\0kgy\0khb\0khf\0khg\0khn\0kho\0" - "kht\0khv\0khw\0kif\0kim\0kip\0kjg\0kjh\0kjl\0kjo\0kjp\0kjt\0kjz\0" - "kk\0kk_AF\0kk_CN\0kk_IR\0kk_MN\0kkf\0kkh\0kkt\0kle\0klj\0klr\0" - "km\0kmj\0kmz\0kn\0knn\0ko\0koi\0kok\0kpt\0kpy\0kqd\0kqy\0kra\0" - "krc\0krk\0krr\0kru\0krv\0ks\0ksu\0ksw\0ksz\0ktb\0kte\0ktl\0ktp\0" - "ku_LB\0kuf\0kum\0kv\0kva\0kvq\0kvt\0kvx\0kvy\0kxf\0kxk\0kxm\0" - "kxp\0ky\0ky_CN\0kyu\0kyv\0kyw\0lab\0lad\0lae\0lah\0lbe\0lbf\0" - "lbj\0lbm\0lbo\0lbr\0lcp\0lep\0lez\0lhm\0lhs\0lif\0lis\0lkh\0lki\0" - "lmh\0lmn\0lo\0loy\0lpo\0lrc\0lrk\0lrl\0lsa\0lsd\0lss\0ltc\0luk\0" - "luu\0luv\0luz\0lwl\0lwm\0lya\0lzh\0mag\0mai\0man_GN\0mby\0mde\0" - "mdf\0mdx\0mdy\0mfa\0mfi\0mga\0mgp\0mhj\0mid\0mjl\0mjq\0mjr\0mjt\0" - "mju\0mjv\0mjz\0mk\0mkb\0mke\0mki\0mkm\0ml\0mlf\0mn\0mn_CN\0mnc\0" - "mni\0mnj\0mns\0mnw\0mpz\0mr\0mra\0mrd\0mrj\0mro\0mrr\0ms_CC\0" - "mtm\0mtr\0mud\0muk\0mut\0muv\0muz\0mve\0mvf\0mvy\0mvz\0mwr\0mwt\0" - "mww\0my\0mym\0myv\0myz\0mzn\0nan\0nao\0ncd\0ncq\0ndf\0ne\0neg\0" - "neh\0nei\0new\0ngt\0nio\0nit\0niv\0nli\0nlm\0nlx\0nmm\0nnp\0nod\0" - "noe\0nog\0noi\0non\0nos\0npb\0nqo\0nrn\0nsd\0nsf\0nsk\0nst\0nsv\0" - "nty\0ntz\0nwc\0nwx\0nyl\0nyq\0nyw\0oaa\0oac\0oar\0oav\0obm\0obr\0" - "odk\0oht\0oj\0ojs\0okm\0oko\0okz\0ola\0ole\0omk\0omp\0omr\0omx\0" - "oon\0or\0ort\0oru\0orv\0os\0osa\0osc\0osi\0ota\0otb\0otk\0oty\0" - "oui\0pa\0pa_PK\0pal\0paq\0pbt\0pcb\0pce\0pcf\0pcg\0pch\0pci\0" - "pcj\0peg\0peo\0pgd\0pgg\0pgl\0pgn\0phd\0phk\0phl\0phn\0pho\0phr\0" - "pht\0phu\0phv\0phw\0pi\0pka\0pkr\0plk\0pll\0pmh\0pnt\0pra\0prc\0" - "prd\0prt\0prx\0ps\0psh\0psi\0pst\0psu\0pum\0pwo\0pwr\0pww\0pyx\0" - "qxq\0raa\0rab\0raf\0rah\0raj\0rav\0rbb\0rdb\0rei\0rhg\0rji\0rjs\0" - "rka\0rki\0rkt\0rmi\0rmt\0rmz\0rsk\0rtw\0ru\0rue\0rut\0rwr\0ryu\0" - "sa\0sah\0sam\0sat\0saz\0sbn\0sbu\0sck\0scl\0scp\0sct\0scu\0scx\0" - "sd\0sd_IN\0sdb\0sdf\0sdg\0sdh\0sdr\0sds\0sel\0sfm\0sga\0sgh\0" - "sgj\0sgr\0sgt\0sgw\0sgy\0shd\0shi\0shm\0shn\0shu\0shv\0si\0sia\0" - "sip\0siy\0siz\0sjd\0sjp\0sjt\0skb\0skj\0skr\0smh\0smp\0smu\0smy\0" - "soa\0sog\0soi\0sou\0spt\0spv\0sqo\0sqq\0sqt\0sr\0srb\0srh\0srx\0" - "srz\0ssh\0sss\0sts\0stv\0sty\0suz\0sva\0swb\0swi\0swv\0sxu\0syc\0" - "syl\0syn\0syr\0syw\0ta\0tab\0taj\0tbk\0tcn\0tco\0tcx\0tcy\0tda\0" - "tdb\0tdd\0tdg\0tdh\0te\0tes\0tg\0tg_PK\0tge\0tgf\0th\0the\0thf\0" - "thi\0thl\0thm\0thq\0thr\0ths\0ti\0tig\0tij\0tin\0tjl\0tjo\0tkb\0" - "tks\0tkt\0tmr\0tnv\0tov\0tpu\0tra\0trg\0trm\0trw\0tsd\0tsj\0tt\0" - "tth\0tto\0tts\0ttz\0tvn\0twm\0txg\0txo\0tyr\0tyv\0ude\0udg\0udi\0" - "udm\0ug\0ug_KZ\0ug_MN\0uga\0ugh\0ugo\0uk\0uki\0ulc\0unr\0unr_NP\0" - "unx\0ur\0urk\0ush\0uum\0uz_AF\0uz_CN\0uzs\0vaa\0vaf\0vah\0vai\0" - "vas\0vav\0vay\0vgr\0vjk\0vmd\0vmh\0wal\0wbk\0wbq\0wbr\0wle\0wlo\0" - "wme\0wne\0wni\0wsg\0wsv\0wtm\0wuu\0xag\0xal\0xan\0xas\0xco\0xcr\0" - "xdq\0xhe\0xhm\0xis\0xka\0xkc\0xkf\0xkj\0xkp\0xlc\0xld\0xly\0xmf\0" - "xmn\0xmr\0xna\0xnr\0xpg\0xpi\0xpm\0xpr\0xrm\0xrn\0xsa\0xsr\0xtq\0" - "xub\0xuj\0xve\0xvi\0xwo\0xzh\0yai\0ybh\0ybi\0ydg\0yea\0yej\0yeu\0" - "ygp\0yhd\0yi\0yig\0yih\0yiv\0ykg\0ykh\0yna\0ynk\0yoi\0yoy\0yrk\0" - "ysd\0ysn\0ysp\0ysr\0ysy\0yud\0yue\0yue_CN\0yug\0yux\0ywq\0ywu\0" - "zau\0zba\0zch\0zdj\0zeh\0zen\0zgb\0zgh\0zgm\0zgn\0zh\0zh_AU\0" - "zh_BN\0zh_GB\0zh_GF\0zh_HK\0zh_ID\0zh_MO\0zh_PA\0zh_PF\0zh_PH\0" - "zh_SR\0zh_TH\0zh_TW\0zh_US\0zh_VN\0zhd\0zhx\0zko\0zkt\0zkz\0zlj\0" - "zln\0zlq\0zqe\0zrg\0zrp\0zum\0zwa\0zyg\0zyn\0zzj\0"; + "ha_SD\0hac\0hak\0hak_TW\0har\0haz\0hbo\0hdy\0he\0hi\0hif\0hii\0" + "hit\0hkh\0hlb\0hlu\0hmd\0hmj\0hmq\0hnd\0hne\0hnj\0hno\0hoc\0hoh\0" + "hoj\0how\0hoy\0hpo\0hrt\0hrz\0hsn\0hss\0htx\0hut\0huy\0huz\0hy\0" + "hyw\0ii\0imy\0inh\0int\0ior\0iru\0isk\0itk\0itl\0iu\0iw\0ja\0" + "jad\0jat\0jbe\0jbn\0jct\0jda\0jdg\0jdt\0jee\0jge\0ji\0jje\0jkm\0" + "jml\0jna\0jnd\0jnl\0jns\0jog\0jpa\0jpr\0jrb\0jul\0jun\0juy\0jya\0" + "jye\0ka\0kaa\0kap\0kaw\0kbd\0kbg\0kbu\0kby\0kca\0kcy\0kdq\0kdt\0" + "ket\0kev\0kex\0key\0kfa\0kfb\0kfc\0kfd\0kfe\0kfg\0kfh\0kfi\0kfk\0" + "kfm\0kfp\0kfq\0kfr\0kfs\0kfu\0kfx\0kfy\0kgj\0kgy\0khb\0khf\0khg\0" + "khn\0kho\0kht\0khv\0khw\0kif\0kim\0kip\0kjg\0kjh\0kjl\0kjo\0kjp\0" + "kjt\0kjz\0kk\0kk_AF\0kk_CN\0kk_IR\0kk_MN\0kkf\0kkh\0kkt\0kle\0" + "klj\0klr\0km\0kmj\0kmz\0kn\0knn\0ko\0koi\0kok\0kpt\0kpy\0kqd\0" + "kqy\0kra\0krc\0krk\0krr\0kru\0krv\0ks\0ksu\0ksw\0ksz\0ktb\0kte\0" + "ktl\0ktp\0ku_LB\0kuf\0kum\0kv\0kva\0kvq\0kvt\0kvx\0kvy\0kxf\0" + "kxk\0kxm\0kxp\0ky\0ky_CN\0kyu\0kyv\0kyw\0lab\0lad\0lae\0lah\0" + "lbe\0lbf\0lbj\0lbm\0lbo\0lbr\0lcp\0lep\0lez\0lhm\0lhs\0lif\0lis\0" + "lkh\0lki\0lmh\0lmn\0lo\0loy\0lpo\0lrc\0lrk\0lrl\0lsa\0lsd\0lss\0" + "ltc\0luk\0luu\0luv\0luz\0lwl\0lwm\0lya\0lzh\0lzz_GE\0mag\0mai\0" + "mby\0mde\0mdf\0mdx\0mdy\0mfa\0mfi\0mga\0mgp\0mhj\0mid\0mjl\0mjq\0" + "mjr\0mjt\0mju\0mjv\0mjz\0mk\0mkb\0mke\0mki\0mkm\0ml\0mlf\0mn\0" + "mn_CN\0mnc\0mni\0mnj\0mns\0mnw\0mpz\0mr\0mra\0mrd\0mrj\0mro\0" + "mrr\0ms_CC\0mtm\0mtr\0mud\0muk\0mut\0muv\0muz\0mve\0mvf\0mvy\0" + "mvz\0mwr\0mwt\0mww\0my\0mym\0myv\0myz\0mzn\0nan\0nan_TW\0nao\0" + "ncd\0ncq\0ndf\0ne\0neg\0neh\0nei\0new\0ngt\0nio\0nit\0niv\0nli\0" + "nlm\0nlx\0nmm\0nnp\0nod\0noe\0nog\0noi\0non\0nos\0npb\0nqo\0nrn\0" + "nsd\0nsf\0nsk\0nst\0nsv\0nty\0ntz\0nwc\0nwx\0nyl\0nyq\0nyw\0oaa\0" + "oac\0oar\0oav\0obm\0obr\0odk\0oht\0oj\0ojs\0okm\0oko\0okz\0ola\0" + "ole\0omk\0omp\0omr\0omx\0oon\0or\0ort\0oru\0orv\0os\0osa\0osc\0" + "osi\0ota\0otb\0otk\0oty\0oui\0pa\0pa_PK\0pal\0paq\0pbt\0pcb\0" + "pce\0pcf\0pcg\0pch\0pci\0pcj\0peg\0peo\0pgd\0pgg\0pgl\0pgn\0phd\0" + "phk\0phl\0phn\0pho\0phr\0pht\0phu\0phv\0phw\0pi\0pka\0pkr\0plk\0" + "pll\0pmh\0pnt\0pnt_RU\0pra\0prc\0prd\0prt\0prx\0ps\0psh\0psi\0" + "pst\0psu\0pum\0pwo\0pwr\0pww\0pyx\0qxq\0raa\0rab\0raf\0rah\0raj\0" + "rav\0rbb\0rdb\0rei\0rhg\0rji\0rjs\0rka\0rki\0rkt\0rmi\0rmt\0rmz\0" + "rsk\0rtw\0ru\0rue\0rut\0rwr\0ryu\0sa\0sah\0sam\0sat\0saz\0sbn\0" + "sbu\0sck\0scl\0scp\0sct\0scu\0scx\0sd\0sd_IN\0sdb\0sdf\0sdg\0" + "sdh\0sdr\0sds\0sel\0sfm\0sgh\0sgj\0sgr\0sgt\0sgw\0sgy\0shd\0shi\0" + "shm\0shn\0shu\0shv\0si\0sia\0sip\0siy\0siz\0sjd\0sjp\0sjt\0skb\0" + "skj\0skr\0smh\0smp\0smu\0smy\0soa\0sog\0soi\0sou\0spt\0spv\0sqo\0" + "sqq\0sqt\0sr\0srb\0srh\0srx\0srz\0ssh\0sss\0sts\0stv\0sty\0suz\0" + "sva\0swb\0swi\0swv\0sxu\0syc\0syl\0syn\0syr\0syw\0ta\0tab\0taj\0" + "tbk\0tcn\0tco\0tcx\0tcy\0tda\0tdb\0tdd\0tdg\0tdh\0te\0tes\0tg\0" + "tg_PK\0tge\0tgf\0th\0the\0thf\0thi\0thl\0thm\0thq\0thr\0ths\0" + "ti\0tig\0tij\0tin\0tjl\0tjo\0tkb\0tks\0tkt\0tmr\0tnv\0tov\0tpu\0" + "tra\0trg\0trm\0trw\0tsd\0tsj\0tt\0tth\0tto\0tts\0ttz\0tvn\0twm\0" + "txg\0txo\0tyr\0tyv\0ude\0udg\0udi\0udm\0ug\0ug_KZ\0ug_MN\0uga\0" + "ugh\0ugo\0uk\0uki\0ulc\0unr\0unr_NP\0unx\0ur\0urk\0ush\0uum\0" + "uz_AF\0uz_CN\0uzs\0vaa\0vaf\0vah\0vai\0vas\0vav\0vay\0vgr\0vjk\0" + "vmd\0vmh\0wal\0wbk\0wbq\0wbr\0wle\0wlo\0wme\0wne\0wni\0wsg\0wsv\0" + "wtm\0wuu\0xag\0xal\0xan\0xas\0xco\0xcr\0xdq\0xhe\0xhm\0xis\0xka\0" + "xkc\0xkf\0xkj\0xkp\0xlc\0xld\0xly\0xmf\0xmn\0xmr\0xna\0xnr\0xpg\0" + "xpi\0xpm\0xpr\0xrm\0xrn\0xsa\0xsr\0xtq\0xub\0xuj\0xve\0xvi\0xwo\0" + "xzh\0yai\0ybh\0ybi\0ydg\0yea\0yej\0yeu\0ygp\0yhd\0yi\0yig\0yih\0" + "yiv\0ykg\0ykh\0yna\0ynk\0yoi\0yoy\0yrk\0ysd\0ysn\0ysp\0ysr\0ysy\0" + "yud\0yue\0yue_CN\0yug\0yux\0ywq\0ywu\0zau\0zba\0zch\0zdj\0zeh\0" + "zen\0zgb\0zgh\0zgm\0zgn\0zh\0zh_AU\0zh_BN\0zh_GB\0zh_GF\0zh_HK\0" + "zh_ID\0zh_MO\0zh_PA\0zh_PF\0zh_PH\0zh_SR\0zh_TH\0zh_TW\0zh_US\0" + "zh_VN\0zhd\0zhx\0zko\0zkt\0zkz\0zlj\0zln\0zlq\0zqe\0zrg\0zrp\0" + "zum\0zwa\0zyg\0zyn\0zzj\0"; const int32_t defaultScriptTable[] = { 0, 330, // aaf -> Mlym 4, 10, // aao -> Arab - 8, 150, // aat -> Grek - 12, 100, // ab -> Cyrl + 8, 155, // aat -> Grek + 12, 105, // ab -> Cyrl 15, 10, // abh -> Arab 19, 435, // abl -> Rjng 23, 10, // abv -> Arab @@ -121,64 +122,64 @@ const int32_t defaultScriptTable[] = { 39, 10, // acx -> Arab 43, 10, // adf -> Arab 47, 555, // adx -> Tibt - 51, 100, // ady -> Cyrl + 51, 105, // ady -> Cyrl 55, 25, // ae -> Avst 58, 10, // aeb -> Arab 62, 10, // aec -> Arab 66, 10, // aee -> Arab 70, 10, // aeq -> Arab 74, 10, // afb -> Arab - 78, 105, // agi -> Deva - 82, 120, // agj -> Ethi - 86, 100, // agx -> Cyrl - 90, 120, // ahg -> Ethi + 78, 110, // agi -> Deva + 82, 125, // agj -> Ethi + 86, 105, // agx -> Cyrl + 90, 125, // ahg -> Ethi 94, 5, // aho -> Ahom - 98, 105, // ahr -> Deva + 98, 110, // ahr -> Deva 102, 10, // aib -> Arab 106, 495, // aii -> Syrc - 110, 185, // aij -> Hebr - 114, 220, // ain -> Kana + 110, 190, // aij -> Hebr + 114, 225, // ain -> Kana 118, 355, // aio -> Mymr 122, 10, // aiq -> Arab 126, 590, // akk -> Xsux - 130, 100, // akv -> Cyrl + 130, 105, // akv -> Cyrl 134, 260, // alk -> Laoo 138, 330, // all -> Mlym - 142, 100, // alr -> Cyrl - 146, 100, // alt -> Cyrl - 150, 120, // alw -> Ethi - 154, 120, // am -> Ethi - 157, 210, // ams -> Jpan + 142, 105, // alr -> Cyrl + 146, 105, // alt -> Cyrl + 150, 125, // alw -> Ethi + 154, 125, // am -> Ethi + 157, 215, // ams -> Jpan 161, 495, // amw -> Syrc - 165, 100, // ani -> Cyrl - 169, 105, // anp -> Deva - 173, 105, // anq -> Deva - 177, 105, // anr -> Deva - 181, 120, // anu -> Ethi - 185, 45, // aot -> Beng + 165, 105, // ani -> Cyrl + 169, 110, // anp -> Deva + 173, 110, // anq -> Deva + 177, 110, // anr -> Deva + 181, 125, // anu -> Ethi + 185, 50, // aot -> Beng 189, 10, // apc -> Arab 193, 10, // apd -> Arab - 197, 105, // aph -> Deva - 201, 100, // aqc -> Cyrl + 197, 110, // aph -> Deva + 201, 105, // aqc -> Cyrl 205, 10, // ar -> Arab 208, 15, // arc -> Armi 212, 10, // arq -> Arab 216, 10, // ars -> Arab 220, 10, // ary -> Arab 224, 10, // arz -> Arab - 228, 45, // as -> Beng + 228, 50, // as -> Beng 231, 465, // ase -> Sgnw 235, 10, // ask -> Arab - 239, 105, // asr -> Deva + 239, 110, // asr -> Deva 243, 10, // atn -> Arab - 247, 100, // atv -> Cyrl + 247, 105, // atv -> Cyrl 251, 10, // auj -> Arab 255, 10, // auz -> Arab - 259, 100, // av -> Cyrl + 259, 105, // av -> Cyrl 262, 10, // avd -> Arab 266, 10, // avl -> Arab - 270, 105, // awa -> Deva - 274, 120, // awn -> Ethi + 270, 110, // awa -> Deva + 274, 125, // awn -> Ethi 278, 20, // axm -> Armn 282, 10, // ayh -> Arab 286, 10, // ayl -> Arab @@ -186,971 +187,973 @@ const int32_t defaultScriptTable[] = { 294, 10, // ayp -> Arab 298, 10, // az_IQ -> Arab 304, 10, // az_IR -> Arab - 310, 100, // az_RU -> Cyrl + 310, 105, // az_RU -> Cyrl 316, 10, // azb -> Arab - 320, 100, // ba -> Cyrl + 320, 105, // ba -> Cyrl 323, 10, // bal -> Arab - 327, 105, // bap -> Deva - 331, 30, // bax -> Bamu - 335, 125, // bbl -> Geor - 339, 120, // bcq -> Ethi + 327, 110, // bap -> Deva + 331, 35, // bax -> Bamu + 335, 130, // bbl -> Geor + 339, 125, // bcq -> Ethi 343, 395, // bdv -> Orya 347, 10, // bdz -> Arab - 351, 100, // be -> Cyrl - 354, 105, // bee -> Deva + 351, 105, // be -> Cyrl + 354, 110, // bee -> Deva 358, 10, // bej -> Arab - 362, 105, // bfb -> Deva + 362, 110, // bfb -> Deva 366, 520, // bfq -> Taml 370, 10, // bft -> Arab 374, 555, // bfu -> Tibt 378, 395, // bfw -> Orya - 382, 105, // bfy -> Deva - 386, 105, // bfz -> Deva - 390, 100, // bg -> Cyrl - 393, 105, // bgc -> Deva - 397, 105, // bgd -> Deva + 382, 110, // bfy -> Deva + 386, 110, // bfz -> Deva + 390, 105, // bg -> Cyrl + 393, 110, // bgc -> Deva + 397, 110, // bgd -> Deva 401, 10, // bgn -> Arab 405, 10, // bgp -> Arab - 409, 105, // bgq -> Deva - 413, 105, // bgw -> Deva - 417, 150, // bgx -> Grek - 421, 105, // bha -> Deva - 425, 105, // bhb -> Deva - 429, 105, // bhd -> Deva + 409, 110, // bgq -> Deva + 413, 110, // bgw -> Deva + 417, 155, // bgx -> Grek + 421, 110, // bha -> Deva + 425, 110, // bhb -> Deva + 429, 110, // bhd -> Deva 433, 10, // bhe -> Arab - 437, 100, // bhh -> Cyrl - 441, 105, // bhi -> Deva - 445, 105, // bhj -> Deva + 437, 105, // bhh -> Cyrl + 441, 110, // bhi -> Deva + 445, 110, // bhj -> Deva 449, 10, // bhm -> Arab 453, 495, // bhn -> Syrc - 457, 105, // bho -> Deva - 461, 105, // bht -> Deva - 465, 105, // bhu -> Deva - 469, 105, // biy -> Deva + 457, 110, // bho -> Deva + 461, 110, // bht -> Deva + 465, 110, // bhu -> Deva + 469, 110, // biy -> Deva 473, 495, // bjf -> Syrc - 477, 105, // bjj -> Deva + 477, 110, // bjj -> Deva 481, 10, // bjm -> Arab 485, 555, // bkk -> Tibt 489, 355, // blk -> Mymr 493, 530, // blt -> Tavt - 497, 105, // bmj -> Deva - 501, 45, // bn -> Beng - 504, 105, // bns -> Deva + 497, 110, // bmj -> Deva + 501, 50, // bn -> Beng + 504, 110, // bns -> Deva 508, 555, // bo -> Tibt - 511, 100, // bph -> Cyrl - 515, 105, // bpx -> Deva - 519, 45, // bpy -> Beng + 511, 105, // bph -> Cyrl + 515, 110, // bpx -> Deva + 519, 50, // bpy -> Beng 523, 10, // bqi -> Arab - 527, 105, // bra -> Deva + 527, 110, // bra -> Deva 531, 235, // brb -> Khmr - 535, 105, // brd -> Deva + 535, 110, // brd -> Deva 539, 10, // brh -> Arab 543, 10, // brk -> Arab 547, 555, // bro -> Tibt 551, 260, // brv -> Laoo 555, 245, // brw -> Knda - 559, 105, // brx -> Deva + 559, 110, // brx -> Deva 563, 10, // bsh -> Arab 567, 10, // bsk -> Arab - 571, 35, // bsq -> Bass - 575, 120, // bst -> Ethi - 579, 40, // btd -> Batk - 583, 40, // btm -> Batk - 587, 105, // btv -> Deva - 591, 100, // bua -> Cyrl + 571, 40, // bsq -> Bass + 575, 125, // bst -> Ethi + 579, 45, // btd -> Batk + 583, 45, // btm -> Batk + 587, 110, // btv -> Deva + 591, 105, // bua -> Cyrl 595, 355, // bwe -> Mymr - 599, 100, // bxm -> Cyrl + 599, 105, // bxm -> Cyrl 603, 340, // bxu -> Mong - 607, 105, // byh -> Deva - 611, 120, // byn -> Ethi - 615, 105, // byw -> Deva + 607, 110, // byh -> Deva + 611, 125, // byn -> Ethi + 615, 110, // byw -> Deva 619, 550, // bzi -> Thai 623, 550, // cbn -> Thai - 627, 60, // ccp -> Cakm + 627, 65, // ccp -> Cakm 631, 535, // cde -> Telu - 635, 105, // cdh -> Deva - 639, 155, // cdi -> Gujr - 643, 105, // cdj -> Deva - 647, 105, // cdm -> Deva - 651, 175, // cdo -> Hans - 655, 45, // cdz -> Beng - 659, 100, // ce -> Cyrl + 635, 110, // cdh -> Deva + 639, 160, // cdi -> Gujr + 643, 110, // cdj -> Deva + 647, 110, // cdm -> Deva + 651, 180, // cdo -> Hans + 655, 50, // cdz -> Beng + 659, 105, // ce -> Cyrl 662, 555, // cgk -> Tibt 666, 10, // chg -> Arab - 670, 100, // chm -> Cyrl - 674, 80, // chr -> Cher - 678, 105, // chx -> Deva - 682, 105, // cih -> Deva + 670, 105, // chm -> Cyrl + 674, 85, // chr -> Cher + 678, 110, // chx -> Deva + 682, 110, // cih -> Deva 686, 10, // cja -> Arab - 690, 100, // cji -> Cyrl - 694, 75, // cjm -> Cham - 698, 175, // cjy -> Hans + 690, 105, // cji -> Cyrl + 694, 80, // cjm -> Cham + 698, 180, // cjy -> Hans 702, 10, // ckb -> Arab - 706, 100, // ckt -> Cyrl + 706, 105, // ckt -> Cyrl 710, 10, // clh -> Arab - 714, 100, // clw -> Cyrl + 714, 105, // clw -> Cyrl 718, 485, // cmg -> Soyo 722, 555, // cna -> Tibt - 726, 175, // cnp -> Hans + 726, 180, // cnp -> Hans 730, 550, // cog -> Thai - 734, 90, // cop -> Copt - 738, 150, // cpg -> Grek - 742, 65, // cr -> Cans - 745, 100, // crh -> Cyrl - 749, 65, // crj -> Cans - 753, 65, // crk -> Cans - 757, 65, // crl -> Cans - 761, 65, // crm -> Cans + 734, 95, // cop -> Copt + 738, 155, // cpg -> Grek + 742, 70, // cr -> Cans + 745, 105, // crh -> Cyrl + 749, 70, // crj -> Cans + 753, 70, // crk -> Cans + 757, 70, // crl -> Cans + 761, 70, // crm -> Cans 765, 355, // csh -> Mymr - 769, 175, // csp -> Hans - 773, 65, // csw -> Cans + 769, 180, // csp -> Hans + 773, 70, // csw -> Cans 777, 410, // ctd -> Pauc - 781, 45, // ctg -> Beng - 785, 105, // ctn -> Deva + 781, 50, // ctg -> Beng + 785, 110, // ctn -> Deva 789, 520, // ctt -> Taml 793, 520, // cty -> Taml - 797, 100, // cu -> Cyrl + 797, 105, // cu -> Cyrl 800, 255, // cuu -> Lana - 804, 100, // cv -> Cyrl - 807, 175, // czh -> Hans - 811, 185, // czk -> Hebr - 815, 105, // daq -> Deva - 819, 100, // dar -> Cyrl + 804, 105, // cv -> Cyrl + 807, 180, // czh -> Hans + 811, 190, // czk -> Hebr + 815, 110, // daq -> Deva + 819, 105, // dar -> Cyrl 823, 10, // dcc -> Arab - 827, 100, // ddo -> Cyrl + 827, 105, // ddo -> Cyrl 831, 10, // def -> Arab 835, 10, // deh -> Arab - 839, 45, // der -> Beng + 839, 50, // der -> Beng 843, 10, // dgl -> Arab - 847, 105, // dhi -> Deva - 851, 155, // dhn -> Gujr - 855, 105, // dho -> Deva - 859, 105, // dhw -> Deva + 847, 110, // dhi -> Deva + 851, 160, // dhn -> Gujr + 855, 110, // dho -> Deva + 859, 110, // dhw -> Deva 863, 555, // dka -> Tibt - 867, 100, // dlg -> Cyrl + 867, 105, // dlg -> Cyrl 871, 320, // dmf -> Medf 875, 10, // dmk -> Arab 879, 10, // dml -> Arab - 883, 100, // dng -> Cyrl + 883, 105, // dng -> Cyrl 887, 355, // dnu -> Mymr 891, 355, // dnv -> Mymr - 895, 105, // doi -> Deva - 899, 120, // dox -> Ethi + 895, 110, // doi -> Deva + 899, 125, // dox -> Ethi 903, 555, // dre -> Tibt - 907, 105, // drq -> Deva - 911, 120, // drs -> Ethi - 915, 105, // dry -> Deva + 907, 110, // drq -> Deva + 911, 125, // drs -> Ethi + 915, 110, // dry -> Deva 919, 395, // dso -> Orya - 923, 105, // dty -> Deva - 927, 155, // dub -> Gujr - 931, 105, // duh -> Deva - 935, 105, // dus -> Deva + 923, 110, // dty -> Deva + 927, 160, // dub -> Gujr + 931, 110, // duh -> Deva + 935, 110, // dus -> Deva 939, 545, // dv -> Thaa 942, 395, // dwk -> Orya - 946, 105, // dwz -> Deva + 946, 110, // dwz -> Deva 950, 555, // dz -> Tibt 953, 555, // dzl -> Tibt - 957, 150, // ecr -> Grek - 961, 95, // ecy -> Cprt - 965, 110, // egy -> Egyp - 969, 215, // eky -> Kali - 973, 150, // el -> Grek - 976, 105, // emg -> Deva - 980, 105, // emu -> Deva - 984, 100, // enf -> Cyrl - 988, 100, // enh -> Cyrl + 957, 155, // ecr -> Grek + 961, 100, // ecy -> Cprt + 965, 115, // egy -> Egyp + 969, 220, // eky -> Kali + 973, 155, // el -> Grek + 976, 110, // emg -> Deva + 980, 110, // emu -> Deva + 984, 105, // enf -> Cyrl + 988, 105, // enh -> Cyrl 992, 520, // era -> Taml - 996, 135, // esg -> Gonm + 996, 140, // esg -> Gonm 1000, 10, // esh -> Arab - 1004, 200, // ett -> Ital - 1008, 100, // eve -> Cyrl - 1012, 100, // evn -> Cyrl + 1004, 205, // ett -> Ital + 1008, 105, // eve -> Cyrl + 1012, 105, // evn -> Cyrl 1016, 10, // fa -> Arab 1019, 10, // fay -> Arab 1023, 10, // faz -> Arab 1027, 10, // fia -> Arab - 1031, 105, // fmu -> Deva + 1031, 110, // fmu -> Deva 1035, 10, // fub -> Arab - 1039, 175, // gan -> Hans + 1039, 180, // gan -> Hans 1043, 395, // gaq -> Orya - 1047, 155, // gas -> Gujr + 1047, 160, // gas -> Gujr 1051, 535, // gau -> Telu 1055, 395, // gbj -> Orya - 1059, 105, // gbk -> Deva - 1063, 155, // gbl -> Gujr - 1067, 105, // gbm -> Deva + 1059, 110, // gbk -> Deva + 1063, 160, // gbl -> Gujr + 1067, 110, // gbm -> Deva 1071, 10, // gbz -> Arab 1075, 395, // gdb -> Orya - 1079, 100, // gdo -> Cyrl - 1083, 105, // gdx -> Deva - 1087, 120, // gez -> Ethi + 1079, 105, // gdo -> Cyrl + 1083, 110, // gdx -> Deva + 1087, 125, // gez -> Ethi 1091, 10, // ggg -> Arab 1095, 10, // gha -> Arab - 1099, 105, // ghe -> Deva + 1099, 110, // ghe -> Deva 1103, 540, // gho -> Tfng 1107, 10, // ghr -> Arab 1111, 555, // ght -> Tibt 1115, 10, // gig -> Arab - 1119, 100, // gin -> Cyrl + 1119, 105, // gin -> Cyrl 1123, 10, // gjk -> Arab 1127, 10, // gju -> Arab - 1131, 100, // gld -> Cyrl + 1131, 105, // gld -> Cyrl 1135, 10, // glh -> Arab 1139, 10, // glk -> Arab 1143, 265, // gml -> Latf - 1147, 120, // gmv -> Ethi + 1147, 125, // gmv -> Ethi 1151, 285, // gmy -> Linb 1155, 555, // goe -> Tibt - 1159, 120, // gof -> Ethi - 1163, 105, // goj -> Deva - 1167, 105, // gok -> Deva - 1171, 105, // gon -> Deva - 1175, 140, // got -> Goth - 1179, 105, // gra -> Deva - 1183, 95, // grc -> Cprt - 1187, 45, // grt -> Beng - 1191, 120, // gru -> Ethi - 1195, 155, // gu -> Gujr - 1198, 105, // gvr -> Deva + 1159, 125, // gof -> Ethi + 1163, 110, // goj -> Deva + 1167, 110, // gok -> Deva + 1171, 110, // gon -> Deva + 1175, 145, // got -> Goth + 1179, 110, // gra -> Deva + 1183, 155, // grc -> Grek + 1187, 50, // grt -> Beng + 1191, 125, // gru -> Ethi + 1195, 160, // gu -> Gujr + 1198, 110, // gvr -> Deva 1202, 10, // gwc -> Arab 1206, 10, // gwf -> Arab 1210, 10, // gwt -> Arab - 1214, 105, // gyo -> Deva + 1214, 110, // gyo -> Deva 1218, 10, // gzi -> Arab 1222, 10, // ha_CM -> Arab 1228, 10, // ha_SD -> Arab 1234, 10, // hac -> Arab - 1238, 175, // hak -> Hans - 1242, 120, // har -> Ethi - 1246, 10, // haz -> Arab - 1250, 185, // hbo -> Hebr - 1254, 120, // hdy -> Ethi - 1258, 185, // he -> Hebr - 1261, 105, // hi -> Deva - 1264, 105, // hif -> Deva - 1268, 505, // hii -> Takr - 1272, 590, // hit -> Xsux - 1276, 10, // hkh -> Arab - 1280, 105, // hlb -> Deva - 1284, 190, // hlu -> Hluw - 1288, 425, // hmd -> Plrd - 1292, 50, // hmj -> Bopo - 1296, 50, // hmq -> Bopo - 1300, 10, // hnd -> Arab - 1304, 105, // hne -> Deva - 1308, 195, // hnj -> Hmnp - 1312, 10, // hno -> Arab - 1316, 105, // hoc -> Deva - 1320, 10, // hoh -> Arab - 1324, 105, // hoj -> Deva - 1328, 170, // how -> Hani - 1332, 105, // hoy -> Deva - 1336, 355, // hpo -> Mymr - 1340, 495, // hrt -> Syrc - 1344, 10, // hrz -> Arab - 1348, 175, // hsn -> Hans - 1352, 10, // hss -> Arab - 1356, 590, // htx -> Xsux - 1360, 105, // hut -> Deva - 1364, 185, // huy -> Hebr - 1368, 100, // huz -> Cyrl - 1372, 20, // hy -> Armn - 1375, 20, // hyw -> Armn - 1379, 595, // ii -> Yiii - 1382, 295, // imy -> Lyci - 1386, 100, // inh -> Cyrl - 1390, 355, // int -> Mymr - 1394, 120, // ior -> Ethi - 1398, 520, // iru -> Taml - 1402, 10, // isk -> Arab - 1406, 185, // itk -> Hebr - 1410, 100, // itl -> Cyrl - 1414, 65, // iu -> Cans - 1417, 185, // iw -> Hebr - 1420, 210, // ja -> Jpan - 1423, 10, // jad -> Arab - 1427, 10, // jat -> Arab - 1431, 185, // jbe -> Hebr - 1435, 10, // jbn -> Arab - 1439, 100, // jct -> Cyrl - 1443, 555, // jda -> Tibt - 1447, 10, // jdg -> Arab - 1451, 100, // jdt -> Cyrl - 1455, 105, // jee -> Deva - 1459, 125, // jge -> Geor - 1463, 185, // ji -> Hebr - 1466, 165, // jje -> Hang - 1470, 355, // jkm -> Mymr - 1474, 105, // jml -> Deva - 1478, 505, // jna -> Takr - 1482, 10, // jnd -> Arab - 1486, 105, // jnl -> Deva - 1490, 105, // jns -> Deva - 1494, 10, // jog -> Arab - 1498, 185, // jpa -> Hebr - 1502, 185, // jpr -> Hebr - 1506, 185, // jrb -> Hebr - 1510, 105, // jul -> Deva - 1514, 395, // jun -> Orya - 1518, 395, // juy -> Orya - 1522, 555, // jya -> Tibt - 1526, 185, // jye -> Hebr - 1530, 125, // ka -> Geor - 1533, 100, // kaa -> Cyrl - 1537, 100, // kap -> Cyrl - 1541, 225, // kaw -> Kawi - 1545, 100, // kbd -> Cyrl - 1549, 555, // kbg -> Tibt - 1553, 10, // kbu -> Arab - 1557, 10, // kby -> Arab - 1561, 100, // kca -> Cyrl - 1565, 10, // kcy -> Arab - 1569, 45, // kdq -> Beng - 1573, 550, // kdt -> Thai - 1577, 100, // ket -> Cyrl - 1581, 330, // kev -> Mlym - 1585, 105, // kex -> Deva - 1589, 535, // key -> Telu - 1593, 245, // kfa -> Knda - 1597, 105, // kfb -> Deva - 1601, 535, // kfc -> Telu - 1605, 245, // kfd -> Knda - 1609, 520, // kfe -> Taml - 1613, 245, // kfg -> Knda - 1617, 330, // kfh -> Mlym - 1621, 520, // kfi -> Taml - 1625, 105, // kfk -> Deva - 1629, 10, // kfm -> Arab - 1633, 105, // kfp -> Deva - 1637, 105, // kfq -> Deva - 1641, 105, // kfr -> Deva - 1645, 105, // kfs -> Deva - 1649, 105, // kfu -> Deva - 1653, 105, // kfx -> Deva - 1657, 105, // kfy -> Deva - 1661, 105, // kgj -> Deva - 1665, 105, // kgy -> Deva - 1669, 515, // khb -> Talu - 1673, 550, // khf -> Thai - 1677, 555, // khg -> Tibt - 1681, 105, // khn -> Deva - 1685, 55, // kho -> Brah - 1689, 355, // kht -> Mymr - 1693, 100, // khv -> Cyrl - 1697, 10, // khw -> Arab - 1701, 105, // kif -> Deva - 1705, 100, // kim -> Cyrl - 1709, 105, // kip -> Deva - 1713, 260, // kjg -> Laoo - 1717, 100, // kjh -> Cyrl - 1721, 105, // kjl -> Deva - 1725, 105, // kjo -> Deva - 1729, 355, // kjp -> Mymr - 1733, 550, // kjt -> Thai - 1737, 555, // kjz -> Tibt - 1741, 100, // kk -> Cyrl - 1744, 10, // kk_AF -> Arab - 1750, 10, // kk_CN -> Arab - 1756, 10, // kk_IR -> Arab - 1762, 10, // kk_MN -> Arab - 1768, 555, // kkf -> Tibt - 1772, 255, // kkh -> Lana - 1776, 105, // kkt -> Deva - 1780, 105, // kle -> Deva - 1784, 10, // klj -> Arab - 1788, 105, // klr -> Deva - 1792, 235, // km -> Khmr - 1795, 105, // kmj -> Deva - 1799, 10, // kmz -> Arab - 1803, 245, // kn -> Knda - 1806, 105, // knn -> Deva - 1810, 250, // ko -> Kore - 1813, 100, // koi -> Cyrl - 1817, 105, // kok -> Deva - 1821, 100, // kpt -> Cyrl - 1825, 100, // kpy -> Cyrl - 1829, 495, // kqd -> Syrc - 1833, 120, // kqy -> Ethi - 1837, 105, // kra -> Deva - 1841, 100, // krc -> Cyrl - 1845, 100, // krk -> Cyrl - 1849, 235, // krr -> Khmr - 1853, 105, // kru -> Deva - 1857, 235, // krv -> Khmr - 1861, 10, // ks -> Arab - 1864, 355, // ksu -> Mymr - 1868, 355, // ksw -> Mymr - 1872, 105, // ksz -> Deva - 1876, 120, // ktb -> Ethi - 1880, 105, // kte -> Deva - 1884, 10, // ktl -> Arab - 1888, 425, // ktp -> Plrd - 1892, 10, // ku_LB -> Arab - 1898, 260, // kuf -> Laoo - 1902, 100, // kum -> Cyrl - 1906, 100, // kv -> Cyrl - 1909, 100, // kva -> Cyrl - 1913, 355, // kvq -> Mymr - 1917, 355, // kvt -> Mymr - 1921, 10, // kvx -> Arab - 1925, 215, // kvy -> Kali - 1929, 355, // kxf -> Mymr - 1933, 355, // kxk -> Mymr - 1937, 550, // kxm -> Thai - 1941, 10, // kxp -> Arab - 1945, 100, // ky -> Cyrl - 1948, 10, // ky_CN -> Arab - 1954, 215, // kyu -> Kali - 1958, 105, // kyv -> Deva - 1962, 105, // kyw -> Deva - 1966, 280, // lab -> Lina - 1970, 185, // lad -> Hebr - 1974, 105, // lae -> Deva - 1978, 10, // lah -> Arab - 1982, 100, // lbe -> Cyrl - 1986, 105, // lbf -> Deva - 1990, 555, // lbj -> Tibt - 1994, 105, // lbm -> Deva - 1998, 260, // lbo -> Laoo - 2002, 105, // lbr -> Deva - 2006, 550, // lcp -> Thai - 2010, 275, // lep -> Lepc - 2014, 100, // lez -> Cyrl - 2018, 105, // lhm -> Deva - 2022, 495, // lhs -> Syrc - 2026, 105, // lif -> Deva - 2030, 290, // lis -> Lisu - 2034, 555, // lkh -> Tibt - 2038, 10, // lki -> Arab - 2042, 105, // lmh -> Deva - 2046, 535, // lmn -> Telu - 2050, 260, // lo -> Laoo - 2053, 105, // loy -> Deva - 2057, 425, // lpo -> Plrd - 2061, 10, // lrc -> Arab - 2065, 10, // lrk -> Arab - 2069, 10, // lrl -> Arab - 2073, 10, // lsa -> Arab - 2077, 185, // lsd -> Hebr - 2081, 10, // lss -> Arab - 2085, 180, // ltc -> Hant - 2089, 555, // luk -> Tibt - 2093, 105, // luu -> Deva - 2097, 10, // luv -> Arab - 2101, 10, // luz -> Arab - 2105, 550, // lwl -> Thai - 2109, 550, // lwm -> Thai - 2113, 555, // lya -> Tibt - 2117, 175, // lzh -> Hans - 2121, 105, // mag -> Deva - 2125, 105, // mai -> Deva - 2129, 370, // man_GN -> Nkoo - 2136, 10, // mby -> Arab - 2140, 10, // mde -> Arab - 2144, 100, // mdf -> Cyrl - 2148, 120, // mdx -> Ethi - 2152, 120, // mdy -> Ethi - 2156, 10, // mfa -> Arab - 2160, 10, // mfi -> Arab - 2164, 270, // mga -> Latg - 2168, 105, // mgp -> Deva - 2172, 10, // mhj -> Arab - 2176, 305, // mid -> Mand - 2180, 105, // mjl -> Deva - 2184, 330, // mjq -> Mlym - 2188, 330, // mjr -> Mlym - 2192, 105, // mjt -> Deva - 2196, 535, // mju -> Telu - 2200, 330, // mjv -> Mlym - 2204, 105, // mjz -> Deva - 2208, 100, // mk -> Cyrl - 2211, 105, // mkb -> Deva - 2215, 105, // mke -> Deva - 2219, 10, // mki -> Arab - 2223, 550, // mkm -> Thai - 2227, 330, // ml -> Mlym - 2230, 550, // mlf -> Thai - 2234, 100, // mn -> Cyrl - 2237, 340, // mn_CN -> Mong - 2243, 340, // mnc -> Mong - 2247, 45, // mni -> Beng - 2251, 10, // mnj -> Arab - 2255, 100, // mns -> Cyrl - 2259, 355, // mnw -> Mymr - 2263, 550, // mpz -> Thai - 2267, 105, // mr -> Deva - 2270, 550, // mra -> Thai - 2274, 105, // mrd -> Deva - 2278, 100, // mrj -> Cyrl - 2282, 345, // mro -> Mroo - 2286, 105, // mrr -> Deva - 2290, 10, // ms_CC -> Arab - 2296, 100, // mtm -> Cyrl - 2300, 105, // mtr -> Deva - 2304, 100, // mud -> Cyrl - 2308, 555, // muk -> Tibt - 2312, 105, // mut -> Deva - 2316, 520, // muv -> Taml - 2320, 120, // muz -> Ethi - 2324, 10, // mve -> Arab - 2328, 340, // mvf -> Mong - 2332, 10, // mvy -> Arab - 2336, 120, // mvz -> Ethi - 2340, 105, // mwr -> Deva - 2344, 355, // mwt -> Mymr - 2348, 195, // mww -> Hmnp - 2352, 355, // my -> Mymr - 2355, 120, // mym -> Ethi - 2359, 100, // myv -> Cyrl - 2363, 305, // myz -> Mand - 2367, 10, // mzn -> Arab - 2371, 175, // nan -> Hans - 2375, 105, // nao -> Deva - 2379, 105, // ncd -> Deva - 2383, 260, // ncq -> Laoo - 2387, 100, // ndf -> Cyrl - 2391, 105, // ne -> Deva - 2394, 100, // neg -> Cyrl - 2398, 555, // neh -> Tibt - 2402, 590, // nei -> Xsux - 2406, 105, // new -> Deva - 2410, 260, // ngt -> Laoo - 2414, 100, // nio -> Cyrl - 2418, 535, // nit -> Telu - 2422, 100, // niv -> Cyrl - 2426, 10, // nli -> Arab - 2430, 10, // nlm -> Arab - 2434, 105, // nlx -> Deva - 2438, 105, // nmm -> Deva - 2442, 580, // nnp -> Wcho - 2446, 255, // nod -> Lana - 2450, 105, // noe -> Deva - 2454, 100, // nog -> Cyrl - 2458, 105, // noi -> Deva - 2462, 445, // non -> Runr - 2466, 595, // nos -> Yiii - 2470, 555, // npb -> Tibt - 2474, 370, // nqo -> Nkoo - 2478, 445, // nrn -> Runr - 2482, 595, // nsd -> Yiii - 2486, 595, // nsf -> Yiii - 2490, 65, // nsk -> Cans - 2494, 560, // nst -> Tnsa - 2498, 595, // nsv -> Yiii - 2502, 595, // nty -> Yiii - 2506, 10, // ntz -> Arab - 2510, 365, // nwc -> Newa - 2514, 105, // nwx -> Deva - 2518, 550, // nyl -> Thai - 2522, 10, // nyq -> Arab - 2526, 550, // nyw -> Thai - 2530, 100, // oaa -> Cyrl - 2534, 100, // oac -> Cyrl - 2538, 495, // oar -> Syrc - 2542, 125, // oav -> Geor - 2546, 420, // obm -> Phnx - 2550, 355, // obr -> Mymr - 2554, 10, // odk -> Arab - 2558, 590, // oht -> Xsux - 2562, 65, // oj -> Cans - 2565, 65, // ojs -> Cans - 2569, 165, // okm -> Hang - 2573, 170, // oko -> Hani - 2577, 235, // okz -> Khmr - 2581, 105, // ola -> Deva - 2585, 555, // ole -> Tibt - 2589, 100, // omk -> Cyrl - 2593, 350, // omp -> Mtei - 2597, 335, // omr -> Modi - 2601, 355, // omx -> Mymr - 2605, 105, // oon -> Deva - 2609, 395, // or -> Orya - 2612, 535, // ort -> Telu - 2616, 10, // oru -> Arab - 2620, 100, // orv -> Cyrl - 2624, 100, // os -> Cyrl - 2627, 400, // osa -> Osge - 2631, 200, // osc -> Ital - 2635, 205, // osi -> Java - 2639, 10, // ota -> Arab - 2643, 555, // otb -> Tibt - 2647, 390, // otk -> Orkh - 2651, 145, // oty -> Gran - 2655, 405, // oui -> Ougr - 2659, 160, // pa -> Guru - 2662, 10, // pa_PK -> Arab - 2668, 415, // pal -> Phli - 2672, 100, // paq -> Cyrl - 2676, 10, // pbt -> Arab - 2680, 235, // pcb -> Khmr - 2684, 355, // pce -> Mymr - 2688, 330, // pcf -> Mlym - 2692, 330, // pcg -> Mlym - 2696, 105, // pch -> Deva - 2700, 105, // pci -> Deva - 2704, 535, // pcj -> Telu - 2708, 395, // peg -> Orya - 2712, 585, // peo -> Xpeo - 2716, 230, // pgd -> Khar - 2720, 105, // pgg -> Deva - 2724, 380, // pgl -> Ogam - 2728, 200, // pgn -> Ital - 2732, 105, // phd -> Deva - 2736, 355, // phk -> Mymr - 2740, 10, // phl -> Arab - 2744, 420, // phn -> Phnx - 2748, 260, // pho -> Laoo - 2752, 10, // phr -> Arab - 2756, 550, // pht -> Thai - 2760, 550, // phu -> Thai - 2764, 10, // phv -> Arab - 2768, 105, // phw -> Deva - 2772, 470, // pi -> Sinh - 2775, 55, // pka -> Brah - 2779, 330, // pkr -> Mlym - 2783, 10, // plk -> Arab - 2787, 355, // pll -> Mymr - 2791, 55, // pmh -> Brah - 2795, 150, // pnt -> Grek - 2799, 230, // pra -> Khar - 2803, 10, // prc -> Arab - 2807, 10, // prd -> Arab - 2811, 550, // prt -> Thai - 2815, 10, // prx -> Arab - 2819, 10, // ps -> Arab - 2822, 10, // psh -> Arab - 2826, 10, // psi -> Arab - 2830, 10, // pst -> Arab - 2834, 55, // psu -> Brah - 2838, 105, // pum -> Deva - 2842, 355, // pwo -> Mymr - 2846, 105, // pwr -> Deva - 2850, 550, // pww -> Thai - 2854, 355, // pyx -> Mymr - 2858, 10, // qxq -> Arab - 2862, 105, // raa -> Deva - 2866, 105, // rab -> Deva - 2870, 105, // raf -> Deva - 2874, 45, // rah -> Beng - 2878, 105, // raj -> Deva - 2882, 105, // rav -> Deva - 2886, 355, // rbb -> Mymr - 2890, 10, // rdb -> Arab - 2894, 395, // rei -> Orya - 2898, 440, // rhg -> Rohg - 2902, 105, // rji -> Deva - 2906, 105, // rjs -> Deva - 2910, 235, // rka -> Khmr - 2914, 355, // rki -> Mymr - 2918, 45, // rkt -> Beng - 2922, 20, // rmi -> Armn - 2926, 10, // rmt -> Arab - 2930, 355, // rmz -> Mymr - 2934, 100, // rsk -> Cyrl - 2938, 105, // rtw -> Deva - 2942, 100, // ru -> Cyrl - 2945, 100, // rue -> Cyrl - 2949, 100, // rut -> Cyrl - 2953, 105, // rwr -> Deva - 2957, 220, // ryu -> Kana - 2961, 105, // sa -> Deva - 2964, 100, // sah -> Cyrl - 2968, 450, // sam -> Samr - 2972, 385, // sat -> Olck - 2976, 460, // saz -> Saur - 2980, 10, // sbn -> Arab - 2984, 555, // sbu -> Tibt - 2988, 105, // sck -> Deva - 2992, 10, // scl -> Arab - 2996, 105, // scp -> Deva - 3000, 260, // sct -> Laoo - 3004, 505, // scu -> Takr - 3008, 150, // scx -> Grek - 3012, 10, // sd -> Arab - 3015, 105, // sd_IN -> Deva - 3021, 10, // sdb -> Arab - 3025, 10, // sdf -> Arab - 3029, 10, // sdg -> Arab - 3033, 10, // sdh -> Arab - 3037, 45, // sdr -> Beng - 3041, 10, // sds -> Arab - 3045, 100, // sel -> Cyrl - 3049, 425, // sfm -> Plrd - 3053, 380, // sga -> Ogam - 3057, 100, // sgh -> Cyrl - 3061, 105, // sgj -> Deva - 3065, 10, // sgr -> Arab - 3069, 555, // sgt -> Tibt - 3073, 120, // sgw -> Ethi - 3077, 10, // sgy -> Arab - 3081, 10, // shd -> Arab - 3085, 540, // shi -> Tfng - 3089, 10, // shm -> Arab - 3093, 355, // shn -> Mymr - 3097, 10, // shu -> Arab - 3101, 10, // shv -> Arab - 3105, 470, // si -> Sinh - 3108, 100, // sia -> Cyrl - 3112, 555, // sip -> Tibt - 3116, 10, // siy -> Arab - 3120, 10, // siz -> Arab - 3124, 100, // sjd -> Cyrl - 3128, 105, // sjp -> Deva - 3132, 100, // sjt -> Cyrl - 3136, 550, // skb -> Thai - 3140, 105, // skj -> Deva - 3144, 10, // skr -> Arab - 3148, 595, // smh -> Yiii - 3152, 450, // smp -> Samr - 3156, 235, // smu -> Khmr - 3160, 10, // smy -> Arab - 3164, 530, // soa -> Tavt - 3168, 475, // sog -> Sogd - 3172, 105, // soi -> Deva - 3176, 550, // sou -> Thai - 3180, 555, // spt -> Tibt - 3184, 395, // spv -> Orya - 3188, 10, // sqo -> Arab - 3192, 260, // sqq -> Laoo - 3196, 10, // sqt -> Arab - 3200, 100, // sr -> Cyrl - 3203, 480, // srb -> Sora - 3207, 10, // srh -> Arab - 3211, 105, // srx -> Deva - 3215, 10, // srz -> Arab - 3219, 10, // ssh -> Arab - 3223, 260, // sss -> Laoo - 3227, 10, // sts -> Arab - 3231, 120, // stv -> Ethi - 3235, 100, // sty -> Cyrl - 3239, 490, // suz -> Sunu - 3243, 125, // sva -> Geor - 3247, 10, // swb -> Arab - 3251, 170, // swi -> Hani - 3255, 105, // swv -> Deva - 3259, 445, // sxu -> Runr - 3263, 495, // syc -> Syrc - 3267, 45, // syl -> Beng - 3271, 495, // syn -> Syrc - 3275, 495, // syr -> Syrc - 3279, 105, // syw -> Deva - 3283, 520, // ta -> Taml - 3286, 100, // tab -> Cyrl - 3290, 105, // taj -> Deva - 3294, 500, // tbk -> Tagb - 3298, 555, // tcn -> Tibt - 3302, 355, // tco -> Mymr - 3306, 520, // tcx -> Taml - 3310, 245, // tcy -> Knda - 3314, 540, // tda -> Tfng - 3318, 105, // tdb -> Deva - 3322, 510, // tdd -> Tale - 3326, 105, // tdg -> Deva - 3330, 105, // tdh -> Deva - 3334, 535, // te -> Telu - 3337, 205, // tes -> Java - 3341, 100, // tg -> Cyrl - 3344, 10, // tg_PK -> Arab - 3350, 105, // tge -> Deva - 3354, 555, // tgf -> Tibt - 3358, 550, // th -> Thai - 3361, 105, // the -> Deva - 3365, 105, // thf -> Deva - 3369, 510, // thi -> Tale - 3373, 105, // thl -> Deva - 3377, 550, // thm -> Thai - 3381, 105, // thq -> Deva - 3385, 105, // thr -> Deva - 3389, 105, // ths -> Deva - 3393, 120, // ti -> Ethi - 3396, 120, // tig -> Ethi - 3400, 105, // tij -> Deva - 3404, 100, // tin -> Cyrl - 3408, 355, // tjl -> Mymr - 3412, 10, // tjo -> Arab - 3416, 105, // tkb -> Deva - 3420, 10, // tks -> Arab - 3424, 105, // tkt -> Deva - 3428, 495, // tmr -> Syrc - 3432, 60, // tnv -> Cakm - 3436, 10, // tov -> Arab - 3440, 235, // tpu -> Khmr - 3444, 10, // tra -> Arab - 3448, 185, // trg -> Hebr - 3452, 10, // trm -> Arab - 3456, 10, // trw -> Arab - 3460, 150, // tsd -> Grek - 3464, 555, // tsj -> Tibt - 3468, 100, // tt -> Cyrl - 3471, 260, // tth -> Laoo - 3475, 260, // tto -> Laoo - 3479, 550, // tts -> Thai - 3483, 105, // ttz -> Deva - 3487, 355, // tvn -> Mymr - 3491, 105, // twm -> Deva - 3495, 525, // txg -> Tang - 3499, 565, // txo -> Toto - 3503, 530, // tyr -> Tavt - 3507, 100, // tyv -> Cyrl - 3511, 100, // ude -> Cyrl - 3515, 330, // udg -> Mlym - 3519, 100, // udi -> Cyrl - 3523, 100, // udm -> Cyrl - 3527, 10, // ug -> Arab - 3530, 100, // ug_KZ -> Cyrl - 3536, 100, // ug_MN -> Cyrl - 3542, 570, // uga -> Ugar - 3546, 100, // ugh -> Cyrl - 3550, 550, // ugo -> Thai - 3554, 100, // uk -> Cyrl - 3557, 395, // uki -> Orya - 3561, 100, // ulc -> Cyrl - 3565, 45, // unr -> Beng - 3569, 105, // unr_NP -> Deva - 3576, 45, // unx -> Beng - 3580, 10, // ur -> Arab - 3583, 550, // urk -> Thai - 3587, 10, // ush -> Arab - 3591, 150, // uum -> Grek - 3595, 10, // uz_AF -> Arab - 3601, 100, // uz_CN -> Cyrl - 3607, 10, // uzs -> Arab - 3611, 520, // vaa -> Taml - 3615, 10, // vaf -> Arab - 3619, 105, // vah -> Deva - 3623, 575, // vai -> Vaii - 3627, 105, // vas -> Deva - 3631, 105, // vav -> Deva - 3635, 105, // vay -> Deva - 3639, 10, // vgr -> Arab - 3643, 105, // vjk -> Deva - 3647, 245, // vmd -> Knda - 3651, 10, // vmh -> Arab - 3655, 120, // wal -> Ethi - 3659, 10, // wbk -> Arab - 3663, 535, // wbq -> Telu - 3667, 105, // wbr -> Deva - 3671, 120, // wle -> Ethi - 3675, 10, // wlo -> Arab - 3679, 105, // wme -> Deva - 3683, 10, // wne -> Arab - 3687, 10, // wni -> Arab - 3691, 130, // wsg -> Gong - 3695, 10, // wsv -> Arab - 3699, 105, // wtm -> Deva - 3703, 175, // wuu -> Hans - 3707, 0, // xag -> Aghb - 3711, 100, // xal -> Cyrl - 3715, 120, // xan -> Ethi - 3719, 100, // xas -> Cyrl - 3723, 85, // xco -> Chrs - 3727, 70, // xcr -> Cari - 3731, 100, // xdq -> Cyrl - 3735, 10, // xhe -> Arab - 3739, 235, // xhm -> Khmr - 3743, 395, // xis -> Orya - 3747, 10, // xka -> Arab - 3751, 10, // xkc -> Arab - 3755, 555, // xkf -> Tibt - 3759, 10, // xkj -> Arab - 3763, 10, // xkp -> Arab - 3767, 295, // xlc -> Lyci - 3771, 300, // xld -> Lydi - 3775, 115, // xly -> Elym - 3779, 125, // xmf -> Geor - 3783, 310, // xmn -> Mani - 3787, 325, // xmr -> Merc - 3791, 360, // xna -> Narb - 3795, 105, // xnr -> Deva - 3799, 150, // xpg -> Grek - 3803, 380, // xpi -> Ogam - 3807, 100, // xpm -> Cyrl - 3811, 430, // xpr -> Prti - 3815, 100, // xrm -> Cyrl - 3819, 100, // xrn -> Cyrl - 3823, 455, // xsa -> Sarb - 3827, 105, // xsr -> Deva - 3831, 55, // xtq -> Brah - 3835, 520, // xub -> Taml - 3839, 520, // xuj -> Taml - 3843, 200, // xve -> Ital - 3847, 10, // xvi -> Arab - 3851, 100, // xwo -> Cyrl - 3855, 315, // xzh -> Marc - 3859, 100, // yai -> Cyrl - 3863, 105, // ybh -> Deva - 3867, 105, // ybi -> Deva - 3871, 10, // ydg -> Arab - 3875, 330, // yea -> Mlym - 3879, 150, // yej -> Grek - 3883, 535, // yeu -> Telu - 3887, 425, // ygp -> Plrd - 3891, 185, // yhd -> Hebr - 3895, 185, // yi -> Hebr - 3898, 595, // yig -> Yiii - 3902, 185, // yih -> Hebr - 3906, 595, // yiv -> Yiii - 3910, 100, // ykg -> Cyrl - 3914, 100, // ykh -> Cyrl - 3918, 425, // yna -> Plrd - 3922, 100, // ynk -> Cyrl - 3926, 210, // yoi -> Jpan - 3930, 550, // yoy -> Thai - 3934, 100, // yrk -> Cyrl - 3938, 595, // ysd -> Yiii - 3942, 595, // ysn -> Yiii - 3946, 595, // ysp -> Yiii - 3950, 100, // ysr -> Cyrl - 3954, 425, // ysy -> Plrd - 3958, 185, // yud -> Hebr - 3962, 180, // yue -> Hant - 3966, 175, // yue_CN -> Hans - 3973, 100, // yug -> Cyrl - 3977, 100, // yux -> Cyrl - 3981, 425, // ywq -> Plrd - 3985, 425, // ywu -> Plrd - 3989, 555, // zau -> Tibt - 3993, 10, // zba -> Arab - 3997, 170, // zch -> Hani - 4001, 10, // zdj -> Arab - 4005, 170, // zeh -> Hani - 4009, 540, // zen -> Tfng - 4013, 170, // zgb -> Hani - 4017, 540, // zgh -> Tfng - 4021, 170, // zgm -> Hani - 4025, 170, // zgn -> Hani - 4029, 175, // zh -> Hans - 4032, 180, // zh_AU -> Hant - 4038, 180, // zh_BN -> Hant - 4044, 180, // zh_GB -> Hant - 4050, 180, // zh_GF -> Hant - 4056, 180, // zh_HK -> Hant - 4062, 180, // zh_ID -> Hant - 4068, 180, // zh_MO -> Hant - 4074, 180, // zh_PA -> Hant - 4080, 180, // zh_PF -> Hant - 4086, 180, // zh_PH -> Hant - 4092, 180, // zh_SR -> Hant - 4098, 180, // zh_TH -> Hant - 4104, 180, // zh_TW -> Hant - 4110, 180, // zh_US -> Hant - 4116, 180, // zh_VN -> Hant - 4122, 170, // zhd -> Hani - 4126, 375, // zhx -> Nshu - 4130, 100, // zko -> Cyrl - 4134, 240, // zkt -> Kits - 4138, 100, // zkz -> Cyrl - 4142, 170, // zlj -> Hani - 4146, 170, // zln -> Hani - 4150, 170, // zlq -> Hani - 4154, 170, // zqe -> Hani - 4158, 395, // zrg -> Orya - 4162, 185, // zrp -> Hebr - 4166, 10, // zum -> Arab - 4170, 120, // zwa -> Ethi - 4174, 170, // zyg -> Hani - 4178, 170, // zyn -> Hani - 4182, 170, // zzj -> Hani + 1238, 180, // hak -> Hans + 1242, 185, // hak_TW -> Hant + 1249, 125, // har -> Ethi + 1253, 10, // haz -> Arab + 1257, 190, // hbo -> Hebr + 1261, 125, // hdy -> Ethi + 1265, 190, // he -> Hebr + 1268, 110, // hi -> Deva + 1271, 110, // hif -> Deva + 1275, 505, // hii -> Takr + 1279, 590, // hit -> Xsux + 1283, 10, // hkh -> Arab + 1287, 110, // hlb -> Deva + 1291, 195, // hlu -> Hluw + 1295, 425, // hmd -> Plrd + 1299, 55, // hmj -> Bopo + 1303, 55, // hmq -> Bopo + 1307, 10, // hnd -> Arab + 1311, 110, // hne -> Deva + 1315, 200, // hnj -> Hmnp + 1319, 10, // hno -> Arab + 1323, 110, // hoc -> Deva + 1327, 10, // hoh -> Arab + 1331, 110, // hoj -> Deva + 1335, 175, // how -> Hani + 1339, 110, // hoy -> Deva + 1343, 355, // hpo -> Mymr + 1347, 495, // hrt -> Syrc + 1351, 10, // hrz -> Arab + 1355, 180, // hsn -> Hans + 1359, 10, // hss -> Arab + 1363, 590, // htx -> Xsux + 1367, 110, // hut -> Deva + 1371, 190, // huy -> Hebr + 1375, 105, // huz -> Cyrl + 1379, 20, // hy -> Armn + 1382, 20, // hyw -> Armn + 1386, 595, // ii -> Yiii + 1389, 295, // imy -> Lyci + 1393, 105, // inh -> Cyrl + 1397, 355, // int -> Mymr + 1401, 125, // ior -> Ethi + 1405, 520, // iru -> Taml + 1409, 10, // isk -> Arab + 1413, 190, // itk -> Hebr + 1417, 105, // itl -> Cyrl + 1421, 70, // iu -> Cans + 1424, 190, // iw -> Hebr + 1427, 215, // ja -> Jpan + 1430, 10, // jad -> Arab + 1434, 10, // jat -> Arab + 1438, 190, // jbe -> Hebr + 1442, 10, // jbn -> Arab + 1446, 105, // jct -> Cyrl + 1450, 555, // jda -> Tibt + 1454, 10, // jdg -> Arab + 1458, 105, // jdt -> Cyrl + 1462, 110, // jee -> Deva + 1466, 130, // jge -> Geor + 1470, 190, // ji -> Hebr + 1473, 170, // jje -> Hang + 1477, 355, // jkm -> Mymr + 1481, 110, // jml -> Deva + 1485, 505, // jna -> Takr + 1489, 10, // jnd -> Arab + 1493, 110, // jnl -> Deva + 1497, 110, // jns -> Deva + 1501, 10, // jog -> Arab + 1505, 190, // jpa -> Hebr + 1509, 190, // jpr -> Hebr + 1513, 190, // jrb -> Hebr + 1517, 110, // jul -> Deva + 1521, 395, // jun -> Orya + 1525, 395, // juy -> Orya + 1529, 555, // jya -> Tibt + 1533, 190, // jye -> Hebr + 1537, 130, // ka -> Geor + 1540, 105, // kaa -> Cyrl + 1544, 105, // kap -> Cyrl + 1548, 30, // kaw -> Bali + 1552, 105, // kbd -> Cyrl + 1556, 555, // kbg -> Tibt + 1560, 10, // kbu -> Arab + 1564, 10, // kby -> Arab + 1568, 105, // kca -> Cyrl + 1572, 10, // kcy -> Arab + 1576, 50, // kdq -> Beng + 1580, 550, // kdt -> Thai + 1584, 105, // ket -> Cyrl + 1588, 330, // kev -> Mlym + 1592, 110, // kex -> Deva + 1596, 535, // key -> Telu + 1600, 245, // kfa -> Knda + 1604, 110, // kfb -> Deva + 1608, 535, // kfc -> Telu + 1612, 245, // kfd -> Knda + 1616, 520, // kfe -> Taml + 1620, 245, // kfg -> Knda + 1624, 330, // kfh -> Mlym + 1628, 520, // kfi -> Taml + 1632, 110, // kfk -> Deva + 1636, 10, // kfm -> Arab + 1640, 110, // kfp -> Deva + 1644, 110, // kfq -> Deva + 1648, 110, // kfr -> Deva + 1652, 110, // kfs -> Deva + 1656, 110, // kfu -> Deva + 1660, 110, // kfx -> Deva + 1664, 110, // kfy -> Deva + 1668, 110, // kgj -> Deva + 1672, 110, // kgy -> Deva + 1676, 515, // khb -> Talu + 1680, 550, // khf -> Thai + 1684, 555, // khg -> Tibt + 1688, 110, // khn -> Deva + 1692, 60, // kho -> Brah + 1696, 355, // kht -> Mymr + 1700, 105, // khv -> Cyrl + 1704, 10, // khw -> Arab + 1708, 110, // kif -> Deva + 1712, 105, // kim -> Cyrl + 1716, 110, // kip -> Deva + 1720, 260, // kjg -> Laoo + 1724, 105, // kjh -> Cyrl + 1728, 110, // kjl -> Deva + 1732, 110, // kjo -> Deva + 1736, 355, // kjp -> Mymr + 1740, 550, // kjt -> Thai + 1744, 555, // kjz -> Tibt + 1748, 105, // kk -> Cyrl + 1751, 10, // kk_AF -> Arab + 1757, 10, // kk_CN -> Arab + 1763, 10, // kk_IR -> Arab + 1769, 10, // kk_MN -> Arab + 1775, 555, // kkf -> Tibt + 1779, 255, // kkh -> Lana + 1783, 110, // kkt -> Deva + 1787, 110, // kle -> Deva + 1791, 10, // klj -> Arab + 1795, 110, // klr -> Deva + 1799, 235, // km -> Khmr + 1802, 110, // kmj -> Deva + 1806, 10, // kmz -> Arab + 1810, 245, // kn -> Knda + 1813, 110, // knn -> Deva + 1817, 250, // ko -> Kore + 1820, 105, // koi -> Cyrl + 1824, 110, // kok -> Deva + 1828, 105, // kpt -> Cyrl + 1832, 105, // kpy -> Cyrl + 1836, 495, // kqd -> Syrc + 1840, 125, // kqy -> Ethi + 1844, 110, // kra -> Deva + 1848, 105, // krc -> Cyrl + 1852, 105, // krk -> Cyrl + 1856, 235, // krr -> Khmr + 1860, 110, // kru -> Deva + 1864, 235, // krv -> Khmr + 1868, 10, // ks -> Arab + 1871, 355, // ksu -> Mymr + 1875, 355, // ksw -> Mymr + 1879, 110, // ksz -> Deva + 1883, 125, // ktb -> Ethi + 1887, 110, // kte -> Deva + 1891, 10, // ktl -> Arab + 1895, 425, // ktp -> Plrd + 1899, 10, // ku_LB -> Arab + 1905, 260, // kuf -> Laoo + 1909, 105, // kum -> Cyrl + 1913, 105, // kv -> Cyrl + 1916, 105, // kva -> Cyrl + 1920, 355, // kvq -> Mymr + 1924, 355, // kvt -> Mymr + 1928, 10, // kvx -> Arab + 1932, 220, // kvy -> Kali + 1936, 355, // kxf -> Mymr + 1940, 355, // kxk -> Mymr + 1944, 550, // kxm -> Thai + 1948, 10, // kxp -> Arab + 1952, 105, // ky -> Cyrl + 1955, 10, // ky_CN -> Arab + 1961, 220, // kyu -> Kali + 1965, 110, // kyv -> Deva + 1969, 110, // kyw -> Deva + 1973, 280, // lab -> Lina + 1977, 190, // lad -> Hebr + 1981, 110, // lae -> Deva + 1985, 10, // lah -> Arab + 1989, 105, // lbe -> Cyrl + 1993, 110, // lbf -> Deva + 1997, 555, // lbj -> Tibt + 2001, 110, // lbm -> Deva + 2005, 260, // lbo -> Laoo + 2009, 110, // lbr -> Deva + 2013, 550, // lcp -> Thai + 2017, 275, // lep -> Lepc + 2021, 105, // lez -> Cyrl + 2025, 110, // lhm -> Deva + 2029, 495, // lhs -> Syrc + 2033, 110, // lif -> Deva + 2037, 290, // lis -> Lisu + 2041, 555, // lkh -> Tibt + 2045, 10, // lki -> Arab + 2049, 110, // lmh -> Deva + 2053, 535, // lmn -> Telu + 2057, 260, // lo -> Laoo + 2060, 110, // loy -> Deva + 2064, 425, // lpo -> Plrd + 2068, 10, // lrc -> Arab + 2072, 10, // lrk -> Arab + 2076, 10, // lrl -> Arab + 2080, 10, // lsa -> Arab + 2084, 190, // lsd -> Hebr + 2088, 10, // lss -> Arab + 2092, 185, // ltc -> Hant + 2096, 555, // luk -> Tibt + 2100, 110, // luu -> Deva + 2104, 10, // luv -> Arab + 2108, 10, // luz -> Arab + 2112, 550, // lwl -> Thai + 2116, 550, // lwm -> Thai + 2120, 555, // lya -> Tibt + 2124, 180, // lzh -> Hans + 2128, 130, // lzz_GE -> Geor + 2135, 110, // mag -> Deva + 2139, 110, // mai -> Deva + 2143, 10, // mby -> Arab + 2147, 10, // mde -> Arab + 2151, 105, // mdf -> Cyrl + 2155, 125, // mdx -> Ethi + 2159, 125, // mdy -> Ethi + 2163, 10, // mfa -> Arab + 2167, 10, // mfi -> Arab + 2171, 270, // mga -> Latg + 2175, 110, // mgp -> Deva + 2179, 10, // mhj -> Arab + 2183, 305, // mid -> Mand + 2187, 110, // mjl -> Deva + 2191, 330, // mjq -> Mlym + 2195, 330, // mjr -> Mlym + 2199, 110, // mjt -> Deva + 2203, 535, // mju -> Telu + 2207, 330, // mjv -> Mlym + 2211, 110, // mjz -> Deva + 2215, 105, // mk -> Cyrl + 2218, 110, // mkb -> Deva + 2222, 110, // mke -> Deva + 2226, 10, // mki -> Arab + 2230, 550, // mkm -> Thai + 2234, 330, // ml -> Mlym + 2237, 550, // mlf -> Thai + 2241, 105, // mn -> Cyrl + 2244, 340, // mn_CN -> Mong + 2250, 340, // mnc -> Mong + 2254, 50, // mni -> Beng + 2258, 10, // mnj -> Arab + 2262, 105, // mns -> Cyrl + 2266, 355, // mnw -> Mymr + 2270, 550, // mpz -> Thai + 2274, 110, // mr -> Deva + 2277, 550, // mra -> Thai + 2281, 110, // mrd -> Deva + 2285, 105, // mrj -> Cyrl + 2289, 345, // mro -> Mroo + 2293, 110, // mrr -> Deva + 2297, 10, // ms_CC -> Arab + 2303, 105, // mtm -> Cyrl + 2307, 110, // mtr -> Deva + 2311, 105, // mud -> Cyrl + 2315, 555, // muk -> Tibt + 2319, 110, // mut -> Deva + 2323, 520, // muv -> Taml + 2327, 125, // muz -> Ethi + 2331, 10, // mve -> Arab + 2335, 340, // mvf -> Mong + 2339, 10, // mvy -> Arab + 2343, 125, // mvz -> Ethi + 2347, 110, // mwr -> Deva + 2351, 355, // mwt -> Mymr + 2355, 200, // mww -> Hmnp + 2359, 355, // my -> Mymr + 2362, 125, // mym -> Ethi + 2366, 105, // myv -> Cyrl + 2370, 305, // myz -> Mand + 2374, 10, // mzn -> Arab + 2378, 180, // nan -> Hans + 2382, 185, // nan_TW -> Hant + 2389, 110, // nao -> Deva + 2393, 110, // ncd -> Deva + 2397, 260, // ncq -> Laoo + 2401, 105, // ndf -> Cyrl + 2405, 110, // ne -> Deva + 2408, 105, // neg -> Cyrl + 2412, 555, // neh -> Tibt + 2416, 590, // nei -> Xsux + 2420, 110, // new -> Deva + 2424, 260, // ngt -> Laoo + 2428, 105, // nio -> Cyrl + 2432, 535, // nit -> Telu + 2436, 105, // niv -> Cyrl + 2440, 10, // nli -> Arab + 2444, 10, // nlm -> Arab + 2448, 110, // nlx -> Deva + 2452, 110, // nmm -> Deva + 2456, 580, // nnp -> Wcho + 2460, 255, // nod -> Lana + 2464, 110, // noe -> Deva + 2468, 105, // nog -> Cyrl + 2472, 110, // noi -> Deva + 2476, 445, // non -> Runr + 2480, 595, // nos -> Yiii + 2484, 555, // npb -> Tibt + 2488, 370, // nqo -> Nkoo + 2492, 445, // nrn -> Runr + 2496, 595, // nsd -> Yiii + 2500, 595, // nsf -> Yiii + 2504, 70, // nsk -> Cans + 2508, 560, // nst -> Tnsa + 2512, 595, // nsv -> Yiii + 2516, 595, // nty -> Yiii + 2520, 10, // ntz -> Arab + 2524, 365, // nwc -> Newa + 2528, 110, // nwx -> Deva + 2532, 550, // nyl -> Thai + 2536, 10, // nyq -> Arab + 2540, 550, // nyw -> Thai + 2544, 105, // oaa -> Cyrl + 2548, 105, // oac -> Cyrl + 2552, 495, // oar -> Syrc + 2556, 130, // oav -> Geor + 2560, 420, // obm -> Phnx + 2564, 355, // obr -> Mymr + 2568, 10, // odk -> Arab + 2572, 590, // oht -> Xsux + 2576, 70, // oj -> Cans + 2579, 70, // ojs -> Cans + 2583, 170, // okm -> Hang + 2587, 175, // oko -> Hani + 2591, 235, // okz -> Khmr + 2595, 110, // ola -> Deva + 2599, 555, // ole -> Tibt + 2603, 105, // omk -> Cyrl + 2607, 350, // omp -> Mtei + 2611, 335, // omr -> Modi + 2615, 355, // omx -> Mymr + 2619, 110, // oon -> Deva + 2623, 395, // or -> Orya + 2626, 535, // ort -> Telu + 2630, 10, // oru -> Arab + 2634, 105, // orv -> Cyrl + 2638, 105, // os -> Cyrl + 2641, 400, // osa -> Osge + 2645, 205, // osc -> Ital + 2649, 210, // osi -> Java + 2653, 10, // ota -> Arab + 2657, 555, // otb -> Tibt + 2661, 390, // otk -> Orkh + 2665, 150, // oty -> Gran + 2669, 405, // oui -> Ougr + 2673, 165, // pa -> Guru + 2676, 10, // pa_PK -> Arab + 2682, 415, // pal -> Phli + 2686, 105, // paq -> Cyrl + 2690, 10, // pbt -> Arab + 2694, 235, // pcb -> Khmr + 2698, 355, // pce -> Mymr + 2702, 330, // pcf -> Mlym + 2706, 330, // pcg -> Mlym + 2710, 110, // pch -> Deva + 2714, 110, // pci -> Deva + 2718, 535, // pcj -> Telu + 2722, 395, // peg -> Orya + 2726, 585, // peo -> Xpeo + 2730, 230, // pgd -> Khar + 2734, 110, // pgg -> Deva + 2738, 380, // pgl -> Ogam + 2742, 205, // pgn -> Ital + 2746, 110, // phd -> Deva + 2750, 355, // phk -> Mymr + 2754, 10, // phl -> Arab + 2758, 420, // phn -> Phnx + 2762, 260, // pho -> Laoo + 2766, 10, // phr -> Arab + 2770, 550, // pht -> Thai + 2774, 550, // phu -> Thai + 2778, 10, // phv -> Arab + 2782, 110, // phw -> Deva + 2786, 470, // pi -> Sinh + 2789, 60, // pka -> Brah + 2793, 330, // pkr -> Mlym + 2797, 10, // plk -> Arab + 2801, 355, // pll -> Mymr + 2805, 60, // pmh -> Brah + 2809, 155, // pnt -> Grek + 2813, 105, // pnt_RU -> Cyrl + 2820, 230, // pra -> Khar + 2824, 10, // prc -> Arab + 2828, 10, // prd -> Arab + 2832, 550, // prt -> Thai + 2836, 10, // prx -> Arab + 2840, 10, // ps -> Arab + 2843, 10, // psh -> Arab + 2847, 10, // psi -> Arab + 2851, 10, // pst -> Arab + 2855, 60, // psu -> Brah + 2859, 110, // pum -> Deva + 2863, 355, // pwo -> Mymr + 2867, 110, // pwr -> Deva + 2871, 550, // pww -> Thai + 2875, 355, // pyx -> Mymr + 2879, 10, // qxq -> Arab + 2883, 110, // raa -> Deva + 2887, 110, // rab -> Deva + 2891, 110, // raf -> Deva + 2895, 50, // rah -> Beng + 2899, 110, // raj -> Deva + 2903, 110, // rav -> Deva + 2907, 355, // rbb -> Mymr + 2911, 10, // rdb -> Arab + 2915, 395, // rei -> Orya + 2919, 440, // rhg -> Rohg + 2923, 110, // rji -> Deva + 2927, 110, // rjs -> Deva + 2931, 235, // rka -> Khmr + 2935, 355, // rki -> Mymr + 2939, 50, // rkt -> Beng + 2943, 20, // rmi -> Armn + 2947, 10, // rmt -> Arab + 2951, 355, // rmz -> Mymr + 2955, 105, // rsk -> Cyrl + 2959, 110, // rtw -> Deva + 2963, 105, // ru -> Cyrl + 2966, 105, // rue -> Cyrl + 2970, 105, // rut -> Cyrl + 2974, 110, // rwr -> Deva + 2978, 225, // ryu -> Kana + 2982, 110, // sa -> Deva + 2985, 105, // sah -> Cyrl + 2989, 450, // sam -> Samr + 2993, 385, // sat -> Olck + 2997, 460, // saz -> Saur + 3001, 10, // sbn -> Arab + 3005, 555, // sbu -> Tibt + 3009, 110, // sck -> Deva + 3013, 10, // scl -> Arab + 3017, 110, // scp -> Deva + 3021, 260, // sct -> Laoo + 3025, 505, // scu -> Takr + 3029, 155, // scx -> Grek + 3033, 10, // sd -> Arab + 3036, 110, // sd_IN -> Deva + 3042, 10, // sdb -> Arab + 3046, 10, // sdf -> Arab + 3050, 10, // sdg -> Arab + 3054, 10, // sdh -> Arab + 3058, 50, // sdr -> Beng + 3062, 10, // sds -> Arab + 3066, 105, // sel -> Cyrl + 3070, 425, // sfm -> Plrd + 3074, 105, // sgh -> Cyrl + 3078, 110, // sgj -> Deva + 3082, 10, // sgr -> Arab + 3086, 555, // sgt -> Tibt + 3090, 125, // sgw -> Ethi + 3094, 10, // sgy -> Arab + 3098, 10, // shd -> Arab + 3102, 540, // shi -> Tfng + 3106, 10, // shm -> Arab + 3110, 355, // shn -> Mymr + 3114, 10, // shu -> Arab + 3118, 10, // shv -> Arab + 3122, 470, // si -> Sinh + 3125, 105, // sia -> Cyrl + 3129, 555, // sip -> Tibt + 3133, 10, // siy -> Arab + 3137, 10, // siz -> Arab + 3141, 105, // sjd -> Cyrl + 3145, 110, // sjp -> Deva + 3149, 105, // sjt -> Cyrl + 3153, 550, // skb -> Thai + 3157, 110, // skj -> Deva + 3161, 10, // skr -> Arab + 3165, 595, // smh -> Yiii + 3169, 450, // smp -> Samr + 3173, 235, // smu -> Khmr + 3177, 10, // smy -> Arab + 3181, 530, // soa -> Tavt + 3185, 475, // sog -> Sogd + 3189, 110, // soi -> Deva + 3193, 550, // sou -> Thai + 3197, 555, // spt -> Tibt + 3201, 395, // spv -> Orya + 3205, 10, // sqo -> Arab + 3209, 260, // sqq -> Laoo + 3213, 10, // sqt -> Arab + 3217, 105, // sr -> Cyrl + 3220, 480, // srb -> Sora + 3224, 10, // srh -> Arab + 3228, 110, // srx -> Deva + 3232, 10, // srz -> Arab + 3236, 10, // ssh -> Arab + 3240, 260, // sss -> Laoo + 3244, 10, // sts -> Arab + 3248, 125, // stv -> Ethi + 3252, 105, // sty -> Cyrl + 3256, 490, // suz -> Sunu + 3260, 130, // sva -> Geor + 3264, 10, // swb -> Arab + 3268, 175, // swi -> Hani + 3272, 110, // swv -> Deva + 3276, 445, // sxu -> Runr + 3280, 495, // syc -> Syrc + 3284, 50, // syl -> Beng + 3288, 495, // syn -> Syrc + 3292, 495, // syr -> Syrc + 3296, 110, // syw -> Deva + 3300, 520, // ta -> Taml + 3303, 105, // tab -> Cyrl + 3307, 110, // taj -> Deva + 3311, 500, // tbk -> Tagb + 3315, 555, // tcn -> Tibt + 3319, 355, // tco -> Mymr + 3323, 520, // tcx -> Taml + 3327, 245, // tcy -> Knda + 3331, 540, // tda -> Tfng + 3335, 110, // tdb -> Deva + 3339, 510, // tdd -> Tale + 3343, 110, // tdg -> Deva + 3347, 110, // tdh -> Deva + 3351, 535, // te -> Telu + 3354, 210, // tes -> Java + 3358, 105, // tg -> Cyrl + 3361, 10, // tg_PK -> Arab + 3367, 110, // tge -> Deva + 3371, 555, // tgf -> Tibt + 3375, 550, // th -> Thai + 3378, 110, // the -> Deva + 3382, 110, // thf -> Deva + 3386, 510, // thi -> Tale + 3390, 110, // thl -> Deva + 3394, 550, // thm -> Thai + 3398, 110, // thq -> Deva + 3402, 110, // thr -> Deva + 3406, 110, // ths -> Deva + 3410, 125, // ti -> Ethi + 3413, 125, // tig -> Ethi + 3417, 110, // tij -> Deva + 3421, 105, // tin -> Cyrl + 3425, 355, // tjl -> Mymr + 3429, 10, // tjo -> Arab + 3433, 110, // tkb -> Deva + 3437, 10, // tks -> Arab + 3441, 110, // tkt -> Deva + 3445, 495, // tmr -> Syrc + 3449, 65, // tnv -> Cakm + 3453, 10, // tov -> Arab + 3457, 235, // tpu -> Khmr + 3461, 10, // tra -> Arab + 3465, 190, // trg -> Hebr + 3469, 10, // trm -> Arab + 3473, 10, // trw -> Arab + 3477, 155, // tsd -> Grek + 3481, 555, // tsj -> Tibt + 3485, 105, // tt -> Cyrl + 3488, 260, // tth -> Laoo + 3492, 260, // tto -> Laoo + 3496, 550, // tts -> Thai + 3500, 110, // ttz -> Deva + 3504, 355, // tvn -> Mymr + 3508, 110, // twm -> Deva + 3512, 525, // txg -> Tang + 3516, 565, // txo -> Toto + 3520, 530, // tyr -> Tavt + 3524, 105, // tyv -> Cyrl + 3528, 105, // ude -> Cyrl + 3532, 330, // udg -> Mlym + 3536, 105, // udi -> Cyrl + 3540, 105, // udm -> Cyrl + 3544, 10, // ug -> Arab + 3547, 105, // ug_KZ -> Cyrl + 3553, 105, // ug_MN -> Cyrl + 3559, 570, // uga -> Ugar + 3563, 105, // ugh -> Cyrl + 3567, 550, // ugo -> Thai + 3571, 105, // uk -> Cyrl + 3574, 395, // uki -> Orya + 3578, 105, // ulc -> Cyrl + 3582, 50, // unr -> Beng + 3586, 110, // unr_NP -> Deva + 3593, 50, // unx -> Beng + 3597, 10, // ur -> Arab + 3600, 550, // urk -> Thai + 3604, 10, // ush -> Arab + 3608, 155, // uum -> Grek + 3612, 10, // uz_AF -> Arab + 3618, 105, // uz_CN -> Cyrl + 3624, 10, // uzs -> Arab + 3628, 520, // vaa -> Taml + 3632, 10, // vaf -> Arab + 3636, 110, // vah -> Deva + 3640, 575, // vai -> Vaii + 3644, 110, // vas -> Deva + 3648, 110, // vav -> Deva + 3652, 110, // vay -> Deva + 3656, 10, // vgr -> Arab + 3660, 110, // vjk -> Deva + 3664, 245, // vmd -> Knda + 3668, 10, // vmh -> Arab + 3672, 125, // wal -> Ethi + 3676, 10, // wbk -> Arab + 3680, 535, // wbq -> Telu + 3684, 110, // wbr -> Deva + 3688, 125, // wle -> Ethi + 3692, 10, // wlo -> Arab + 3696, 110, // wme -> Deva + 3700, 10, // wne -> Arab + 3704, 10, // wni -> Arab + 3708, 135, // wsg -> Gong + 3712, 10, // wsv -> Arab + 3716, 110, // wtm -> Deva + 3720, 180, // wuu -> Hans + 3724, 0, // xag -> Aghb + 3728, 105, // xal -> Cyrl + 3732, 125, // xan -> Ethi + 3736, 105, // xas -> Cyrl + 3740, 90, // xco -> Chrs + 3744, 75, // xcr -> Cari + 3748, 105, // xdq -> Cyrl + 3752, 10, // xhe -> Arab + 3756, 235, // xhm -> Khmr + 3760, 395, // xis -> Orya + 3764, 10, // xka -> Arab + 3768, 10, // xkc -> Arab + 3772, 555, // xkf -> Tibt + 3776, 10, // xkj -> Arab + 3780, 10, // xkp -> Arab + 3784, 295, // xlc -> Lyci + 3788, 300, // xld -> Lydi + 3792, 120, // xly -> Elym + 3796, 130, // xmf -> Geor + 3800, 310, // xmn -> Mani + 3804, 325, // xmr -> Merc + 3808, 360, // xna -> Narb + 3812, 110, // xnr -> Deva + 3816, 155, // xpg -> Grek + 3820, 380, // xpi -> Ogam + 3824, 105, // xpm -> Cyrl + 3828, 430, // xpr -> Prti + 3832, 105, // xrm -> Cyrl + 3836, 105, // xrn -> Cyrl + 3840, 455, // xsa -> Sarb + 3844, 110, // xsr -> Deva + 3848, 60, // xtq -> Brah + 3852, 520, // xub -> Taml + 3856, 520, // xuj -> Taml + 3860, 205, // xve -> Ital + 3864, 10, // xvi -> Arab + 3868, 105, // xwo -> Cyrl + 3872, 315, // xzh -> Marc + 3876, 105, // yai -> Cyrl + 3880, 110, // ybh -> Deva + 3884, 110, // ybi -> Deva + 3888, 10, // ydg -> Arab + 3892, 330, // yea -> Mlym + 3896, 155, // yej -> Grek + 3900, 535, // yeu -> Telu + 3904, 425, // ygp -> Plrd + 3908, 190, // yhd -> Hebr + 3912, 190, // yi -> Hebr + 3915, 595, // yig -> Yiii + 3919, 190, // yih -> Hebr + 3923, 595, // yiv -> Yiii + 3927, 105, // ykg -> Cyrl + 3931, 105, // ykh -> Cyrl + 3935, 425, // yna -> Plrd + 3939, 105, // ynk -> Cyrl + 3943, 215, // yoi -> Jpan + 3947, 550, // yoy -> Thai + 3951, 105, // yrk -> Cyrl + 3955, 595, // ysd -> Yiii + 3959, 595, // ysn -> Yiii + 3963, 595, // ysp -> Yiii + 3967, 105, // ysr -> Cyrl + 3971, 425, // ysy -> Plrd + 3975, 190, // yud -> Hebr + 3979, 185, // yue -> Hant + 3983, 180, // yue_CN -> Hans + 3990, 105, // yug -> Cyrl + 3994, 105, // yux -> Cyrl + 3998, 425, // ywq -> Plrd + 4002, 425, // ywu -> Plrd + 4006, 555, // zau -> Tibt + 4010, 10, // zba -> Arab + 4014, 175, // zch -> Hani + 4018, 10, // zdj -> Arab + 4022, 175, // zeh -> Hani + 4026, 540, // zen -> Tfng + 4030, 175, // zgb -> Hani + 4034, 540, // zgh -> Tfng + 4038, 175, // zgm -> Hani + 4042, 175, // zgn -> Hani + 4046, 180, // zh -> Hans + 4049, 185, // zh_AU -> Hant + 4055, 185, // zh_BN -> Hant + 4061, 185, // zh_GB -> Hant + 4067, 185, // zh_GF -> Hant + 4073, 185, // zh_HK -> Hant + 4079, 185, // zh_ID -> Hant + 4085, 185, // zh_MO -> Hant + 4091, 185, // zh_PA -> Hant + 4097, 185, // zh_PF -> Hant + 4103, 185, // zh_PH -> Hant + 4109, 185, // zh_SR -> Hant + 4115, 185, // zh_TH -> Hant + 4121, 185, // zh_TW -> Hant + 4127, 185, // zh_US -> Hant + 4133, 185, // zh_VN -> Hant + 4139, 175, // zhd -> Hani + 4143, 375, // zhx -> Nshu + 4147, 105, // zko -> Cyrl + 4151, 240, // zkt -> Kits + 4155, 105, // zkz -> Cyrl + 4159, 175, // zlj -> Hani + 4163, 175, // zln -> Hani + 4167, 175, // zlq -> Hani + 4171, 175, // zqe -> Hani + 4175, 395, // zrg -> Orya + 4179, 190, // zrp -> Hebr + 4183, 10, // zum -> Arab + 4187, 125, // zwa -> Ethi + 4191, 175, // zyg -> Hani + 4195, 175, // zyn -> Hani + 4199, 175, // zzj -> Hani }; //====================================================================== @@ -1159,38 +1162,39 @@ const char parentLocaleChars[] = "az_Arab\0az_Cyrl\0bal_Latn\0blt_Latn\0bm_Nkoo\0bs_Cyrl\0byn_Latn\0" "cu_Glag\0dje_Arab\0dyo_Arab\0en_001\0en_150\0en_AG\0en_AI\0en_AT\0" "en_AU\0en_BB\0en_BE\0en_BM\0en_BS\0en_BW\0en_BZ\0en_CC\0en_CH\0" - "en_CK\0en_CM\0en_CX\0en_CY\0en_DE\0en_DG\0en_DK\0en_DM\0en_Dsrt\0" - "en_ER\0en_FI\0en_FJ\0en_FK\0en_FM\0en_GB\0en_GD\0en_GG\0en_GH\0" - "en_GI\0en_GM\0en_GY\0en_HK\0en_ID\0en_IE\0en_IL\0en_IM\0en_IN\0" - "en_IO\0en_JE\0en_JM\0en_KE\0en_KI\0en_KN\0en_KY\0en_LC\0en_LR\0" - "en_LS\0en_MG\0en_MO\0en_MS\0en_MT\0en_MU\0en_MV\0en_MW\0en_MY\0" - "en_NA\0en_NF\0en_NG\0en_NL\0en_NR\0en_NU\0en_NZ\0en_PG\0en_PK\0" - "en_PN\0en_PW\0en_RW\0en_SB\0en_SC\0en_SD\0en_SE\0en_SG\0en_SH\0" - "en_SI\0en_SL\0en_SS\0en_SX\0en_SZ\0en_Shaw\0en_TC\0en_TK\0en_TO\0" - "en_TT\0en_TV\0en_TZ\0en_UG\0en_VC\0en_VG\0en_VU\0en_WS\0en_ZA\0" - "en_ZM\0en_ZW\0es_419\0es_AR\0es_BO\0es_BR\0es_BZ\0es_CL\0es_CO\0" - "es_CR\0es_CU\0es_DO\0es_EC\0es_GT\0es_HN\0es_JP\0es_MX\0es_NI\0" - "es_PA\0es_PE\0es_PR\0es_PY\0es_SV\0es_US\0es_UY\0es_VE\0ff_Adlm\0" - "ff_Arab\0fr_HT\0ha_Arab\0hi_Latn\0ht\0iu_Latn\0kaa_Latn\0kk_Arab\0" - "kok_Latn\0ks_Deva\0ku_Arab\0kxv_Deva\0kxv_Orya\0kxv_Telu\0ky_Arab\0" - "ky_Latn\0ml_Arab\0mn_Mong\0mni_Mtei\0ms_Arab\0nb\0nn\0no\0no_NO\0" - "pa_Arab\0pt_AO\0pt_CH\0pt_CV\0pt_FR\0pt_GQ\0pt_GW\0pt_LU\0pt_MO\0" - "pt_MZ\0pt_PT\0pt_ST\0pt_TL\0root\0sat_Deva\0sd_Deva\0sd_Khoj\0" - "sd_Sind\0shi_Latn\0so_Arab\0sr_Latn\0sw_Arab\0tg_Arab\0ug_Cyrl\0" - "uz_Arab\0uz_Cyrl\0vai_Latn\0wo_Arab\0yo_Arab\0yue_Hans\0zh_Hant\0" - "zh_Hant_HK\0zh_Hant_MO\0"; + "en_CK\0en_CM\0en_CX\0en_CY\0en_CZ\0en_DE\0en_DG\0en_DK\0en_DM\0" + "en_Dsrt\0en_ER\0en_ES\0en_FI\0en_FJ\0en_FK\0en_FM\0en_FR\0en_GB\0" + "en_GD\0en_GG\0en_GH\0en_GI\0en_GM\0en_GS\0en_GY\0en_HK\0en_HU\0" + "en_ID\0en_IE\0en_IL\0en_IM\0en_IN\0en_IO\0en_IT\0en_JE\0en_JM\0" + "en_KE\0en_KI\0en_KN\0en_KY\0en_LC\0en_LR\0en_LS\0en_MG\0en_MO\0" + "en_MS\0en_MT\0en_MU\0en_MV\0en_MW\0en_MY\0en_NA\0en_NF\0en_NG\0" + "en_NL\0en_NO\0en_NR\0en_NU\0en_NZ\0en_PG\0en_PK\0en_PL\0en_PN\0" + "en_PT\0en_PW\0en_RO\0en_RW\0en_SB\0en_SC\0en_SD\0en_SE\0en_SG\0" + "en_SH\0en_SI\0en_SK\0en_SL\0en_SS\0en_SX\0en_SZ\0en_Shaw\0en_TC\0" + "en_TK\0en_TO\0en_TT\0en_TV\0en_TZ\0en_UG\0en_VC\0en_VG\0en_VU\0" + "en_WS\0en_ZA\0en_ZM\0en_ZW\0es_419\0es_AR\0es_BO\0es_BR\0es_BZ\0" + "es_CL\0es_CO\0es_CR\0es_CU\0es_DO\0es_EC\0es_GT\0es_HN\0es_JP\0" + "es_MX\0es_NI\0es_PA\0es_PE\0es_PR\0es_PY\0es_SV\0es_US\0es_UY\0" + "es_VE\0ff_Adlm\0ff_Arab\0fr_HT\0ha_Arab\0hi_Latn\0ht\0iu_Latn\0" + "kaa_Latn\0kk_Arab\0kok_Latn\0ks_Deva\0ku_Arab\0kxv_Deva\0kxv_Orya\0" + "kxv_Telu\0ky_Arab\0ky_Latn\0ml_Arab\0mn_Mong\0mni_Mtei\0ms_Arab\0" + "nb\0nn\0no\0no_NO\0pa_Arab\0pt_AO\0pt_CH\0pt_CV\0pt_FR\0pt_GQ\0" + "pt_GW\0pt_LU\0pt_MO\0pt_MZ\0pt_PT\0pt_ST\0pt_TL\0root\0sat_Deva\0" + "sd_Deva\0sd_Khoj\0sd_Sind\0shi_Latn\0so_Arab\0sr_Latn\0sw_Arab\0" + "tg_Arab\0ug_Cyrl\0uz_Arab\0uz_Cyrl\0vai_Latn\0wo_Arab\0yo_Arab\0" + "yue_Hans\0zh_Hant\0zh_Hant_HK\0zh_Hant_MO\0"; const int32_t parentLocaleTable[] = { - 0, 1080, // az_Arab -> root - 8, 1080, // az_Cyrl -> root - 16, 1080, // bal_Latn -> root - 25, 1080, // blt_Latn -> root - 34, 1080, // bm_Nkoo -> root - 42, 1080, // bs_Cyrl -> root - 50, 1080, // byn_Latn -> root - 59, 1080, // cu_Glag -> root - 67, 1080, // dje_Arab -> root - 76, 1080, // dyo_Arab -> root + 0, 1146, // az_Arab -> root + 8, 1146, // az_Cyrl -> root + 16, 1146, // bal_Latn -> root + 25, 1146, // blt_Latn -> root + 34, 1146, // bm_Nkoo -> root + 42, 1146, // bs_Cyrl -> root + 50, 1146, // byn_Latn -> root + 59, 1146, // cu_Glag -> root + 67, 1146, // dje_Arab -> root + 76, 1146, // dyo_Arab -> root 92, 85, // en_150 -> en_001 99, 85, // en_AG -> en_001 105, 85, // en_AI -> en_001 @@ -1208,161 +1212,172 @@ const int32_t parentLocaleTable[] = { 177, 85, // en_CM -> en_001 183, 85, // en_CX -> en_001 189, 85, // en_CY -> en_001 - 195, 92, // en_DE -> en_150 - 201, 85, // en_DG -> en_001 - 207, 92, // en_DK -> en_150 - 213, 85, // en_DM -> en_001 - 219, 1080, // en_Dsrt -> root - 227, 85, // en_ER -> en_001 - 233, 92, // en_FI -> en_150 - 239, 85, // en_FJ -> en_001 - 245, 85, // en_FK -> en_001 - 251, 85, // en_FM -> en_001 - 257, 85, // en_GB -> en_001 - 263, 85, // en_GD -> en_001 - 269, 85, // en_GG -> en_001 - 275, 85, // en_GH -> en_001 - 281, 85, // en_GI -> en_001 - 287, 85, // en_GM -> en_001 - 293, 85, // en_GY -> en_001 - 299, 85, // en_HK -> en_001 - 305, 85, // en_ID -> en_001 - 311, 85, // en_IE -> en_001 - 317, 85, // en_IL -> en_001 - 323, 85, // en_IM -> en_001 - 329, 85, // en_IN -> en_001 - 335, 85, // en_IO -> en_001 - 341, 85, // en_JE -> en_001 - 347, 85, // en_JM -> en_001 - 353, 85, // en_KE -> en_001 - 359, 85, // en_KI -> en_001 - 365, 85, // en_KN -> en_001 - 371, 85, // en_KY -> en_001 - 377, 85, // en_LC -> en_001 - 383, 85, // en_LR -> en_001 - 389, 85, // en_LS -> en_001 - 395, 85, // en_MG -> en_001 - 401, 85, // en_MO -> en_001 - 407, 85, // en_MS -> en_001 - 413, 85, // en_MT -> en_001 - 419, 85, // en_MU -> en_001 - 425, 85, // en_MV -> en_001 - 431, 85, // en_MW -> en_001 - 437, 85, // en_MY -> en_001 - 443, 85, // en_NA -> en_001 - 449, 85, // en_NF -> en_001 - 455, 85, // en_NG -> en_001 - 461, 92, // en_NL -> en_150 - 467, 85, // en_NR -> en_001 - 473, 85, // en_NU -> en_001 - 479, 85, // en_NZ -> en_001 - 485, 85, // en_PG -> en_001 - 491, 85, // en_PK -> en_001 - 497, 85, // en_PN -> en_001 - 503, 85, // en_PW -> en_001 - 509, 85, // en_RW -> en_001 - 515, 85, // en_SB -> en_001 - 521, 85, // en_SC -> en_001 - 527, 85, // en_SD -> en_001 - 533, 92, // en_SE -> en_150 - 539, 85, // en_SG -> en_001 - 545, 85, // en_SH -> en_001 - 551, 92, // en_SI -> en_150 - 557, 85, // en_SL -> en_001 - 563, 85, // en_SS -> en_001 - 569, 85, // en_SX -> en_001 - 575, 85, // en_SZ -> en_001 - 581, 1080, // en_Shaw -> root - 589, 85, // en_TC -> en_001 - 595, 85, // en_TK -> en_001 - 601, 85, // en_TO -> en_001 - 607, 85, // en_TT -> en_001 - 613, 85, // en_TV -> en_001 - 619, 85, // en_TZ -> en_001 - 625, 85, // en_UG -> en_001 - 631, 85, // en_VC -> en_001 - 637, 85, // en_VG -> en_001 - 643, 85, // en_VU -> en_001 - 649, 85, // en_WS -> en_001 - 655, 85, // en_ZA -> en_001 - 661, 85, // en_ZM -> en_001 - 667, 85, // en_ZW -> en_001 - 680, 673, // es_AR -> es_419 - 686, 673, // es_BO -> es_419 - 692, 673, // es_BR -> es_419 - 698, 673, // es_BZ -> es_419 - 704, 673, // es_CL -> es_419 - 710, 673, // es_CO -> es_419 - 716, 673, // es_CR -> es_419 - 722, 673, // es_CU -> es_419 - 728, 673, // es_DO -> es_419 - 734, 673, // es_EC -> es_419 - 740, 673, // es_GT -> es_419 - 746, 673, // es_HN -> es_419 - 752, 673, // es_JP -> es_419 - 758, 673, // es_MX -> es_419 - 764, 673, // es_NI -> es_419 - 770, 673, // es_PA -> es_419 - 776, 673, // es_PE -> es_419 - 782, 673, // es_PR -> es_419 - 788, 673, // es_PY -> es_419 - 794, 673, // es_SV -> es_419 - 800, 673, // es_US -> es_419 - 806, 673, // es_UY -> es_419 - 812, 673, // es_VE -> es_419 - 818, 1080, // ff_Adlm -> root - 826, 1080, // ff_Arab -> root - 840, 1080, // ha_Arab -> root - 848, 329, // hi_Latn -> en_IN - 856, 834, // ht -> fr_HT - 859, 1080, // iu_Latn -> root - 867, 1080, // kaa_Latn -> root - 876, 1080, // kk_Arab -> root - 884, 1080, // kok_Latn -> root - 893, 1080, // ks_Deva -> root - 901, 1080, // ku_Arab -> root - 909, 1080, // kxv_Deva -> root - 918, 1080, // kxv_Orya -> root - 927, 1080, // kxv_Telu -> root - 936, 1080, // ky_Arab -> root - 944, 1080, // ky_Latn -> root - 952, 1080, // ml_Arab -> root - 960, 1080, // mn_Mong -> root - 968, 1080, // mni_Mtei -> root - 977, 1080, // ms_Arab -> root - 985, 991, // nb -> no - 988, 991, // nn -> no - 994, 991, // no_NO -> no - 1000, 1080, // pa_Arab -> root - 1008, 1062, // pt_AO -> pt_PT - 1014, 1062, // pt_CH -> pt_PT - 1020, 1062, // pt_CV -> pt_PT - 1026, 1062, // pt_FR -> pt_PT - 1032, 1062, // pt_GQ -> pt_PT - 1038, 1062, // pt_GW -> pt_PT - 1044, 1062, // pt_LU -> pt_PT - 1050, 1062, // pt_MO -> pt_PT - 1056, 1062, // pt_MZ -> pt_PT - 1068, 1062, // pt_ST -> pt_PT - 1074, 1062, // pt_TL -> pt_PT - 1085, 1080, // sat_Deva -> root - 1094, 1080, // sd_Deva -> root - 1102, 1080, // sd_Khoj -> root - 1110, 1080, // sd_Sind -> root - 1118, 1080, // shi_Latn -> root - 1127, 1080, // so_Arab -> root - 1135, 1080, // sr_Latn -> root - 1143, 1080, // sw_Arab -> root - 1151, 1080, // tg_Arab -> root - 1159, 1080, // ug_Cyrl -> root - 1167, 1080, // uz_Arab -> root - 1175, 1080, // uz_Cyrl -> root - 1183, 1080, // vai_Latn -> root - 1192, 1080, // wo_Arab -> root - 1200, 1080, // yo_Arab -> root - 1208, 1080, // yue_Hans -> root - 1217, 1080, // zh_Hant -> root - 1236, 1225, // zh_Hant_MO -> zh_Hant_HK + 195, 92, // en_CZ -> en_150 + 201, 92, // en_DE -> en_150 + 207, 85, // en_DG -> en_001 + 213, 92, // en_DK -> en_150 + 219, 85, // en_DM -> en_001 + 225, 1146, // en_Dsrt -> root + 233, 85, // en_ER -> en_001 + 239, 92, // en_ES -> en_150 + 245, 92, // en_FI -> en_150 + 251, 85, // en_FJ -> en_001 + 257, 85, // en_FK -> en_001 + 263, 85, // en_FM -> en_001 + 269, 92, // en_FR -> en_150 + 275, 85, // en_GB -> en_001 + 281, 85, // en_GD -> en_001 + 287, 85, // en_GG -> en_001 + 293, 85, // en_GH -> en_001 + 299, 85, // en_GI -> en_001 + 305, 85, // en_GM -> en_001 + 311, 85, // en_GS -> en_001 + 317, 85, // en_GY -> en_001 + 323, 85, // en_HK -> en_001 + 329, 92, // en_HU -> en_150 + 335, 85, // en_ID -> en_001 + 341, 85, // en_IE -> en_001 + 347, 85, // en_IL -> en_001 + 353, 85, // en_IM -> en_001 + 359, 85, // en_IN -> en_001 + 365, 85, // en_IO -> en_001 + 371, 92, // en_IT -> en_150 + 377, 85, // en_JE -> en_001 + 383, 85, // en_JM -> en_001 + 389, 85, // en_KE -> en_001 + 395, 85, // en_KI -> en_001 + 401, 85, // en_KN -> en_001 + 407, 85, // en_KY -> en_001 + 413, 85, // en_LC -> en_001 + 419, 85, // en_LR -> en_001 + 425, 85, // en_LS -> en_001 + 431, 85, // en_MG -> en_001 + 437, 85, // en_MO -> en_001 + 443, 85, // en_MS -> en_001 + 449, 85, // en_MT -> en_001 + 455, 85, // en_MU -> en_001 + 461, 85, // en_MV -> en_001 + 467, 85, // en_MW -> en_001 + 473, 85, // en_MY -> en_001 + 479, 85, // en_NA -> en_001 + 485, 85, // en_NF -> en_001 + 491, 85, // en_NG -> en_001 + 497, 92, // en_NL -> en_150 + 503, 92, // en_NO -> en_150 + 509, 85, // en_NR -> en_001 + 515, 85, // en_NU -> en_001 + 521, 85, // en_NZ -> en_001 + 527, 85, // en_PG -> en_001 + 533, 85, // en_PK -> en_001 + 539, 92, // en_PL -> en_150 + 545, 85, // en_PN -> en_001 + 551, 92, // en_PT -> en_150 + 557, 85, // en_PW -> en_001 + 563, 92, // en_RO -> en_150 + 569, 85, // en_RW -> en_001 + 575, 85, // en_SB -> en_001 + 581, 85, // en_SC -> en_001 + 587, 85, // en_SD -> en_001 + 593, 92, // en_SE -> en_150 + 599, 85, // en_SG -> en_001 + 605, 85, // en_SH -> en_001 + 611, 92, // en_SI -> en_150 + 617, 92, // en_SK -> en_150 + 623, 85, // en_SL -> en_001 + 629, 85, // en_SS -> en_001 + 635, 85, // en_SX -> en_001 + 641, 85, // en_SZ -> en_001 + 647, 1146, // en_Shaw -> root + 655, 85, // en_TC -> en_001 + 661, 85, // en_TK -> en_001 + 667, 85, // en_TO -> en_001 + 673, 85, // en_TT -> en_001 + 679, 85, // en_TV -> en_001 + 685, 85, // en_TZ -> en_001 + 691, 85, // en_UG -> en_001 + 697, 85, // en_VC -> en_001 + 703, 85, // en_VG -> en_001 + 709, 85, // en_VU -> en_001 + 715, 85, // en_WS -> en_001 + 721, 85, // en_ZA -> en_001 + 727, 85, // en_ZM -> en_001 + 733, 85, // en_ZW -> en_001 + 746, 739, // es_AR -> es_419 + 752, 739, // es_BO -> es_419 + 758, 739, // es_BR -> es_419 + 764, 739, // es_BZ -> es_419 + 770, 739, // es_CL -> es_419 + 776, 739, // es_CO -> es_419 + 782, 739, // es_CR -> es_419 + 788, 739, // es_CU -> es_419 + 794, 739, // es_DO -> es_419 + 800, 739, // es_EC -> es_419 + 806, 739, // es_GT -> es_419 + 812, 739, // es_HN -> es_419 + 818, 739, // es_JP -> es_419 + 824, 739, // es_MX -> es_419 + 830, 739, // es_NI -> es_419 + 836, 739, // es_PA -> es_419 + 842, 739, // es_PE -> es_419 + 848, 739, // es_PR -> es_419 + 854, 739, // es_PY -> es_419 + 860, 739, // es_SV -> es_419 + 866, 739, // es_US -> es_419 + 872, 739, // es_UY -> es_419 + 878, 739, // es_VE -> es_419 + 884, 1146, // ff_Adlm -> root + 892, 1146, // ff_Arab -> root + 906, 1146, // ha_Arab -> root + 914, 359, // hi_Latn -> en_IN + 922, 900, // ht -> fr_HT + 925, 1146, // iu_Latn -> root + 933, 1146, // kaa_Latn -> root + 942, 1146, // kk_Arab -> root + 950, 1146, // kok_Latn -> root + 959, 1146, // ks_Deva -> root + 967, 1146, // ku_Arab -> root + 975, 1146, // kxv_Deva -> root + 984, 1146, // kxv_Orya -> root + 993, 1146, // kxv_Telu -> root + 1002, 1146, // ky_Arab -> root + 1010, 1146, // ky_Latn -> root + 1018, 1146, // ml_Arab -> root + 1026, 1146, // mn_Mong -> root + 1034, 1146, // mni_Mtei -> root + 1043, 1146, // ms_Arab -> root + 1051, 1057, // nb -> no + 1054, 1057, // nn -> no + 1060, 1057, // no_NO -> no + 1066, 1146, // pa_Arab -> root + 1074, 1128, // pt_AO -> pt_PT + 1080, 1128, // pt_CH -> pt_PT + 1086, 1128, // pt_CV -> pt_PT + 1092, 1128, // pt_FR -> pt_PT + 1098, 1128, // pt_GQ -> pt_PT + 1104, 1128, // pt_GW -> pt_PT + 1110, 1128, // pt_LU -> pt_PT + 1116, 1128, // pt_MO -> pt_PT + 1122, 1128, // pt_MZ -> pt_PT + 1134, 1128, // pt_ST -> pt_PT + 1140, 1128, // pt_TL -> pt_PT + 1151, 1146, // sat_Deva -> root + 1160, 1146, // sd_Deva -> root + 1168, 1146, // sd_Khoj -> root + 1176, 1146, // sd_Sind -> root + 1184, 1146, // shi_Latn -> root + 1193, 1146, // so_Arab -> root + 1201, 1146, // sr_Latn -> root + 1209, 1146, // sw_Arab -> root + 1217, 1146, // tg_Arab -> root + 1225, 1146, // ug_Cyrl -> root + 1233, 1146, // uz_Arab -> root + 1241, 1146, // uz_Cyrl -> root + 1249, 1146, // vai_Latn -> root + 1258, 1146, // wo_Arab -> root + 1266, 1146, // yo_Arab -> root + 1274, 1146, // yue_Hans -> root + 1283, 1146, // zh_Hant -> root + 1302, 1291, // zh_Hant_MO -> zh_Hant_HK }; diff --git a/contrib/libs/icu/common/locbased.cpp b/contrib/libs/icu/common/locbased.cpp index 832bc3e88b14..6f35e72210fe 100644 --- a/contrib/libs/icu/common/locbased.cpp +++ b/contrib/libs/icu/common/locbased.cpp @@ -12,44 +12,84 @@ */ #include "locbased.h" #include "cstring.h" +#include "charstr.h" U_NAMESPACE_BEGIN -Locale LocaleBased::getLocale(ULocDataLocaleType type, UErrorCode& status) const { - const char* id = getLocaleID(type, status); +Locale LocaleBased::getLocale(const CharString* valid, const CharString* actual, + ULocDataLocaleType type, UErrorCode& status) { + const char* id = getLocaleID(valid, actual, type, status); return Locale(id != nullptr ? id : ""); } -const char* LocaleBased::getLocaleID(ULocDataLocaleType type, UErrorCode& status) const { +const char* LocaleBased::getLocaleID(const CharString* valid, const CharString* actual, + ULocDataLocaleType type, UErrorCode& status) { if (U_FAILURE(status)) { return nullptr; } switch(type) { case ULOC_VALID_LOCALE: - return valid; + return valid == nullptr ? "" : valid->data(); case ULOC_ACTUAL_LOCALE: - return actual; + return actual == nullptr ? "" : actual->data(); default: status = U_ILLEGAL_ARGUMENT_ERROR; return nullptr; } } -void LocaleBased::setLocaleIDs(const char* validID, const char* actualID) { - if (validID != nullptr) { - uprv_strncpy(valid, validID, ULOC_FULLNAME_CAPACITY); - valid[ULOC_FULLNAME_CAPACITY-1] = 0; // always terminate +void LocaleBased::setLocaleIDs(const CharString* validID, const CharString* actualID, UErrorCode& status) { + setValidLocaleID(validID, status); + setActualLocaleID(actualID,status); +} +void LocaleBased::setLocaleIDs(const char* validID, const char* actualID, UErrorCode& status) { + setValidLocaleID(validID, status); + setActualLocaleID(actualID,status); +} + +void LocaleBased::setLocaleID(const char* id, CharString*& dest, UErrorCode& status) { + if (U_FAILURE(status)) { return; } + if (id == nullptr || *id == 0) { + delete dest; + dest = nullptr; + } else { + if (dest == nullptr) { + dest = new CharString(id, status); + if (dest == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return; + } + } else { + dest->copyFrom(id, status); + } } - if (actualID != nullptr) { - uprv_strncpy(actual, actualID, ULOC_FULLNAME_CAPACITY); - actual[ULOC_FULLNAME_CAPACITY-1] = 0; // always terminate +} + +void LocaleBased::setLocaleID(const CharString* id, CharString*& dest, UErrorCode& status) { + if (U_FAILURE(status)) { return; } + if (id == nullptr || id->isEmpty()) { + delete dest; + dest = nullptr; + } else { + if (dest == nullptr) { + dest = new CharString(*id, status); + if (dest == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return; + } + } else { + dest->copyFrom(*id, status); + } } } -void LocaleBased::setLocaleIDs(const Locale& validID, const Locale& actualID) { - uprv_strcpy(valid, validID.getName()); - uprv_strcpy(actual, actualID.getName()); +bool LocaleBased::equalIDs(const CharString* left, const CharString* right) { + // true if both are nullptr + if (left == nullptr && right == nullptr) return true; + // false if only one is nullptr + if (left == nullptr || right == nullptr) return false; + return *left == *right; } U_NAMESPACE_END diff --git a/contrib/libs/icu/common/locbased.h b/contrib/libs/icu/common/locbased.h index 2d260b527873..9441eb823107 100644 --- a/contrib/libs/icu/common/locbased.h +++ b/contrib/libs/icu/common/locbased.h @@ -19,13 +19,14 @@ /** * Macro to declare a locale LocaleBased wrapper object for the given * object, which must have two members named `validLocale' and - * `actualLocale' of size ULOC_FULLNAME_CAPACITY + * `actualLocale' of which are pointers to the internal icu::CharString. */ #define U_LOCALE_BASED(varname, objname) \ LocaleBased varname((objname).validLocale, (objname).actualLocale) U_NAMESPACE_BEGIN +class CharString; /** * A utility class that unifies the implementation of getLocale() by * various ICU services. This class is likely to be removed in the @@ -41,33 +42,35 @@ class U_COMMON_API LocaleBased : public UMemory { * Construct a LocaleBased wrapper around the two pointers. These * will be aliased for the lifetime of this object. */ - inline LocaleBased(char* validAlias, char* actualAlias); - - /** - * Construct a LocaleBased wrapper around the two const pointers. - * These will be aliased for the lifetime of this object. - */ - inline LocaleBased(const char* validAlias, const char* actualAlias); + inline LocaleBased(CharString*& validAlias, CharString*& actualAlias); /** * Return locale meta-data for the service object wrapped by this * object. Either the valid or the actual locale may be * retrieved. + * @param valid The valid locale. + * @param actual The actual locale. * @param type either ULOC_VALID_LOCALE or ULOC_ACTUAL_LOCALE * @param status input-output error code * @return the indicated locale */ - Locale getLocale(ULocDataLocaleType type, UErrorCode& status) const; + static Locale getLocale( + const CharString* valid, const CharString* actual, + ULocDataLocaleType type, UErrorCode& status); /** * Return the locale ID for the service object wrapped by this * object. Either the valid or the actual locale may be * retrieved. + * @param valid The valid locale. + * @param actual The actual locale. * @param type either ULOC_VALID_LOCALE or ULOC_ACTUAL_LOCALE * @param status input-output error code * @return the indicated locale ID */ - const char* getLocaleID(ULocDataLocaleType type, UErrorCode& status) const; + static const char* getLocaleID( + const CharString* valid, const CharString* actual, + ULocDataLocaleType type, UErrorCode& status); /** * Set the locale meta-data for the service object wrapped by this @@ -75,31 +78,40 @@ class U_COMMON_API LocaleBased : public UMemory { * @param valid the ID of the valid locale * @param actual the ID of the actual locale */ - void setLocaleIDs(const char* valid, const char* actual); + void setLocaleIDs(const char* valid, const char* actual, UErrorCode& status); + void setLocaleIDs(const CharString* valid, const CharString* actual, UErrorCode& status); - /** - * Set the locale meta-data for the service object wrapped by this - * object. - * @param valid the ID of the valid locale - * @param actual the ID of the actual locale - */ - void setLocaleIDs(const Locale& valid, const Locale& actual); + static void setLocaleID(const char* id, CharString*& dest, UErrorCode& status); + static void setLocaleID(const CharString* id, CharString*& dest, UErrorCode& status); + + static bool equalIDs(const CharString* left, const CharString* right); private: - char* valid; - - char* actual; + void setValidLocaleID(const CharString* id, UErrorCode& status); + void setActualLocaleID(const CharString* id, UErrorCode& status); + void setValidLocaleID(const char* id, UErrorCode& status); + void setActualLocaleID(const char* id, UErrorCode& status); + + CharString*& valid; + CharString*& actual; }; -inline LocaleBased::LocaleBased(char* validAlias, char* actualAlias) : +inline LocaleBased::LocaleBased(CharString*& validAlias, CharString*& actualAlias) : valid(validAlias), actual(actualAlias) { } -inline LocaleBased::LocaleBased(const char* validAlias, - const char* actualAlias) : - // ugh: cast away const - valid(const_cast(validAlias)), actual(const_cast(actualAlias)) { +inline void LocaleBased::setValidLocaleID(const CharString* id, UErrorCode& status) { + setLocaleID(id, valid, status); +} +inline void LocaleBased::setActualLocaleID(const CharString* id, UErrorCode& status) { + setLocaleID(id, actual, status); +} +inline void LocaleBased::setValidLocaleID(const char* id, UErrorCode& status) { + setLocaleID(id, valid, status); +} +inline void LocaleBased::setActualLocaleID(const char* id, UErrorCode& status) { + setLocaleID(id, actual, status); } U_NAMESPACE_END diff --git a/contrib/libs/icu/common/locdispnames.cpp b/contrib/libs/icu/common/locdispnames.cpp index ddf7687a2bf0..d3521e879b60 100644 --- a/contrib/libs/icu/common/locdispnames.cpp +++ b/contrib/libs/icu/common/locdispnames.cpp @@ -19,6 +19,8 @@ * that then do not depend on resource bundle code and display name data. */ +#include + #include "unicode/utypes.h" #include "unicode/brkiter.h" #include "unicode/locid.h" @@ -359,7 +361,7 @@ _getStringOrCopyKey(const char *path, const char *locale, return u_terminateUChars(dest, destCapacity, length, &errorCode); } -using UDisplayNameGetter = icu::CharString(const char*, UErrorCode&); +using UDisplayNameGetter = icu::CharString(std::string_view, UErrorCode&); int32_t _getDisplayNameForComponent(const char *locale, @@ -377,6 +379,10 @@ _getDisplayNameForComponent(const char *locale, return 0; } + if (locale == nullptr) { + locale = uloc_getDefault(); + } + localStatus = U_ZERO_ERROR; icu::CharString localeBuffer = (*getter)(locale, localStatus); if (U_FAILURE(localStatus)) { diff --git a/contrib/libs/icu/common/locid.cpp b/contrib/libs/icu/common/locid.cpp index 4a73f5592052..e7e86079ae91 100644 --- a/contrib/libs/icu/common/locid.cpp +++ b/contrib/libs/icu/common/locid.cpp @@ -1828,8 +1828,13 @@ ulocimp_isCanonicalizedLocaleForTest(const char* localeName) U_NAMESPACE_BEGIN -/*This function initializes a Locale from a C locale ID*/ Locale& Locale::init(const char* localeID, UBool canonicalize) +{ + return localeID == nullptr ? *this = getDefault() : init(StringPiece{localeID}, canonicalize); +} + +/*This function initializes a Locale from a C locale ID*/ +Locale& Locale::init(StringPiece localeID, UBool canonicalize) { fIsBogus = false; /* Free our current storage */ @@ -1854,19 +1859,28 @@ Locale& Locale::init(const char* localeID, UBool canonicalize) int32_t length; UErrorCode err; - if(localeID == nullptr) { - // not an error, just set the default locale - return *this = getDefault(); - } - /* preset all fields to empty */ language[0] = script[0] = country[0] = 0; + const auto parse = [canonicalize](std::string_view localeID, + char* name, + int32_t nameCapacity, + UErrorCode& status) { + return ByteSinkUtil::viaByteSinkToTerminatedChars( + name, nameCapacity, + [&](ByteSink& sink, UErrorCode& status) { + if (canonicalize) { + ulocimp_canonicalize(localeID, sink, status); + } else { + ulocimp_getName(localeID, sink, status); + } + }, + status); + }; + // "canonicalize" the locale ID to ICU/Java format err = U_ZERO_ERROR; - length = canonicalize ? - uloc_canonicalize(localeID, fullName, sizeof(fullNameBuffer), &err) : - uloc_getName(localeID, fullName, sizeof(fullNameBuffer), &err); + length = parse(localeID, fullName, sizeof fullNameBuffer, err); if (err == U_BUFFER_OVERFLOW_ERROR || length >= static_cast(sizeof(fullNameBuffer))) { U_ASSERT(baseName == nullptr); @@ -1877,9 +1891,7 @@ Locale& Locale::init(const char* localeID, UBool canonicalize) } fullName = newFullName; err = U_ZERO_ERROR; - length = canonicalize ? - uloc_canonicalize(localeID, fullName, length+1, &err) : - uloc_getName(localeID, fullName, length+1, &err); + length = parse(localeID, fullName, length + 1, err); } if(U_FAILURE(err) || err == U_STRING_NOT_TERMINATED_WARNING) { /* should never occur */ @@ -2200,6 +2212,13 @@ Locale::createFromName (const char *name) } } +Locale U_EXPORT2 +Locale::createFromName(StringPiece name) { + Locale loc(""); + loc.init(name, false); + return loc; +} + Locale U_EXPORT2 Locale::createCanonical(const char* name) { Locale loc(""); diff --git a/contrib/libs/icu/common/loclikely.cpp b/contrib/libs/icu/common/loclikely.cpp index ccbcbfa7a5d7..f87fd8dd61ca 100644 --- a/contrib/libs/icu/common/loclikely.cpp +++ b/contrib/libs/icu/common/loclikely.cpp @@ -300,6 +300,9 @@ ulocimp_addLikelySubtags(const char* localeID, icu::ByteSink& sink, UErrorCode& status) { if (U_FAILURE(status)) { return; } + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } icu::CharString localeBuffer = ulocimp_canonicalize(localeID, status); _uloc_addLikelySubtags(localeBuffer.data(), sink, status); } @@ -334,6 +337,9 @@ ulocimp_minimizeSubtags(const char* localeID, bool favorScript, UErrorCode& status) { if (U_FAILURE(status)) { return; } + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } icu::CharString localeBuffer = ulocimp_canonicalize(localeID, status); _uloc_minimizeSubtags(localeBuffer.data(), sink, favorScript, status); } @@ -349,7 +355,9 @@ uloc_isRightToLeft(const char *locale) { UErrorCode errorCode = U_ZERO_ERROR; icu::CharString lang; icu::CharString script; - ulocimp_getSubtags(locale, &lang, &script, nullptr, nullptr, nullptr, errorCode); + ulocimp_getSubtags( + locale == nullptr ? uloc_getDefault() : locale, + &lang, &script, nullptr, nullptr, nullptr, errorCode); if (U_FAILURE(errorCode) || script.isEmpty()) { // Fastpath: We know the likely scripts and their writing direction // for some common languages. @@ -369,7 +377,7 @@ uloc_isRightToLeft(const char *locale) { if (U_FAILURE(errorCode)) { return false; } - ulocimp_getSubtags(likely.data(), nullptr, &script, nullptr, nullptr, nullptr, errorCode); + ulocimp_getSubtags(likely.toStringPiece(), nullptr, &script, nullptr, nullptr, nullptr, errorCode); if (U_FAILURE(errorCode) || script.isEmpty()) { return false; } @@ -430,7 +438,7 @@ ulocimp_getRegionForSupplementalData(const char *localeID, bool inferRegion, icu::CharString rgBuf = GetRegionFromKey(localeID, "rg", status); if (U_SUCCESS(status) && rgBuf.isEmpty()) { // No valid rg keyword value, try for unicode_region_subtag - rgBuf = ulocimp_getRegion(localeID, status); + rgBuf = ulocimp_getRegion(localeID == nullptr ? uloc_getDefault() : localeID, status); if (U_SUCCESS(status) && rgBuf.isEmpty() && inferRegion) { // Second check for sd keyword value rgBuf = GetRegionFromKey(localeID, "sd", status); @@ -439,7 +447,7 @@ ulocimp_getRegionForSupplementalData(const char *localeID, bool inferRegion, UErrorCode rgStatus = U_ZERO_ERROR; icu::CharString locBuf = ulocimp_addLikelySubtags(localeID, rgStatus); if (U_SUCCESS(rgStatus)) { - rgBuf = ulocimp_getRegion(locBuf.data(), status); + rgBuf = ulocimp_getRegion(locBuf.toStringPiece(), status); } } } diff --git a/contrib/libs/icu/common/loclikelysubtags.cpp b/contrib/libs/icu/common/loclikelysubtags.cpp index 7c6131197d89..7245a779816c 100644 --- a/contrib/libs/icu/common/loclikelysubtags.cpp +++ b/contrib/libs/icu/common/loclikelysubtags.cpp @@ -527,7 +527,7 @@ LSR LikelySubtags::makeMaximizedLsrFrom(const Locale &locale, return {}; } const char *name = locale.getName(); - if (uprv_isAtSign(name[0]) && name[1] == 'x' && name[2] == '=') { // name.startsWith("@x=") + if (!returnInputIfUnmatch && uprv_isAtSign(name[0]) && name[1] == 'x' && name[2] == '=') { // name.startsWith("@x=") // Private use language tag x-subtag-subtag... which CLDR changes to // und-x-subtag-subtag... return LSR(name, "", "", LSR::EXPLICIT_LSR); diff --git a/contrib/libs/icu/common/locresdata.cpp b/contrib/libs/icu/common/locresdata.cpp index 725e66091598..ba7163fa2dba 100644 --- a/contrib/libs/icu/common/locresdata.cpp +++ b/contrib/libs/icu/common/locresdata.cpp @@ -161,6 +161,9 @@ _uloc_getOrientationHelper(const char* localeId, if (U_FAILURE(status)) { return result; } + if (localeId == nullptr) { + localeId = uloc_getDefault(); + } icu::CharString localeBuffer = ulocimp_canonicalize(localeId, status); if (U_FAILURE(status)) { return result; } diff --git a/contrib/libs/icu/common/punycode.cpp b/contrib/libs/icu/common/punycode.cpp index aa02298c5e6d..1868a07a856a 100644 --- a/contrib/libs/icu/common/punycode.cpp +++ b/contrib/libs/icu/common/punycode.cpp @@ -193,7 +193,7 @@ u_strToPunycode(const char16_t *src, int32_t srcLength, return 0; } - if(src==nullptr || srcLength<-1 || (dest==nullptr && destCapacity!=0)) { + if(src==nullptr || srcLength<-1 || destCapacity<0 || (dest==nullptr && destCapacity!=0)) { *pErrorCode=U_ILLEGAL_ARGUMENT_ERROR; return 0; } diff --git a/contrib/libs/icu/common/putil.cpp b/contrib/libs/icu/common/putil.cpp index a3af233d069a..8411fd29df3e 100644 --- a/contrib/libs/icu/common/putil.cpp +++ b/contrib/libs/icu/common/putil.cpp @@ -76,7 +76,7 @@ #include #ifndef U_COMMON_IMPLEMENTATION -#error U_COMMON_IMPLEMENTATION not set - must be set for all ICU source files in common/ - see https://unicode-org.github.io/icu/userguide/howtouseicu +#error U_COMMON_IMPLEMENTATION not set - must be set for all ICU source files in common/ - see https://unicode-org.github.io/icu/userguide/icu/howtouseicu.html #endif diff --git a/contrib/libs/icu/common/rbbinode.cpp b/contrib/libs/icu/common/rbbinode.cpp index 71407b9e684e..849ee7180a22 100644 --- a/contrib/libs/icu/common/rbbinode.cpp +++ b/contrib/libs/icu/common/rbbinode.cpp @@ -47,7 +47,10 @@ static int gLastSerial = 0; // Constructor. Just set the fields to reasonable default values. // //------------------------------------------------------------------------- -RBBINode::RBBINode(NodeType t) : UMemory() { +RBBINode::RBBINode(NodeType t, UErrorCode& status) : UMemory() { + if (U_FAILURE(status)) { + return; + } #ifdef RBBI_DEBUG fSerialNum = ++gLastSerial; #endif @@ -65,10 +68,13 @@ RBBINode::RBBINode(NodeType t) : UMemory() { fVal = 0; fPrecedence = precZero; - UErrorCode status = U_ZERO_ERROR; - fFirstPosSet = new UVector(status); // TODO - get a real status from somewhere + fFirstPosSet = new UVector(status); fLastPosSet = new UVector(status); fFollowPos = new UVector(status); + if (U_SUCCESS(status) && + (fFirstPosSet == nullptr || fLastPosSet == nullptr || fFollowPos == nullptr)) { + status = U_MEMORY_ALLOCATION_ERROR; + } if (t==opCat) {fPrecedence = precOpCat;} else if (t==opOr) {fPrecedence = precOpOr;} else if (t==opStart) {fPrecedence = precStart;} @@ -77,7 +83,10 @@ RBBINode::RBBINode(NodeType t) : UMemory() { } -RBBINode::RBBINode(const RBBINode &other) : UMemory(other) { +RBBINode::RBBINode(const RBBINode &other, UErrorCode& status) : UMemory(other) { + if (U_FAILURE(status)) { + return; + } #ifdef RBBI_DEBUG fSerialNum = ++gLastSerial; #endif @@ -94,10 +103,13 @@ RBBINode::RBBINode(const RBBINode &other) : UMemory(other) { fVal = other.fVal; fRuleRoot = false; fChainIn = other.fChainIn; - UErrorCode status = U_ZERO_ERROR; fFirstPosSet = new UVector(status); // TODO - get a real status from somewhere fLastPosSet = new UVector(status); fFollowPos = new UVector(status); + if (U_SUCCESS(status) && + (fFirstPosSet == nullptr || fLastPosSet == nullptr || fFollowPos == nullptr)) { + status = U_MEMORY_ALLOCATION_ERROR; + } } @@ -193,27 +205,54 @@ void RBBINode::NRDeleteNode(RBBINode *node) { // references in preparation for generating the DFA tables. // //------------------------------------------------------------------------- -RBBINode *RBBINode::cloneTree() { +constexpr int kRecursiveDepthLimit = 3500; +RBBINode *RBBINode::cloneTree(UErrorCode &status, int depth) { + if (U_FAILURE(status)) { + return nullptr; + } + // If the depth of the stack is too deep, we return U_INPUT_TOO_LONG_ERROR + // to avoid stack overflow crash. + if (depth > kRecursiveDepthLimit) { + status = U_INPUT_TOO_LONG_ERROR; + return nullptr; + } RBBINode *n; if (fType == RBBINode::varRef) { // If the current node is a variable reference, skip over it // and clone the definition of the variable instead. - n = fLeftChild->cloneTree(); + n = fLeftChild->cloneTree(status, depth+1); + if (U_FAILURE(status)) { + return nullptr; + } } else if (fType == RBBINode::uset) { n = this; } else { - n = new RBBINode(*this); + n = new RBBINode(*this, status); + if (U_FAILURE(status)) { + delete n; + return nullptr; + } // Check for null pointer. - if (n != nullptr) { - if (fLeftChild != nullptr) { - n->fLeftChild = fLeftChild->cloneTree(); - n->fLeftChild->fParent = n; + if (n == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + } + if (fLeftChild != nullptr) { + n->fLeftChild = fLeftChild->cloneTree(status, depth+1); + if (U_FAILURE(status)) { + delete n; + return nullptr; } - if (fRightChild != nullptr) { - n->fRightChild = fRightChild->cloneTree(); - n->fRightChild->fParent = n; + n->fLeftChild->fParent = n; + } + if (fRightChild != nullptr) { + n->fRightChild = fRightChild->cloneTree(status, depth+1); + if (U_FAILURE(status)) { + delete n; + return nullptr; } + n->fRightChild->fParent = n; } } return n; @@ -239,7 +278,6 @@ RBBINode *RBBINode::cloneTree() { // nested references are handled by cloneTree(), not here. // //------------------------------------------------------------------------- -constexpr int kRecursiveDepthLimit = 3500; RBBINode *RBBINode::flattenVariables(UErrorCode& status, int depth) { if (U_FAILURE(status)) { return this; @@ -251,21 +289,34 @@ RBBINode *RBBINode::flattenVariables(UErrorCode& status, int depth) { return this; } if (fType == varRef) { - RBBINode *retNode = fLeftChild->cloneTree(); - if (retNode != nullptr) { - retNode->fRuleRoot = this->fRuleRoot; - retNode->fChainIn = this->fChainIn; + RBBINode *retNode = fLeftChild->cloneTree(status, depth+1); + if (U_FAILURE(status)) { + return this; } + retNode->fRuleRoot = this->fRuleRoot; + retNode->fChainIn = this->fChainIn; delete this; // TODO: undefined behavior. Fix. return retNode; } if (fLeftChild != nullptr) { fLeftChild = fLeftChild->flattenVariables(status, depth+1); + if (fLeftChild == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(status)) { + return this; + } fLeftChild->fParent = this; } if (fRightChild != nullptr) { fRightChild = fRightChild->flattenVariables(status, depth+1); + if (fRightChild == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(status)) { + return this; + } fRightChild->fParent = this; } return this; @@ -280,7 +331,16 @@ RBBINode *RBBINode::flattenVariables(UErrorCode& status, int depth) { // the left child of the uset node. // //------------------------------------------------------------------------- -void RBBINode::flattenSets() { +void RBBINode::flattenSets(UErrorCode &status, int depth) { + if (U_FAILURE(status)) { + return; + } + // If the depth of the stack is too deep, we return U_INPUT_TOO_LONG_ERROR + // to avoid stack overflow crash. + if (depth > kRecursiveDepthLimit) { + status = U_INPUT_TOO_LONG_ERROR; + return; + } U_ASSERT(fType != setRef); if (fLeftChild != nullptr) { @@ -288,11 +348,15 @@ void RBBINode::flattenSets() { RBBINode *setRefNode = fLeftChild; RBBINode *usetNode = setRefNode->fLeftChild; RBBINode *replTree = usetNode->fLeftChild; - fLeftChild = replTree->cloneTree(); + fLeftChild = replTree->cloneTree(status, depth+1); + if (U_FAILURE(status)) { + delete setRefNode; + return; + } fLeftChild->fParent = this; delete setRefNode; } else { - fLeftChild->flattenSets(); + fLeftChild->flattenSets(status, depth+1); } } @@ -301,11 +365,15 @@ void RBBINode::flattenSets() { RBBINode *setRefNode = fRightChild; RBBINode *usetNode = setRefNode->fLeftChild; RBBINode *replTree = usetNode->fLeftChild; - fRightChild = replTree->cloneTree(); + fRightChild = replTree->cloneTree(status, depth+1); + if (U_FAILURE(status)) { + delete setRefNode; + return; + } fRightChild->fParent = this; delete setRefNode; } else { - fRightChild->flattenSets(); + fRightChild->flattenSets(status, depth+1); } } } diff --git a/contrib/libs/icu/common/rbbinode.h b/contrib/libs/icu/common/rbbinode.h index 497a31b8d098..8fbc9d1b588e 100644 --- a/contrib/libs/icu/common/rbbinode.h +++ b/contrib/libs/icu/common/rbbinode.h @@ -91,14 +91,14 @@ class RBBINode : public UMemory { UVector *fFollowPos; - RBBINode(NodeType t); - RBBINode(const RBBINode &other); + RBBINode(NodeType t, UErrorCode& status); + RBBINode(const RBBINode &other, UErrorCode& status); ~RBBINode(); static void NRDeleteNode(RBBINode *node); - RBBINode *cloneTree(); + RBBINode *cloneTree(UErrorCode &status, int depth=0); RBBINode *flattenVariables(UErrorCode &status, int depth=0); - void flattenSets(); + void flattenSets(UErrorCode &status, int depth=0); void findNodes(UVector *dest, RBBINode::NodeType kind, UErrorCode &status); #ifdef RBBI_DEBUG diff --git a/contrib/libs/icu/common/rbbiscan.cpp b/contrib/libs/icu/common/rbbiscan.cpp index cf2d63cd807b..77fc3bcd9b7e 100644 --- a/contrib/libs/icu/common/rbbiscan.cpp +++ b/contrib/libs/icu/common/rbbiscan.cpp @@ -767,15 +767,24 @@ void RBBIRuleScanner::findSetFor(const UnicodeString &s, RBBINode *node, Unicode c = s.char32At(0); setToAdopt = new UnicodeSet(c, c); } + if (setToAdopt == nullptr) { + error(U_MEMORY_ALLOCATION_ERROR); + return; + } } // // Make a new uset node to refer to this UnicodeSet // This new uset node becomes the child of the caller's setReference node. // - RBBINode *usetNode = new RBBINode(RBBINode::uset); + UErrorCode localStatus = U_ZERO_ERROR; + RBBINode *usetNode = new RBBINode(RBBINode::uset, localStatus); if (usetNode == nullptr) { - error(U_MEMORY_ALLOCATION_ERROR); + localStatus = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(localStatus)) { + delete usetNode; + error(localStatus); delete setToAdopt; return; } @@ -1191,7 +1200,7 @@ RBBINode *RBBIRuleScanner::pushNewNode(RBBINode::NodeType t) { return nullptr; } fNodeStackPtr++; - fNodeStack[fNodeStackPtr] = new RBBINode(t); + fNodeStack[fNodeStackPtr] = new RBBINode(t, *fRB->fStatus); if (fNodeStack[fNodeStackPtr] == nullptr) { *fRB->fStatus = U_MEMORY_ALLOCATION_ERROR; } diff --git a/contrib/libs/icu/common/rbbisetb.cpp b/contrib/libs/icu/common/rbbisetb.cpp index 6c22cf470f8b..df94fc8bc4fb 100644 --- a/contrib/libs/icu/common/rbbisetb.cpp +++ b/contrib/libs/icu/common/rbbisetb.cpp @@ -375,7 +375,11 @@ void RBBISetBuilder::addValToSets(UVector *sets, uint32_t val) { } void RBBISetBuilder::addValToSet(RBBINode *usetNode, uint32_t val) { - RBBINode *leafNode = new RBBINode(RBBINode::leafChar); + RBBINode *leafNode = new RBBINode(RBBINode::leafChar, *fStatus); + if (U_FAILURE(*fStatus)) { + delete leafNode; + return; + } if (leafNode == nullptr) { *fStatus = U_MEMORY_ALLOCATION_ERROR; return; @@ -388,9 +392,13 @@ void RBBISetBuilder::addValToSet(RBBINode *usetNode, uint32_t val) { // There are already input symbols present for this set. // Set up an OR node, with the previous stuff as the left child // and the new value as the right child. - RBBINode *orNode = new RBBINode(RBBINode::opOr); + RBBINode *orNode = new RBBINode(RBBINode::opOr, *fStatus); if (orNode == nullptr) { *fStatus = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(*fStatus)) { + delete orNode; + delete leafNode; return; } orNode->fLeftChild = usetNode->fLeftChild; diff --git a/contrib/libs/icu/common/rbbitblb.cpp b/contrib/libs/icu/common/rbbitblb.cpp index 4d95137601ef..b89909807c20 100644 --- a/contrib/libs/icu/common/rbbitblb.cpp +++ b/contrib/libs/icu/common/rbbitblb.cpp @@ -99,13 +99,22 @@ void RBBITableBuilder::buildForwardTable() { // {bof} fake character. // if (fRB->fSetBuilder->sawBOF()) { - RBBINode *bofTop = new RBBINode(RBBINode::opCat); - RBBINode *bofLeaf = new RBBINode(RBBINode::leafChar); - // Delete and exit if memory allocation failed. - if (bofTop == nullptr || bofLeaf == nullptr) { + RBBINode *bofTop = new RBBINode(RBBINode::opCat, *fStatus); + if (bofTop == nullptr) { *fStatus = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(*fStatus)) { delete bofTop; + return; + } + RBBINode *bofLeaf = new RBBINode(RBBINode::leafChar, *fStatus); + // Delete and exit if memory allocation failed. + if (bofLeaf == nullptr) { + *fStatus = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(*fStatus)) { delete bofLeaf; + delete bofTop; return; } bofTop->fLeftChild = bofLeaf; @@ -120,18 +129,23 @@ void RBBITableBuilder::buildForwardTable() { // Appears as a cat-node, left child being the original tree, // right child being the end marker. // - RBBINode *cn = new RBBINode(RBBINode::opCat); + RBBINode *cn = new RBBINode(RBBINode::opCat, *fStatus); // Exit if memory allocation failed. if (cn == nullptr) { *fStatus = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(*fStatus)) { + delete cn; return; } cn->fLeftChild = fTree; fTree->fParent = cn; - RBBINode *endMarkerNode = cn->fRightChild = new RBBINode(RBBINode::endMark); + RBBINode *endMarkerNode = cn->fRightChild = new RBBINode(RBBINode::endMark, *fStatus); // Delete and exit if memory allocation failed. if (cn->fRightChild == nullptr) { *fStatus = U_MEMORY_ALLOCATION_ERROR; + } + if (U_FAILURE(*fStatus)) { delete cn; return; } @@ -142,7 +156,7 @@ void RBBITableBuilder::buildForwardTable() { // Replace all references to UnicodeSets with the tree for the equivalent // expression. // - fTree->flattenSets(); + fTree->flattenSets(*fStatus, 0); #ifdef RBBI_DEBUG if (fRB->fDebugEnv && uprv_strstr(fRB->fDebugEnv, "stree")) { RBBIDebugPuts("\nParse tree after flattening Unicode Set references."); diff --git a/contrib/libs/icu/common/resbund.cpp b/contrib/libs/icu/common/resbund.cpp index 41337cdc155d..4c14dae133ee 100644 --- a/contrib/libs/icu/common/resbund.cpp +++ b/contrib/libs/icu/common/resbund.cpp @@ -388,7 +388,7 @@ const Locale &ResourceBundle::getLocale() const { return ncThis->fLocale != nullptr ? *ncThis->fLocale : Locale::getDefault(); } -const Locale ResourceBundle::getLocale(ULocDataLocaleType type, UErrorCode &status) const +Locale ResourceBundle::getLocale(ULocDataLocaleType type, UErrorCode &status) const { return ures_getLocaleByType(fResource, type, &status); } diff --git a/contrib/libs/icu/common/ucnvmbcs.cpp b/contrib/libs/icu/common/ucnvmbcs.cpp index f5507043bf35..d65c28474616 100644 --- a/contrib/libs/icu/common/ucnvmbcs.cpp +++ b/contrib/libs/icu/common/ucnvmbcs.cpp @@ -3146,11 +3146,8 @@ ucnv_MBCSGetNextUChar(UConverterToUnicodeArgs *pArgs, if(c<0) { if(U_SUCCESS(*pErrorCode) && source==sourceLimit && lastSourcetoUBytes; cnv->toULength = static_cast(source - lastSource); - do { - *bytes++=*lastSource++; - } while(lastSourcetoUBytes, lastSource, cnv->toULength); *pErrorCode=U_TRUNCATED_CHAR_FOUND; } else if(U_FAILURE(*pErrorCode)) { /* callback(illegal) */ diff --git a/contrib/libs/icu/common/ucurr.cpp b/contrib/libs/icu/common/ucurr.cpp index b74a80a676af..cccf1130ae8e 100644 --- a/contrib/libs/icu/common/ucurr.cpp +++ b/contrib/libs/icu/common/ucurr.cpp @@ -372,12 +372,8 @@ struct CReg : public icu::UMemory { CReg(const char16_t* _iso, const char* _id) : next(nullptr) { - int32_t len = static_cast(uprv_strlen(_id)); - if (len > static_cast(sizeof(id) - 1)) { - len = (sizeof(id)-1); - } - uprv_strncpy(id, _id, len); - id[len] = 0; + uprv_strncpy(id, _id, sizeof(id)-1); + id[sizeof(id)-1] = 0; u_memcpy(iso, _iso, ISO_CURRENCY_CODE_LENGTH); iso[ISO_CURRENCY_CODE_LENGTH] = 0; } @@ -682,6 +678,9 @@ ucurr_getName(const char16_t* currency, // this function. UErrorCode ec2 = U_ZERO_ERROR; + if (locale == nullptr) { + locale = uloc_getDefault(); + } CharString loc = ulocimp_getName(locale, ec2); if (U_FAILURE(ec2)) { *ec = U_ILLEGAL_ARGUMENT_ERROR; @@ -780,6 +779,9 @@ ucurr_getPluralName(const char16_t* currency, // this function. UErrorCode ec2 = U_ZERO_ERROR; + if (locale == nullptr) { + locale = uloc_getDefault(); + } CharString loc = ulocimp_getName(locale, ec2); if (U_FAILURE(ec2)) { *ec = U_ILLEGAL_ARGUMENT_ERROR; @@ -973,6 +975,9 @@ collectCurrencyNames(const char* locale, // Look up the Currencies resource for the given locale. UErrorCode ec2 = U_ZERO_ERROR; + if (locale == nullptr) { + locale = uloc_getDefault(); + } CharString loc = ulocimp_getName(locale, ec2); if (U_FAILURE(ec2)) { ec = U_ILLEGAL_ARGUMENT_ERROR; diff --git a/contrib/libs/icu/common/uloc.cpp b/contrib/libs/icu/common/uloc.cpp index 51887c97c3e1..bea4827a0498 100644 --- a/contrib/libs/icu/common/uloc.cpp +++ b/contrib/libs/icu/common/uloc.cpp @@ -482,8 +482,8 @@ constexpr CanonicalizationMap CANONICALIZE_MAP[] = { /* ### BCP47 Conversion *******************************************/ /* Gets the size of the shortest subtag in the given localeID. */ -int32_t getShortestSubtagLength(const char *localeID) { - int32_t localeIDLength = static_cast(uprv_strlen(localeID)); +int32_t getShortestSubtagLength(std::string_view localeID) { + int32_t localeIDLength = static_cast(localeID.length()); int32_t length = localeIDLength; int32_t tmpLength = 0; int32_t i; @@ -507,8 +507,8 @@ int32_t getShortestSubtagLength(const char *localeID) { return length; } /* Test if the locale id has BCP47 u extension and does not have '@' */ -inline bool _hasBCP47Extension(const char *id) { - return id != nullptr && uprv_strstr(id, "@") == nullptr && getShortestSubtagLength(id) == 1; +inline bool _hasBCP47Extension(std::string_view id) { + return id.find('@') == std::string_view::npos && getShortestSubtagLength(id) == 1; } /* ### Keywords **************************************************/ @@ -523,10 +523,9 @@ inline bool UPRV_OK_VALUE_PUNCTUATION(char c) { return c == '_' || c == '-' || c #define ULOC_MAX_NO_KEYWORDS 25 U_CAPI const char * U_EXPORT2 -locale_getKeywordsStart(const char *localeID) { - const char *result = nullptr; - if((result = uprv_strchr(localeID, '@')) != nullptr) { - return result; +locale_getKeywordsStart(std::string_view localeID) { + if (size_t pos = localeID.find('@'); pos != std::string_view::npos) { + return localeID.data() + pos; } #if (U_CHARSET_FAMILY == U_EBCDIC_FAMILY) else { @@ -536,8 +535,8 @@ locale_getKeywordsStart(const char *localeID) { static const uint8_t ebcdicSigns[] = { 0x7C, 0x44, 0x66, 0x80, 0xAC, 0xAE, 0xAF, 0xB5, 0xEC, 0xEF, 0x00 }; const uint8_t *charToFind = ebcdicSigns; while(*charToFind) { - if((result = uprv_strchr(localeID, *charToFind)) != nullptr) { - return result; + if (size_t pos = localeID.find(*charToFind); pos != std::string_view::npos) { + return localeID.data() + pos; } charToFind++; } @@ -590,7 +589,7 @@ compareKeywordStructs(const void * /*context*/, const void *left, const void *ri } // namespace U_EXPORT CharString -ulocimp_getKeywords(const char* localeID, +ulocimp_getKeywords(std::string_view localeID, char prev, bool valuesToo, UErrorCode& status) @@ -607,7 +606,7 @@ ulocimp_getKeywords(const char* localeID, } U_EXPORT void -ulocimp_getKeywords(const char* localeID, +ulocimp_getKeywords(std::string_view localeID, char prev, ByteSink& sink, bool valuesToo, @@ -619,9 +618,8 @@ ulocimp_getKeywords(const char* localeID, int32_t maxKeywords = ULOC_MAX_NO_KEYWORDS; int32_t numKeywords = 0; - const char* pos = localeID; - const char* equalSign = nullptr; - const char* semicolon = nullptr; + size_t equalSign = std::string_view::npos; + size_t semicolon = std::string_view::npos; int32_t i = 0, j, n; if(prev == '@') { /* start of keyword definition */ @@ -629,74 +627,72 @@ ulocimp_getKeywords(const char* localeID, do { bool duplicate = false; /* skip leading spaces */ - while(*pos == ' ') { - pos++; + while (localeID.front() == ' ') { + localeID.remove_prefix(1); } - if (!*pos) { /* handle trailing "; " */ + if (localeID.empty()) { /* handle trailing "; " */ break; } if(numKeywords == maxKeywords) { status = U_INTERNAL_PROGRAM_ERROR; return; } - equalSign = uprv_strchr(pos, '='); - semicolon = uprv_strchr(pos, ';'); + equalSign = localeID.find('='); + semicolon = localeID.find(';'); /* lack of '=' [foo@currency] is illegal */ /* ';' before '=' [foo@currency;collation=pinyin] is illegal */ - if(!equalSign || (semicolon && semicolon= ULOC_KEYWORD_BUFFER_LEN) { + if (equalSign >= ULOC_KEYWORD_BUFFER_LEN) { /* keyword name too long for internal buffer */ status = U_INTERNAL_PROGRAM_ERROR; return; } - for(i = 0, n = 0; i < equalSign - pos; ++i) { - if (pos[i] != ' ') { - keywordList[numKeywords].keyword[n++] = uprv_tolower(pos[i]); + for (i = 0, n = 0; static_cast(i) < equalSign; ++i) { + if (localeID[i] != ' ') { + keywordList[numKeywords].keyword[n++] = uprv_tolower(localeID[i]); } } - /* zero-length keyword is an error. */ - if (n == 0) { - status = U_INVALID_FORMAT_ERROR; - return; - } - keywordList[numKeywords].keyword[n] = 0; keywordList[numKeywords].keywordLen = n; /* now grab the value part. First we skip the '=' */ equalSign++; /* then we leading spaces */ - while(*equalSign == ' ') { + while (equalSign < localeID.length() && localeID[equalSign] == ' ') { equalSign++; } /* Premature end or zero-length value */ - if (!*equalSign || equalSign == semicolon) { + if (equalSign == localeID.length() || equalSign == semicolon) { status = U_INVALID_FORMAT_ERROR; return; } - keywordList[numKeywords].valueStart = equalSign; + keywordList[numKeywords].valueStart = localeID.data() + equalSign; - pos = semicolon; - i = 0; - if(pos) { - while(*(pos - i - 1) == ' ') { - i++; - } - keywordList[numKeywords].valueLen = static_cast(pos - equalSign - i); - pos++; + std::string_view value = localeID; + if (semicolon != std::string_view::npos) { + value.remove_suffix(value.length() - semicolon); + localeID.remove_prefix(semicolon + 1); } else { - i = static_cast(uprv_strlen(equalSign)); - while(i && equalSign[i-1] == ' ') { - i--; - } - keywordList[numKeywords].valueLen = i; + localeID = {}; } + value.remove_prefix(equalSign); + if (size_t last = value.find_last_not_of(' '); last != std::string_view::npos) { + value.remove_suffix(value.length() - last - 1); + } + keywordList[numKeywords].valueLen = static_cast(value.length()); + /* If this is a duplicate keyword, then ignore it */ for (j=0; j(locale_getKeywordsStart(buffer)); + char* keywords = const_cast( + locale_getKeywordsStart({buffer, static_cast(bufLen)})); int32_t baseLen = keywords == nullptr ? bufLen : keywords - buffer; // Remove -1 from the capacity so that this function can guarantee NUL termination. CheckedArrayByteSink sink(keywords == nullptr ? buffer + bufLen : keywords, @@ -921,7 +918,7 @@ ulocimp_setKeywordValue(std::string_view keywordName, { if (U_FAILURE(status)) { return; } std::string_view keywords; - if (const char* start = locale_getKeywordsStart(localeID.data()); start != nullptr) { + if (const char* start = locale_getKeywordsStart(localeID.toStringPiece()); start != nullptr) { // This is safe because CharString::truncate() doesn't actually erase any // data, but simply sets the position for where new data will be written. int32_t size = start - localeID.data(); @@ -1138,15 +1135,18 @@ inline bool _isPrefixLetter(char a) { return a == 'x' || a == 'X' || a == 'i' || /*returns true if one of the special prefixes is here (s=string) 'x-' or 'i-' */ -inline bool _isIDPrefix(const char *s) { return _isPrefixLetter(s[0]) && _isIDSeparator(s[1]); } +inline bool _isIDPrefix(std::string_view s) { + return s.size() >= 2 && _isPrefixLetter(s[0]) && _isIDSeparator(s[1]); +} /* Dot terminates it because of POSIX form where dot precedes the codepage * except for variant */ -inline bool _isTerminator(char a) { return a == 0 || a == '.' || a == '@'; } +inline bool _isTerminator(char a) { return a == '.' || a == '@'; } -inline bool _isBCP47Extension(const char* p) { - return p[0] == '-' && +inline bool _isBCP47Extension(std::string_view p) { + return p.size() >= 3 && + p[0] == '-' && (p[1] == 't' || p[1] == 'T' || p[1] == 'u' || p[1] == 'U' || p[1] == 'x' || p[1] == 'X') && @@ -1202,49 +1202,44 @@ namespace { * TODO try to use this in Locale */ -void -_getLanguage(const char* localeID, - ByteSink* sink, - const char** pEnd, - UErrorCode& status) { - U_ASSERT(pEnd != nullptr); - *pEnd = localeID; - - if (uprv_stricmp(localeID, "root") == 0) { - localeID += 4; - } else if (uprv_strnicmp(localeID, "und", 3) == 0 && - (localeID[3] == '\0' || +size_t _getLanguage(std::string_view localeID, ByteSink* sink, UErrorCode& status) { + size_t skip = 0; + if (localeID.size() == 4 && uprv_strnicmp(localeID.data(), "root", 4) == 0) { + skip = 4; + localeID.remove_prefix(skip); + } else if (localeID.size() >= 3 && uprv_strnicmp(localeID.data(), "und", 3) == 0 && + (localeID.size() == 3 || localeID[3] == '-' || localeID[3] == '_' || localeID[3] == '@')) { - localeID += 3; + skip = 3; + localeID.remove_prefix(skip); } constexpr int32_t MAXLEN = ULOC_LANG_CAPACITY - 1; // Minus NUL. /* if it starts with i- or x- then copy that prefix */ - int32_t len = _isIDPrefix(localeID) ? 2 : 0; - while (!_isTerminator(localeID[len]) && !_isIDSeparator(localeID[len])) { + size_t len = _isIDPrefix(localeID) ? 2 : 0; + while (len < localeID.size() && !_isTerminator(localeID[len]) && !_isIDSeparator(localeID[len])) { if (len == MAXLEN) { status = U_ILLEGAL_ARGUMENT_ERROR; - return; + return 0; } len++; } - *pEnd = localeID + len; - if (sink == nullptr || len == 0) { return; } + if (sink == nullptr || len == 0) { return skip + len; } - int32_t minCapacity = uprv_max(len, 4); // Minimum 3 letters plus NUL. + int32_t minCapacity = uprv_max(static_cast(len), 4); // Minimum 3 letters plus NUL. char scratch[MAXLEN]; int32_t capacity = 0; char* buffer = sink->GetAppendBuffer( minCapacity, minCapacity, scratch, UPRV_LENGTHOF(scratch), &capacity); - for (int32_t i = 0; i < len; ++i) { + for (size_t i = 0; i < len; ++i) { buffer[i] = uprv_tolower(localeID[i]); } - if (_isIDSeparator(localeID[1])) { + if (localeID.size() >= 2 && _isIDSeparator(localeID[1])) { buffer[1] = '-'; } @@ -1256,32 +1251,26 @@ _getLanguage(const char* localeID, if (offset.has_value()) { const char* const alias = LANGUAGES[*offset]; sink->Append(alias, static_cast(uprv_strlen(alias))); - return; + return skip + len; } } - sink->Append(buffer, len); + sink->Append(buffer, static_cast(len)); + return skip + len; } -void -_getScript(const char* localeID, - ByteSink* sink, - const char** pEnd) { - U_ASSERT(pEnd != nullptr); - *pEnd = localeID; - +size_t _getScript(std::string_view localeID, ByteSink* sink) { constexpr int32_t LENGTH = 4; - int32_t len = 0; - while (!_isTerminator(localeID[len]) && !_isIDSeparator(localeID[len]) && + size_t len = 0; + while (len < localeID.size() && !_isTerminator(localeID[len]) && !_isIDSeparator(localeID[len]) && uprv_isASCIILetter(localeID[len])) { - if (len == LENGTH) { return; } + if (len == LENGTH) { return 0; } len++; } - if (len != LENGTH) { return; } + if (len != LENGTH) { return 0; } - *pEnd = localeID + LENGTH; - if (sink == nullptr) { return; } + if (sink == nullptr) { return len; } char scratch[LENGTH]; int32_t capacity = 0; @@ -1294,27 +1283,21 @@ _getScript(const char* localeID, } sink->Append(buffer, LENGTH); + return len; } -void -_getRegion(const char* localeID, - ByteSink* sink, - const char** pEnd) { - U_ASSERT(pEnd != nullptr); - *pEnd = localeID; - +size_t _getRegion(std::string_view localeID, ByteSink* sink) { constexpr int32_t MINLEN = 2; constexpr int32_t MAXLEN = ULOC_COUNTRY_CAPACITY - 1; // Minus NUL. - int32_t len = 0; - while (!_isTerminator(localeID[len]) && !_isIDSeparator(localeID[len])) { - if (len == MAXLEN) { return; } + size_t len = 0; + while (len < localeID.size() && !_isTerminator(localeID[len]) && !_isIDSeparator(localeID[len])) { + if (len == MAXLEN) { return 0; } len++; } - if (len < MINLEN) { return; } + if (len < MINLEN) { return 0; } - *pEnd = localeID + len; - if (sink == nullptr) { return; } + if (sink == nullptr) { return len; } char scratch[ULOC_COUNTRY_CAPACITY]; int32_t capacity = 0; @@ -1325,7 +1308,7 @@ _getRegion(const char* localeID, UPRV_LENGTHOF(scratch), &capacity); - for (int32_t i = 0; i < len; ++i) { + for (size_t i = 0; i < len; ++i) { buffer[i] = uprv_toupper(localeID[i]); } @@ -1337,26 +1320,25 @@ _getRegion(const char* localeID, if (offset.has_value()) { const char* const alias = COUNTRIES[*offset]; sink->Append(alias, static_cast(uprv_strlen(alias))); - return; + return len; } } - sink->Append(buffer, len); + sink->Append(buffer, static_cast(len)); + return len; } /** * @param needSeparator if true, then add leading '_' if any variants * are added to 'variant' */ -void -_getVariant(const char* localeID, +size_t +_getVariant(std::string_view localeID, char prev, ByteSink* sink, - const char** pEnd, bool needSeparator, UErrorCode& status) { - if (U_FAILURE(status)) return; - if (pEnd != nullptr) { *pEnd = localeID; } + if (U_FAILURE(status) || localeID.empty()) return 0; // Reasonable upper limit for variants // There are no strict limitation of the syntax of variant in the legacy @@ -1369,63 +1351,82 @@ _getVariant(const char* localeID, constexpr int32_t MAX_VARIANTS_LENGTH = 179; /* get one or more variant tags and separate them with '_' */ - int32_t index = 0; + size_t index = 0; if (_isIDSeparator(prev)) { /* get a variant string after a '-' or '_' */ - for (index=0; !_isTerminator(localeID[index]); index++) { - if (index >= MAX_VARIANTS_LENGTH) { // same as length > MAX_VARIANTS_LENGTH + for (std::string_view sub = localeID;;) { + size_t next = sub.find_first_of(".@_-"); + // For historical reasons, a trailing separator is included in the variant. + bool finished = next == std::string_view::npos || next + 1 == sub.length(); + size_t limit = finished ? sub.length() : next; + index += limit; + if (index > MAX_VARIANTS_LENGTH) { status = U_ILLEGAL_ARGUMENT_ERROR; - return; + return 0; } - if (needSeparator) { - if (sink != nullptr) { + + if (sink != nullptr) { + if (needSeparator) { sink->Append("_", 1); + } else { + needSeparator = true; } - needSeparator = false; - } - if (sink != nullptr) { - char c = uprv_toupper(localeID[index]); - if (c == '-') c = '_'; - sink->Append(&c, 1); + + int32_t length = static_cast(limit); + int32_t minCapacity = uprv_min(length, MAX_VARIANTS_LENGTH); + char scratch[MAX_VARIANTS_LENGTH]; + int32_t capacity = 0; + char* buffer = sink->GetAppendBuffer( + minCapacity, minCapacity, scratch, UPRV_LENGTHOF(scratch), &capacity); + + for (size_t i = 0; i < limit; ++i) { + buffer[i] = uprv_toupper(sub[i]); + } + sink->Append(buffer, length); } + + if (finished) { return index; } + sub.remove_prefix(next); + if (_isTerminator(sub.front()) || _isBCP47Extension(sub)) { return index; } + sub.remove_prefix(1); + index++; } - if (pEnd != nullptr) { *pEnd = localeID+index; } } + size_t skip = 0; /* if there is no variant tag after a '-' or '_' then look for '@' */ - if (index == 0) { - if (prev=='@') { - /* keep localeID */ - } else if((localeID=locale_getKeywordsStart(localeID))!=nullptr) { - ++localeID; /* point after the '@' */ - } else { - return; + if (prev == '@') { + /* keep localeID */ + } else if (const char* p = locale_getKeywordsStart(localeID); p != nullptr) { + skip = 1 + p - localeID.data(); /* point after the '@' */ + localeID.remove_prefix(skip); + } else { + return 0; + } + for (; index < localeID.size() && !_isTerminator(localeID[index]); index++) { + if (index >= MAX_VARIANTS_LENGTH) { // same as length > MAX_VARIANTS_LENGTH + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; } - for(; !_isTerminator(localeID[index]); index++) { - if (index >= MAX_VARIANTS_LENGTH) { // same as length > MAX_VARIANTS_LENGTH - status = U_ILLEGAL_ARGUMENT_ERROR; - return; - } - if (needSeparator) { - if (sink != nullptr) { - sink->Append("_", 1); - } - needSeparator = false; - } + if (needSeparator) { if (sink != nullptr) { - char c = uprv_toupper(localeID[index]); - if (c == '-' || c == ',') c = '_'; - sink->Append(&c, 1); + sink->Append("_", 1); } + needSeparator = false; + } + if (sink != nullptr) { + char c = uprv_toupper(localeID[index]); + if (c == '-' || c == ',') c = '_'; + sink->Append(&c, 1); } - if (pEnd != nullptr) { *pEnd = localeID + index; } } + return skip + index; } } // namespace U_EXPORT CharString -ulocimp_getLanguage(const char* localeID, UErrorCode& status) { +ulocimp_getLanguage(std::string_view localeID, UErrorCode& status) { return ByteSinkUtil::viaByteSinkToCharString( [&](ByteSink& sink, UErrorCode& status) { ulocimp_getSubtags( @@ -1441,7 +1442,7 @@ ulocimp_getLanguage(const char* localeID, UErrorCode& status) { } U_EXPORT CharString -ulocimp_getScript(const char* localeID, UErrorCode& status) { +ulocimp_getScript(std::string_view localeID, UErrorCode& status) { return ByteSinkUtil::viaByteSinkToCharString( [&](ByteSink& sink, UErrorCode& status) { ulocimp_getSubtags( @@ -1457,7 +1458,7 @@ ulocimp_getScript(const char* localeID, UErrorCode& status) { } U_EXPORT CharString -ulocimp_getRegion(const char* localeID, UErrorCode& status) { +ulocimp_getRegion(std::string_view localeID, UErrorCode& status) { return ByteSinkUtil::viaByteSinkToCharString( [&](ByteSink& sink, UErrorCode& status) { ulocimp_getSubtags( @@ -1473,7 +1474,7 @@ ulocimp_getRegion(const char* localeID, UErrorCode& status) { } U_EXPORT CharString -ulocimp_getVariant(const char* localeID, UErrorCode& status) { +ulocimp_getVariant(std::string_view localeID, UErrorCode& status) { return ByteSinkUtil::viaByteSinkToCharString( [&](ByteSink& sink, UErrorCode& status) { ulocimp_getSubtags( @@ -1490,7 +1491,7 @@ ulocimp_getVariant(const char* localeID, UErrorCode& status) { U_EXPORT void ulocimp_getSubtags( - const char* localeID, + std::string_view localeID, CharString* language, CharString* script, CharString* region, @@ -1521,7 +1522,7 @@ ulocimp_getSubtags( U_EXPORT void ulocimp_getSubtags( - const char* localeID, + std::string_view localeID, ByteSink* language, ByteSink* script, ByteSink* region, @@ -1531,7 +1532,7 @@ ulocimp_getSubtags( if (U_FAILURE(status)) { return; } if (pEnd != nullptr) { - *pEnd = localeID; + *pEnd = localeID.data(); } else if (language == nullptr && script == nullptr && region == nullptr && @@ -1539,62 +1540,94 @@ ulocimp_getSubtags( return; } + if (localeID.empty()) { return; } + bool hasRegion = false; - if (localeID == nullptr) { - localeID = uloc_getDefault(); + { + size_t len = _getLanguage(localeID, language, status); + if (U_FAILURE(status)) { return; } + if (len > 0) { + localeID.remove_prefix(len); + } } - _getLanguage(localeID, language, &localeID, status); - if (U_FAILURE(status)) { return; } - U_ASSERT(localeID != nullptr); - if (pEnd != nullptr) { - *pEnd = localeID; + *pEnd = localeID.data(); } else if (script == nullptr && region == nullptr && variant == nullptr) { return; } - if (_isIDSeparator(*localeID)) { - const char* begin = localeID + 1; - const char* end = nullptr; - _getScript(begin, script, &end); - U_ASSERT(end != nullptr); - if (end != begin) { - localeID = end; - if (pEnd != nullptr) { *pEnd = localeID; } + if (localeID.empty()) { return; } + + if (_isIDSeparator(localeID.front())) { + std::string_view sub = localeID; + sub.remove_prefix(1); + size_t len = _getScript(sub, script); + if (len > 0) { + localeID.remove_prefix(len + 1); + if (pEnd != nullptr) { *pEnd = localeID.data(); } } } - if (region == nullptr && variant == nullptr && pEnd == nullptr) { return; } + if ((region == nullptr && variant == nullptr && pEnd == nullptr) || localeID.empty()) { return; } - if (_isIDSeparator(*localeID)) { - const char* begin = localeID + 1; - const char* end = nullptr; - _getRegion(begin, region, &end); - U_ASSERT(end != nullptr); - if (end != begin) { + if (_isIDSeparator(localeID.front())) { + std::string_view sub = localeID; + sub.remove_prefix(1); + size_t len = _getRegion(sub, region); + if (len > 0) { hasRegion = true; - localeID = end; - if (pEnd != nullptr) { *pEnd = localeID; } + localeID.remove_prefix(len + 1); + if (pEnd != nullptr) { *pEnd = localeID.data(); } } } - if (variant == nullptr && pEnd == nullptr) { return; } + if ((variant == nullptr && pEnd == nullptr) || localeID.empty()) { return; } - if (_isIDSeparator(*localeID) && !_isBCP47Extension(localeID)) { + bool hasVariant = false; + + if (_isIDSeparator(localeID.front()) && !_isBCP47Extension(localeID)) { + std::string_view sub = localeID; /* If there was no country ID, skip a possible extra IDSeparator */ - if (!hasRegion && _isIDSeparator(localeID[1])) { - localeID++; - } - const char* begin = localeID + 1; - const char* end = nullptr; - _getVariant(begin, *localeID, variant, &end, false, status); + size_t skip = !hasRegion && localeID.size() > 1 && _isIDSeparator(localeID[1]) ? 2 : 1; + sub.remove_prefix(skip); + size_t len = _getVariant(sub, localeID[0], variant, false, status); if (U_FAILURE(status)) { return; } - U_ASSERT(end != nullptr); - if (end != begin && pEnd != nullptr) { *pEnd = end; } + if (len > 0) { + hasVariant = true; + localeID.remove_prefix(skip + len); + if (pEnd != nullptr) { *pEnd = localeID.data(); } + } + } + + if ((variant == nullptr && pEnd == nullptr) || localeID.empty()) { return; } + + if (_isBCP47Extension(localeID)) { + localeID.remove_prefix(2); + constexpr char vaposix[] = "-va-posix"; + constexpr size_t length = sizeof vaposix - 1; + for (size_t next;; localeID.remove_prefix(next)) { + next = localeID.find('-', 1); + if (next == std::string_view::npos) { break; } + next = localeID.find('-', next + 1); + bool finished = next == std::string_view::npos; + std::string_view sub = localeID; + if (!finished) { sub.remove_suffix(sub.length() - next); } + + if (sub.length() == length && uprv_strnicmp(sub.data(), vaposix, length) == 0) { + if (variant != nullptr) { + if (hasVariant) { variant->Append("_", 1); } + constexpr char posix[] = "POSIX"; + variant->Append(posix, sizeof posix - 1); + } + if (pEnd != nullptr) { *pEnd = localeID.data() + length; } + } + + if (finished) { break; } + } } } @@ -1700,7 +1733,7 @@ uloc_openKeywords(const char* localeID, CharString tempBuffer; const char* tmpLocaleID; - if (_hasBCP47Extension(localeID)) { + if (localeID != nullptr && _hasBCP47Extension(localeID)) { tempBuffer = ulocimp_forLanguageTag(localeID, -1, nullptr, *status); tmpLocaleID = U_SUCCESS(*status) && !tempBuffer.isEmpty() ? tempBuffer.data() : localeID; } else { @@ -1753,7 +1786,7 @@ constexpr int32_t I_DEFAULT_LENGTH = UPRV_LENGTHOF(i_default); * This is the code underlying uloc_getName and uloc_canonicalize. */ void -_canonicalize(const char* localeID, +_canonicalize(std::string_view localeID, ByteSink& sink, uint32_t options, UErrorCode& err) { @@ -1764,33 +1797,30 @@ _canonicalize(const char* localeID, int32_t j, fieldCount=0; CharString tempBuffer; // if localeID has a BCP47 extension, tmpLocaleID points to this CharString localeIDWithHyphens; // if localeID has a BPC47 extension and have _, tmpLocaleID points to this - const char* origLocaleID; - const char* tmpLocaleID; - const char* keywordAssign = nullptr; - const char* separatorIndicator = nullptr; + std::string_view origLocaleID; + std::string_view tmpLocaleID; + size_t keywordAssign = std::string_view::npos; + size_t separatorIndicator = std::string_view::npos; if (_hasBCP47Extension(localeID)) { - const char* localeIDPtr = localeID; + std::string_view localeIDPtr = localeID; // convert all underbars to hyphens, unless the "BCP47 extension" comes at the beginning of the string - if (uprv_strchr(localeID, '_') != nullptr && localeID[1] != '-' && localeID[1] != '_') { - localeIDWithHyphens.append(localeID, -1, err); + if (localeID.size() >= 2 && localeID.find('_') != std::string_view::npos && localeID[1] != '-' && localeID[1] != '_') { + localeIDWithHyphens.append(localeID, err); if (U_SUCCESS(err)) { for (char* p = localeIDWithHyphens.data(); *p != '\0'; ++p) { if (*p == '_') { *p = '-'; } } - localeIDPtr = localeIDWithHyphens.data(); + localeIDPtr = localeIDWithHyphens.toStringPiece(); } } - tempBuffer = ulocimp_forLanguageTag(localeIDPtr, -1, nullptr, err); - tmpLocaleID = U_SUCCESS(err) && !tempBuffer.isEmpty() ? tempBuffer.data() : localeIDPtr; + tempBuffer = ulocimp_forLanguageTag(localeIDPtr.data(), static_cast(localeIDPtr.size()), nullptr, err); + tmpLocaleID = U_SUCCESS(err) && !tempBuffer.isEmpty() ? static_cast(tempBuffer.toStringPiece()) : localeIDPtr; } else { - if (localeID==nullptr) { - localeID=uloc_getDefault(); - } tmpLocaleID=localeID; } @@ -1801,20 +1831,25 @@ _canonicalize(const char* localeID, CharString script; CharString country; CharString variant; + const char* end = nullptr; ulocimp_getSubtags( tmpLocaleID, &tag, &script, &country, &variant, - &tmpLocaleID, + &end, err); if (U_FAILURE(err)) { return; } + U_ASSERT(end != nullptr); + if (end > tmpLocaleID.data()) { + tmpLocaleID.remove_prefix(end - tmpLocaleID.data()); + } - if (tag.length() == I_DEFAULT_LENGTH && - uprv_strncmp(origLocaleID, i_default, I_DEFAULT_LENGTH) == 0) { + if (tag.length() == I_DEFAULT_LENGTH && origLocaleID.length() >= I_DEFAULT_LENGTH && + uprv_strncmp(origLocaleID.data(), i_default, I_DEFAULT_LENGTH) == 0) { tag.clear(); tag.append(uloc_getDefault(), err); } else { @@ -1839,15 +1874,14 @@ _canonicalize(const char* localeID, } /* Copy POSIX-style charset specifier, if any [mr.utf8] */ - if (!OPTION_SET(options, _ULOC_CANONICALIZE) && *tmpLocaleID == '.') { + if (!OPTION_SET(options, _ULOC_CANONICALIZE) && !tmpLocaleID.empty() && tmpLocaleID.front() == '.') { tag.append('.', err); - ++tmpLocaleID; - const char *atPos = nullptr; + tmpLocaleID.remove_prefix(1); size_t length; - if((atPos = uprv_strchr(tmpLocaleID, '@')) != nullptr) { - length = atPos - tmpLocaleID; + if (size_t atPos = tmpLocaleID.find('@'); atPos != std::string_view::npos) { + length = atPos; } else { - length = uprv_strlen(tmpLocaleID); + length = tmpLocaleID.length(); } // The longest charset name we found in IANA charset registry // https://www.iana.org/assignments/character-sets/ is @@ -1859,33 +1893,34 @@ _canonicalize(const char* localeID, err = U_ILLEGAL_ARGUMENT_ERROR; /* malformed keyword name */ return; } - tag.append(tmpLocaleID, static_cast(length), err); - tmpLocaleID += length; + if (length > 0) { + tag.append(tmpLocaleID.data(), static_cast(length), err); + tmpLocaleID.remove_prefix(length); + } } /* Scan ahead to next '@' and determine if it is followed by '=' and/or ';' - After this, tmpLocaleID either points to '@' or is nullptr */ - if ((tmpLocaleID=locale_getKeywordsStart(tmpLocaleID))!=nullptr) { - keywordAssign = uprv_strchr(tmpLocaleID, '='); - separatorIndicator = uprv_strchr(tmpLocaleID, ';'); + After this, tmpLocaleID either starts at '@' or is empty. */ + if (const char* start = locale_getKeywordsStart(tmpLocaleID); start != nullptr) { + if (start > tmpLocaleID.data()) { + tmpLocaleID.remove_prefix(start - tmpLocaleID.data()); + } + keywordAssign = tmpLocaleID.find('='); + separatorIndicator = tmpLocaleID.find(';'); + } else { + tmpLocaleID = {}; } /* Copy POSIX-style variant, if any [mr@FOO] */ if (!OPTION_SET(options, _ULOC_CANONICALIZE) && - tmpLocaleID != nullptr && keywordAssign == nullptr) { - for (;;) { - char c = *tmpLocaleID; - if (c == 0) { - break; - } - tag.append(c, err); - ++tmpLocaleID; - } + !tmpLocaleID.empty() && keywordAssign == std::string_view::npos) { + tag.append(tmpLocaleID, err); + tmpLocaleID = {}; } if (OPTION_SET(options, _ULOC_CANONICALIZE)) { /* Handle @FOO variant if @ is present and not followed by = */ - if (tmpLocaleID!=nullptr && keywordAssign==nullptr) { + if (!tmpLocaleID.empty() && keywordAssign == std::string_view::npos) { /* Add missing '_' if needed */ if (fieldCount < 2 || (fieldCount < 3 && !script.isEmpty())) { do { @@ -1895,7 +1930,9 @@ _canonicalize(const char* localeID, } CharStringByteSink s(&tag); - _getVariant(tmpLocaleID+1, '@', &s, nullptr, !variant.isEmpty(), err); + std::string_view sub = tmpLocaleID; + sub.remove_prefix(1); + _getVariant(sub, '@', &s, !variant.isEmpty(), err); if (U_FAILURE(err)) { return; } } @@ -1903,7 +1940,7 @@ _canonicalize(const char* localeID, for (j=0; j keywordAssign)) { + if (!tmpLocaleID.empty() && keywordAssign != std::string_view::npos && + (separatorIndicator == std::string_view::npos || separatorIndicator > keywordAssign)) { sink.Append("@", 1); ++fieldCount; - ulocimp_getKeywords(tmpLocaleID+1, '@', sink, true, err); + tmpLocaleID.remove_prefix(1); + ulocimp_getKeywords(tmpLocaleID, '@', sink, true, err); } } } @@ -1989,6 +2027,10 @@ uloc_getLanguage(const char* localeID, int32_t languageCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } + /* uloc_getLanguage will return a 2 character iso-639 code if one exists. *CWB*/ return ByteSinkUtil::viaByteSinkToTerminatedChars( language, languageCapacity, @@ -2011,6 +2053,10 @@ uloc_getScript(const char* localeID, int32_t scriptCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } + return ByteSinkUtil::viaByteSinkToTerminatedChars( script, scriptCapacity, [&](ByteSink& sink, UErrorCode& status) { @@ -2032,6 +2078,10 @@ uloc_getCountry(const char* localeID, int32_t countryCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } + return ByteSinkUtil::viaByteSinkToTerminatedChars( country, countryCapacity, [&](ByteSink& sink, UErrorCode& status) { @@ -2053,6 +2103,10 @@ uloc_getVariant(const char* localeID, int32_t variantCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } + return ByteSinkUtil::viaByteSinkToTerminatedChars( variant, variantCapacity, [&](ByteSink& sink, UErrorCode& status) { @@ -2074,6 +2128,9 @@ uloc_getName(const char* localeID, int32_t nameCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } return ByteSinkUtil::viaByteSinkToTerminatedChars( name, nameCapacity, [&](ByteSink& sink, UErrorCode& status) { @@ -2083,7 +2140,7 @@ uloc_getName(const char* localeID, } U_EXPORT CharString -ulocimp_getName(const char* localeID, +ulocimp_getName(std::string_view localeID, UErrorCode& err) { return ByteSinkUtil::viaByteSinkToCharString( @@ -2094,7 +2151,7 @@ ulocimp_getName(const char* localeID, } U_EXPORT void -ulocimp_getName(const char* localeID, +ulocimp_getName(std::string_view localeID, ByteSink& sink, UErrorCode& err) { @@ -2107,6 +2164,9 @@ uloc_getBaseName(const char* localeID, int32_t nameCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } return ByteSinkUtil::viaByteSinkToTerminatedChars( name, nameCapacity, [&](ByteSink& sink, UErrorCode& status) { @@ -2116,7 +2176,7 @@ uloc_getBaseName(const char* localeID, } U_EXPORT CharString -ulocimp_getBaseName(const char* localeID, +ulocimp_getBaseName(std::string_view localeID, UErrorCode& err) { return ByteSinkUtil::viaByteSinkToCharString( @@ -2127,7 +2187,7 @@ ulocimp_getBaseName(const char* localeID, } U_EXPORT void -ulocimp_getBaseName(const char* localeID, +ulocimp_getBaseName(std::string_view localeID, ByteSink& sink, UErrorCode& err) { @@ -2140,6 +2200,9 @@ uloc_canonicalize(const char* localeID, int32_t nameCapacity, UErrorCode* err) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } return ByteSinkUtil::viaByteSinkToTerminatedChars( name, nameCapacity, [&](ByteSink& sink, UErrorCode& status) { @@ -2149,7 +2212,7 @@ uloc_canonicalize(const char* localeID, } U_EXPORT CharString -ulocimp_canonicalize(const char* localeID, +ulocimp_canonicalize(std::string_view localeID, UErrorCode& err) { return ByteSinkUtil::viaByteSinkToCharString( @@ -2160,7 +2223,7 @@ ulocimp_canonicalize(const char* localeID, } U_EXPORT void -ulocimp_canonicalize(const char* localeID, +ulocimp_canonicalize(std::string_view localeID, ByteSink& sink, UErrorCode& err) { diff --git a/contrib/libs/icu/common/uloc_tag.cpp b/contrib/libs/icu/common/uloc_tag.cpp index 7b3b1e73a37c..b2e9946f48a7 100644 --- a/contrib/libs/icu/common/uloc_tag.cpp +++ b/contrib/libs/icu/common/uloc_tag.cpp @@ -1043,7 +1043,7 @@ _initializeULanguageTag(ULanguageTag* langtag) { } void -_appendLanguageToLanguageTag(const char* localeID, icu::ByteSink& sink, bool strict, UErrorCode& status) { +_appendLanguageToLanguageTag(std::string_view localeID, icu::ByteSink& sink, bool strict, UErrorCode& status) { UErrorCode tmpStatus = U_ZERO_ERROR; if (U_FAILURE(status)) { @@ -1088,7 +1088,7 @@ _appendLanguageToLanguageTag(const char* localeID, icu::ByteSink& sink, bool str } void -_appendScriptToLanguageTag(const char* localeID, icu::ByteSink& sink, bool strict, UErrorCode& status) { +_appendScriptToLanguageTag(std::string_view localeID, icu::ByteSink& sink, bool strict, UErrorCode& status) { UErrorCode tmpStatus = U_ZERO_ERROR; if (U_FAILURE(status)) { @@ -1118,7 +1118,7 @@ _appendScriptToLanguageTag(const char* localeID, icu::ByteSink& sink, bool stric } void -_appendRegionToLanguageTag(const char* localeID, icu::ByteSink& sink, bool strict, UErrorCode& status) { +_appendRegionToLanguageTag(std::string_view localeID, icu::ByteSink& sink, bool strict, UErrorCode& status) { UErrorCode tmpStatus = U_ZERO_ERROR; if (U_FAILURE(status)) { @@ -1169,7 +1169,7 @@ void _sortVariants(VariantListEntry* first) { } void -_appendVariantsToLanguageTag(const char* localeID, icu::ByteSink& sink, bool strict, bool& hadPosix, UErrorCode& status) { +_appendVariantsToLanguageTag(std::string_view localeID, icu::ByteSink& sink, bool strict, bool& hadPosix, UErrorCode& status) { if (U_FAILURE(status)) { return; } UErrorCode tmpStatus = U_ZERO_ERROR; @@ -1872,7 +1872,7 @@ _appendKeywords(ULanguageTag* langtag, icu::ByteSink& sink, UErrorCode& status) } void -_appendPrivateuseToLanguageTag(const char* localeID, icu::ByteSink& sink, bool strict, bool /*hadPosix*/, UErrorCode& status) { +_appendPrivateuseToLanguageTag(std::string_view localeID, icu::ByteSink& sink, bool strict, bool /*hadPosix*/, UErrorCode& status) { if (U_FAILURE(status)) { return; } UErrorCode tmpStatus = U_ZERO_ERROR; @@ -2596,6 +2596,9 @@ ulocimp_toLanguageTag(const char* localeID, bool hadPosix = false; const char* pKeywordStart; + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } /* Note: uloc_canonicalize returns "en_US_POSIX" for input locale ID "". See #6835 */ icu::CharString canonical = ulocimp_canonicalize(localeID, tmpStatus); if (U_FAILURE(tmpStatus)) { @@ -2604,7 +2607,7 @@ ulocimp_toLanguageTag(const char* localeID, } /* For handling special case - private use only tag */ - pKeywordStart = locale_getKeywordsStart(canonical.data()); + pKeywordStart = locale_getKeywordsStart(canonical.toStringPiece()); if (pKeywordStart == canonical.data()) { int kwdCnt = 0; bool done = false; @@ -2642,12 +2645,12 @@ ulocimp_toLanguageTag(const char* localeID, } } - _appendLanguageToLanguageTag(canonical.data(), sink, strict, status); - _appendScriptToLanguageTag(canonical.data(), sink, strict, status); - _appendRegionToLanguageTag(canonical.data(), sink, strict, status); - _appendVariantsToLanguageTag(canonical.data(), sink, strict, hadPosix, status); + _appendLanguageToLanguageTag(canonical.toStringPiece(), sink, strict, status); + _appendScriptToLanguageTag(canonical.toStringPiece(), sink, strict, status); + _appendRegionToLanguageTag(canonical.toStringPiece(), sink, strict, status); + _appendVariantsToLanguageTag(canonical.toStringPiece(), sink, strict, hadPosix, status); _appendKeywordsToLanguageTag(canonical.data(), sink, strict, hadPosix, status); - _appendPrivateuseToLanguageTag(canonical.data(), sink, strict, hadPosix, status); + _appendPrivateuseToLanguageTag(canonical.toStringPiece(), sink, strict, hadPosix, status); } diff --git a/contrib/libs/icu/common/ulocale.cpp b/contrib/libs/icu/common/ulocale.cpp index f2f81bc97109..33814713dc1b 100644 --- a/contrib/libs/icu/common/ulocale.cpp +++ b/contrib/libs/icu/common/ulocale.cpp @@ -10,7 +10,6 @@ #include "unicode/locid.h" #include "bytesinkutil.h" -#include "charstr.h" #include "cmemory.h" U_NAMESPACE_USE @@ -24,9 +23,7 @@ ulocale_openForLocaleID(const char* localeID, int32_t length, UErrorCode* err) { if (length < 0) { return EXTERNAL(icu::Locale::createFromName(localeID).clone()); } - CharString str(localeID, length, *err); // Make a NUL terminated copy. - if (U_FAILURE(*err)) { return nullptr; } - return EXTERNAL(icu::Locale::createFromName(str.data()).clone()); + return EXTERNAL(icu::Locale::createFromName(StringPiece{localeID, length}).clone()); } ULocale* diff --git a/contrib/libs/icu/common/ulocimp.h b/contrib/libs/icu/common/ulocimp.h index 1887e2a849ab..7f09748c8ac1 100644 --- a/contrib/libs/icu/common/ulocimp.h +++ b/contrib/libs/icu/common/ulocimp.h @@ -68,42 +68,42 @@ U_EXPORT std::optional ulocimp_toLegacyTypeWithFallback(std::string_view keyword, std::string_view value); U_EXPORT icu::CharString -ulocimp_getKeywords(const char* localeID, +ulocimp_getKeywords(std::string_view localeID, char prev, bool valuesToo, UErrorCode& status); U_EXPORT void -ulocimp_getKeywords(const char* localeID, +ulocimp_getKeywords(std::string_view localeID, char prev, icu::ByteSink& sink, bool valuesToo, UErrorCode& status); U_EXPORT icu::CharString -ulocimp_getName(const char* localeID, +ulocimp_getName(std::string_view localeID, UErrorCode& err); U_EXPORT void -ulocimp_getName(const char* localeID, +ulocimp_getName(std::string_view localeID, icu::ByteSink& sink, UErrorCode& err); U_EXPORT icu::CharString -ulocimp_getBaseName(const char* localeID, +ulocimp_getBaseName(std::string_view localeID, UErrorCode& err); U_EXPORT void -ulocimp_getBaseName(const char* localeID, +ulocimp_getBaseName(std::string_view localeID, icu::ByteSink& sink, UErrorCode& err); U_EXPORT icu::CharString -ulocimp_canonicalize(const char* localeID, +ulocimp_canonicalize(std::string_view localeID, UErrorCode& err); U_EXPORT void -ulocimp_canonicalize(const char* localeID, +ulocimp_canonicalize(std::string_view localeID, icu::ByteSink& sink, UErrorCode& err); @@ -119,16 +119,16 @@ ulocimp_getKeywordValue(const char* localeID, UErrorCode& status); U_EXPORT icu::CharString -ulocimp_getLanguage(const char* localeID, UErrorCode& status); +ulocimp_getLanguage(std::string_view localeID, UErrorCode& status); U_EXPORT icu::CharString -ulocimp_getScript(const char* localeID, UErrorCode& status); +ulocimp_getScript(std::string_view localeID, UErrorCode& status); U_EXPORT icu::CharString -ulocimp_getRegion(const char* localeID, UErrorCode& status); +ulocimp_getRegion(std::string_view localeID, UErrorCode& status); U_EXPORT icu::CharString -ulocimp_getVariant(const char* localeID, UErrorCode& status); +ulocimp_getVariant(std::string_view localeID, UErrorCode& status); U_EXPORT void ulocimp_setKeywordValue(std::string_view keywordName, @@ -145,7 +145,7 @@ ulocimp_setKeywordValue(std::string_view keywords, U_EXPORT void ulocimp_getSubtags( - const char* localeID, + std::string_view localeID, icu::CharString* language, icu::CharString* script, icu::CharString* region, @@ -155,7 +155,7 @@ ulocimp_getSubtags( U_EXPORT void ulocimp_getSubtags( - const char* localeID, + std::string_view localeID, icu::ByteSink* language, icu::ByteSink* script, icu::ByteSink* region, @@ -165,7 +165,7 @@ ulocimp_getSubtags( inline void ulocimp_getSubtags( - const char* localeID, + std::string_view localeID, std::nullptr_t, std::nullptr_t, std::nullptr_t, @@ -364,7 +364,7 @@ ulocimp_minimizeSubtags(const char* localeID, UErrorCode& err); U_CAPI const char * U_EXPORT2 -locale_getKeywordsStart(const char *localeID); +locale_getKeywordsStart(std::string_view localeID); bool ultag_isExtensionSubtags(const char* s, int32_t len); diff --git a/contrib/libs/icu/common/umapfile.cpp b/contrib/libs/icu/common/umapfile.cpp index b58ac37f4d45..3ba0251df9c5 100644 --- a/contrib/libs/icu/common/umapfile.cpp +++ b/contrib/libs/icu/common/umapfile.cpp @@ -237,8 +237,13 @@ typedef HANDLE MemoryMap; pData->map = (char *)data + length; pData->pHeader=(const DataHeader *)data; pData->mapAddr = data; -#if U_PLATFORM == U_PF_IPHONE +#if U_PLATFORM == U_PF_IPHONE || U_PLATFORM == U_PF_ANDROID + // Apparently supported from Android 23 and higher: + // https://github.com/ggml-org/llama.cpp/pull/3631 + // Checking for the flag itself is safer than checking for __ANDROID_API__. +# ifdef POSIX_MADV_RANDOM posix_madvise(data, length, POSIX_MADV_RANDOM); +# endif #endif return true; } diff --git a/contrib/libs/icu/common/unistr.cpp b/contrib/libs/icu/common/unistr.cpp index a720245772e6..4e29bad1d3b9 100644 --- a/contrib/libs/icu/common/unistr.cpp +++ b/contrib/libs/icu/common/unistr.cpp @@ -1945,6 +1945,13 @@ UnicodeString::cloneArrayIfNeeded(int32_t newCapacity, growCapacity = newCapacity; } else if(newCapacity <= US_STACKBUF_SIZE && growCapacity > US_STACKBUF_SIZE) { growCapacity = US_STACKBUF_SIZE; + } else if(newCapacity > growCapacity) { + setToBogus(); + return false; // bad inputs + } + if(growCapacity > kMaxCapacity) { + setToBogus(); + return false; } // save old values diff --git a/contrib/libs/icu/common/uresbund.cpp b/contrib/libs/icu/common/uresbund.cpp index 3a09cbf3bcaa..afda2770fd3f 100644 --- a/contrib/libs/icu/common/uresbund.cpp +++ b/contrib/libs/icu/common/uresbund.cpp @@ -2716,6 +2716,9 @@ ures_openWithType(UResourceBundle *r, const char* path, const char* localeID, UResourceDataEntry *entry; if(openType != URES_OPEN_DIRECT) { + if (localeID == nullptr) { + localeID = uloc_getDefault(); + } /* first "canonicalize" the locale ID */ CharString canonLocaleID = ulocimp_getBaseName(localeID, *status); if(U_FAILURE(*status)) { @@ -3080,6 +3083,9 @@ ures_getFunctionalEquivalent(char *result, int32_t resultCapacity, kwVal.clear(); } } + if (locid == nullptr) { + locid = uloc_getDefault(); + } CharString base = ulocimp_getBaseName(locid, subStatus); #if defined(URES_TREE_DEBUG) fprintf(stderr, "getFunctionalEquivalent: \"%s\" [%s=%s] in %s - %s\n", @@ -3244,7 +3250,7 @@ ures_getFunctionalEquivalent(char *result, int32_t resultCapacity, const char *validLoc = ures_getLocaleByType(res, ULOC_VALID_LOCALE, &subStatus); if (U_SUCCESS(subStatus) && validLoc != nullptr && validLoc[0] != 0 && uprv_strcmp(validLoc, "root") != 0) { CharString validLang = ulocimp_getLanguage(validLoc, subStatus); - CharString parentLang = ulocimp_getLanguage(parent.data(), subStatus); + CharString parentLang = ulocimp_getLanguage(parent.toStringPiece(), subStatus); if (U_SUCCESS(subStatus) && validLang != parentLang) { // validLoc is not root and has a different language than parent, use it instead found.clear().append(validLoc, subStatus); diff --git a/contrib/libs/icu/common/uscript.cpp b/contrib/libs/icu/common/uscript.cpp index c48a28fd1434..ce40d354958f 100644 --- a/contrib/libs/icu/common/uscript.cpp +++ b/contrib/libs/icu/common/uscript.cpp @@ -59,6 +59,9 @@ getCodesFromLocale(const char *locale, if (U_FAILURE(*err)) { return 0; } icu::CharString lang; icu::CharString script; + if (locale == nullptr) { + locale = uloc_getDefault(); + } ulocimp_getSubtags(locale, &lang, &script, nullptr, nullptr, nullptr, *err); if (U_FAILURE(*err)) { return 0; } // Multi-script languages, equivalent to the LocaleScript data diff --git a/contrib/libs/icu/common/ushape.cpp b/contrib/libs/icu/common/ushape.cpp index 00125635cb26..b7946dc3ce03 100644 --- a/contrib/libs/icu/common/ushape.cpp +++ b/contrib/libs/icu/common/ushape.cpp @@ -28,6 +28,7 @@ #include "ubidi_props.h" #include "uassert.h" +#include /* * This implementation is designed for 16-bit Unicode strings. * The main assumption is that the Arabic characters and their @@ -747,6 +748,10 @@ handleGeneratedSpaces(char16_t *dest, int32_t sourceLength, } } + if (static_cast(sourceLength) + 1 > std::numeric_limits::max() / U_SIZEOF_UCHAR) { + *pErrorCode = U_INDEX_OUTOFBOUNDS_ERROR; + return 0; + } tempbuffer = static_cast(uprv_malloc((sourceLength + 1) * U_SIZEOF_UCHAR)); /* Test for nullptr */ if(tempbuffer == nullptr) { diff --git a/contrib/libs/icu/common/usprep.cpp b/contrib/libs/icu/common/usprep.cpp index 477b8f2309db..048b423645f8 100644 --- a/contrib/libs/icu/common/usprep.cpp +++ b/contrib/libs/icu/common/usprep.cpp @@ -126,7 +126,7 @@ compareEntries(const UHashTok p1, const UHashTok p2) { name2.pointer = b2->name; path1.pointer = b1->path; path2.pointer = b2->path; - return uhash_compareChars(name1, name2) & uhash_compareChars(path1, path2); + return uhash_compareChars(name1, name2) && uhash_compareChars(path1, path2); } static void diff --git a/contrib/libs/icu/common/utf_impl.cpp b/contrib/libs/icu/common/utf_impl.cpp index 827a82daf403..7da10c9b2d36 100644 --- a/contrib/libs/icu/common/utf_impl.cpp +++ b/contrib/libs/icu/common/utf_impl.cpp @@ -124,11 +124,9 @@ errorValue(int32_t count, int8_t strict) { * >0 Obsolete "strict" behavior of UTF8_NEXT_CHAR_SAFE(..., true): * Same as the obsolete "safe" behavior, but non-characters are also treated * like illegal sequences. - * - * Note that a UBool is the same as an int8_t. */ U_CAPI UChar32 U_EXPORT2 -utf8_nextCharSafeBody(const uint8_t *s, int32_t *pi, int32_t length, UChar32 c, UBool strict) { +utf8_nextCharSafeBody(const uint8_t *s, int32_t *pi, int32_t length, UChar32 c, int8_t strict) { // *pi is one after byte c. int32_t i=*pi; // length can be negative for NUL-terminated strings: Read and validate one byte at a time. @@ -233,7 +231,7 @@ utf8_appendCharSafeBody(uint8_t *s, int32_t i, int32_t length, UChar32 c, UBool } U_CAPI UChar32 U_EXPORT2 -utf8_prevCharSafeBody(const uint8_t *s, int32_t start, int32_t *pi, UChar32 c, UBool strict) { +utf8_prevCharSafeBody(const uint8_t *s, int32_t start, int32_t *pi, UChar32 c, int8_t strict) { // *pi is the index of byte c. int32_t i=*pi; if(U8_IS_TRAIL(c) && i>start) { diff --git a/contrib/libs/icu/common/utypes.cpp b/contrib/libs/icu/common/utypes.cpp index 4602314147f1..4d4c1f81b5e6 100644 --- a/contrib/libs/icu/common/utypes.cpp +++ b/contrib/libs/icu/common/utypes.cpp @@ -140,7 +140,8 @@ _uFmtErrorName[U_FMT_PARSE_ERROR_LIMIT - U_FMT_PARSE_ERROR_START] = { "U_MF_MISSING_SELECTOR_ANNOTATION_ERROR", "U_MF_DUPLICATE_DECLARATION_ERROR", "U_MF_OPERAND_MISMATCH_ERROR", - "U_MF_DUPLICATE_VARIANT_ERROR" + "U_MF_DUPLICATE_VARIANT_ERROR", + "U_MF_BAD_OPTION" }; static const char * const diff --git a/contrib/libs/icu/i18n/basictz.cpp b/contrib/libs/icu/i18n/basictz.cpp index a2c1ec7fb914..610a31ad5dc5 100644 --- a/contrib/libs/icu/i18n/basictz.cpp +++ b/contrib/libs/icu/i18n/basictz.cpp @@ -160,12 +160,13 @@ BasicTimeZone::getSimpleRulesNear(UDate date, InitialTimeZoneRule*& initial, || (tr.getFrom()->getDSTSavings() != 0 && tr.getTo()->getDSTSavings() == 0)) && (date + MILLIS_PER_YEAR > nextTransitionTime)) { - int32_t year, month, dom, dow, doy, mid; + int32_t year, mid; + int8_t month, dom, dow; UDate d; // Get local wall time for the next transition time Grego::timeToFields(nextTransitionTime + initialRaw + initialDst, - year, month, dom, dow, doy, mid, status); + year, month, dom, dow, mid, status); if (U_FAILURE(status)) return; int32_t weekInMonth = Grego::dayOfWeekInMonth(year, month, dom); // Create DOW rule @@ -193,7 +194,7 @@ BasicTimeZone::getSimpleRulesNear(UDate date, InitialTimeZoneRule*& initial, // Get local wall time for the next transition time Grego::timeToFields(tr.getTime() + tr.getFrom()->getRawOffset() + tr.getFrom()->getDSTSavings(), - year, month, dom, dow, doy, mid, status); + year, month, dom, dow, mid, status); if (U_FAILURE(status)) return; weekInMonth = Grego::dayOfWeekInMonth(year, month, dom); // Generate another DOW rule @@ -225,7 +226,7 @@ BasicTimeZone::getSimpleRulesNear(UDate date, InitialTimeZoneRule*& initial, // Generate another DOW rule Grego::timeToFields(tr.getTime() + tr.getFrom()->getRawOffset() + tr.getFrom()->getDSTSavings(), - year, month, dom, dow, doy, mid, status); + year, month, dom, dow, mid, status); if (U_FAILURE(status)) return; weekInMonth = Grego::dayOfWeekInMonth(year, month, dom); dtr = new DateTimeRule(month, weekInMonth, dow, mid, DateTimeRule::WALL_TIME); @@ -486,8 +487,7 @@ BasicTimeZone::getTimeZoneRulesAfter(UDate start, InitialTimeZoneRule*& initial, } } else { // Calculate the transition year - int32_t year, month, dom, dow, doy, mid; - Grego::timeToFields(tzt.getTime(), year, month, dom, dow, doy, mid, status); + int32_t year = Grego::timeToYear(tzt.getTime(), status); if (U_FAILURE(status)) { return; } diff --git a/contrib/libs/icu/i18n/buddhcal.cpp b/contrib/libs/icu/i18n/buddhcal.cpp index 7723ade105d2..c99b97e26713 100644 --- a/contrib/libs/icu/i18n/buddhcal.cpp +++ b/contrib/libs/icu/i18n/buddhcal.cpp @@ -36,7 +36,6 @@ static const int32_t kGregorianEpoch = 1970; // used as the default value of BuddhistCalendar::BuddhistCalendar(const Locale& aLocale, UErrorCode& success) : GregorianCalendar(aLocale, success) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } BuddhistCalendar::~BuddhistCalendar() @@ -48,12 +47,6 @@ BuddhistCalendar::BuddhistCalendar(const BuddhistCalendar& source) { } -BuddhistCalendar& BuddhistCalendar::operator= ( const BuddhistCalendar& right) -{ - GregorianCalendar::operator=(right); - return *this; -} - BuddhistCalendar* BuddhistCalendar::clone() const { return new BuddhistCalendar(*this); diff --git a/contrib/libs/icu/i18n/buddhcal.h b/contrib/libs/icu/i18n/buddhcal.h index 1fa8395b35b2..196b21311fda 100644 --- a/contrib/libs/icu/i18n/buddhcal.h +++ b/contrib/libs/icu/i18n/buddhcal.h @@ -82,13 +82,6 @@ class BuddhistCalendar : public GregorianCalendar { */ BuddhistCalendar(const BuddhistCalendar& source); - /** - * Default assignment operator - * @param right the object to be copied. - * @internal - */ - BuddhistCalendar& operator=(const BuddhistCalendar& right); - /** * Create and return a polymorphic copy of this calendar. * @return return a polymorphic copy of this calendar. diff --git a/contrib/libs/icu/i18n/calendar.cpp b/contrib/libs/icu/i18n/calendar.cpp index 97458567dcbd..4b57d0996944 100644 --- a/contrib/libs/icu/i18n/calendar.cpp +++ b/contrib/libs/icu/i18n/calendar.cpp @@ -156,7 +156,7 @@ U_CFUNC void ucal_dump(UCalendar* cal) { #endif /* Max value for stamp allowable before recalculation */ -#define STAMP_MAX 10000 +#define STAMP_MAX 127 static const char * const gCalTypes[] = { "gregorian", @@ -700,15 +700,10 @@ fIsTimeSet(false), fAreFieldsSet(false), fAreAllFieldsSet(false), fAreFieldsVirtuallySet(false), -fNextStamp(static_cast(kMinimumUserStamp)), -fTime(0), fLenient(true), -fZone(nullptr), fRepeatedWallTime(UCAL_WALLTIME_LAST), fSkippedWallTime(UCAL_WALLTIME_LAST) { - validLocale[0] = 0; - actualLocale[0] = 0; clear(); if (U_FAILURE(success)) { return; @@ -722,26 +717,21 @@ fSkippedWallTime(UCAL_WALLTIME_LAST) // ------------------------------------- -Calendar::Calendar(TimeZone* zone, const Locale& aLocale, UErrorCode& success) +Calendar::Calendar(TimeZone* adoptZone, const Locale& aLocale, UErrorCode& success) : UObject(), fIsTimeSet(false), fAreFieldsSet(false), fAreAllFieldsSet(false), fAreFieldsVirtuallySet(false), -fNextStamp(static_cast(kMinimumUserStamp)), -fTime(0), fLenient(true), -fZone(nullptr), fRepeatedWallTime(UCAL_WALLTIME_LAST), fSkippedWallTime(UCAL_WALLTIME_LAST) { - validLocale[0] = 0; - actualLocale[0] = 0; + LocalPointer zone(adoptZone, success); if (U_FAILURE(success)) { - delete zone; return; } - if (zone == nullptr) { + if (zone.isNull()) { #if defined (U_DEBUG_CAL) fprintf(stderr, "%s:%d: ILLEGAL ARG because timezone cannot be 0\n", __FILE__, __LINE__); @@ -751,7 +741,7 @@ fSkippedWallTime(UCAL_WALLTIME_LAST) } clear(); - fZone = zone; + fZone = zone.orphan(); setWeekData(aLocale, nullptr, success); } @@ -763,15 +753,10 @@ fIsTimeSet(false), fAreFieldsSet(false), fAreAllFieldsSet(false), fAreFieldsVirtuallySet(false), -fNextStamp(static_cast(kMinimumUserStamp)), -fTime(0), fLenient(true), -fZone(nullptr), fRepeatedWallTime(UCAL_WALLTIME_LAST), fSkippedWallTime(UCAL_WALLTIME_LAST) { - validLocale[0] = 0; - actualLocale[0] = 0; if (U_FAILURE(success)) { return; } @@ -779,6 +764,7 @@ fSkippedWallTime(UCAL_WALLTIME_LAST) fZone = zone.clone(); if (fZone == nullptr) { success = U_MEMORY_ALLOCATION_ERROR; + return; } setWeekData(aLocale, nullptr, success); } @@ -788,6 +774,8 @@ fSkippedWallTime(UCAL_WALLTIME_LAST) Calendar::~Calendar() { delete fZone; + delete actualLocale; + delete validLocale; } // ------------------------------------- @@ -795,7 +783,6 @@ Calendar::~Calendar() Calendar::Calendar(const Calendar &source) : UObject(source) { - fZone = nullptr; *this = source; } @@ -806,7 +793,6 @@ Calendar::operator=(const Calendar &right) { if (this != &right) { uprv_arrayCopy(right.fFields, fFields, UCAL_FIELD_COUNT); - uprv_arrayCopy(right.fIsSet, fIsSet, UCAL_FIELD_COUNT); uprv_arrayCopy(right.fStamp, fStamp, UCAL_FIELD_COUNT); fTime = right.fTime; fIsTimeSet = right.fIsTimeSet; @@ -828,10 +814,10 @@ Calendar::operator=(const Calendar &right) fWeekendCease = right.fWeekendCease; fWeekendCeaseMillis = right.fWeekendCeaseMillis; fNextStamp = right.fNextStamp; - uprv_strncpy(validLocale, right.validLocale, sizeof(validLocale)); - uprv_strncpy(actualLocale, right.actualLocale, sizeof(actualLocale)); - validLocale[sizeof(validLocale)-1] = 0; - actualLocale[sizeof(validLocale)-1] = 0; + UErrorCode status = U_ZERO_ERROR; + U_LOCALE_BASED(locBased, *this); + locBased.setLocaleIDs(right.validLocale, right.actualLocale, status); + U_ASSERT(U_SUCCESS(status)); } return *this; @@ -1167,13 +1153,9 @@ Calendar::setTimeInMillis( double millis, UErrorCode& status ) { fAreFieldsSet = fAreAllFieldsSet = false; fIsTimeSet = fAreFieldsVirtuallySet = true; - for (int32_t i=0; i>= 1; } @@ -1467,7 +1442,7 @@ void Calendar::computeFields(UErrorCode &ec) //__FILE__, __LINE__, fFields[UCAL_JULIAN_DAY], localMillis); #endif - computeGregorianAndDOWFields(fFields[UCAL_JULIAN_DAY], ec); + computeGregorianFields(fFields[UCAL_JULIAN_DAY], ec); // Call framework method to have subclass compute its fields. // These must include, at a minimum, MONTH, DAY_OF_MONTH, @@ -1538,32 +1513,6 @@ uint8_t Calendar::julianDayToDayOfWeek(int32_t julian) return result; } -/** -* Compute the Gregorian calendar year, month, and day of month from -* the given Julian day. These values are not stored in fields, but in -* member variables gregorianXxx. Also compute the DAY_OF_WEEK and -* DOW_LOCAL fields. -*/ -void Calendar::computeGregorianAndDOWFields(int32_t julianDay, UErrorCode &ec) -{ - computeGregorianFields(julianDay, ec); - if (U_FAILURE(ec)) { - return; - } - - // Compute day of week: JD 0 = Monday - int32_t dow = julianDayToDayOfWeek(julianDay); - internalSet(UCAL_DAY_OF_WEEK,dow); - - // Calculate 1-based localized day of week - int32_t dowLocal = dow - getFirstDayOfWeek() + 1; - if (dowLocal < 1) { - dowLocal += 7; - } - internalSet(UCAL_DOW_LOCAL,dowLocal); - fFields[UCAL_DOW_LOCAL] = dowLocal; -} - /** * Compute the Gregorian calendar year, month, and day of month from the * Julian day. These values are not stored in fields, but in member @@ -1575,14 +1524,13 @@ void Calendar::computeGregorianFields(int32_t julianDay, UErrorCode& ec) { if (U_FAILURE(ec)) { return; } - int32_t gregorianDayOfWeekUnused; if (uprv_add32_overflow( julianDay, -kEpochStartAsJulianDay, &julianDay)) { ec = U_ILLEGAL_ARGUMENT_ERROR; return; } Grego::dayToFields(julianDay, fGregorianYear, fGregorianMonth, - fGregorianDayOfMonth, gregorianDayOfWeekUnused, + fGregorianDayOfMonth, fGregorianDayOfYear, ec); } @@ -1610,8 +1558,19 @@ void Calendar::computeWeekFields(UErrorCode &ec) { if(U_FAILURE(ec)) { return; } + + // Compute day of week: JD 0 = Monday + int32_t dayOfWeek = julianDayToDayOfWeek(fFields[UCAL_JULIAN_DAY]); + internalSet(UCAL_DAY_OF_WEEK, dayOfWeek); + int32_t firstDayOfWeek = getFirstDayOfWeek(); + // Calculate 1-based localized day of week + int32_t dowLocal = dayOfWeek - firstDayOfWeek + 1; + if (dowLocal < 1) { + dowLocal += 7; + } + internalSet(UCAL_DOW_LOCAL,dowLocal); + int32_t eyear = fFields[UCAL_EXTENDED_YEAR]; - int32_t dayOfWeek = fFields[UCAL_DAY_OF_WEEK]; int32_t dayOfYear = fFields[UCAL_DAY_OF_YEAR]; // WEEK_OF_YEAR start @@ -1624,10 +1583,11 @@ void Calendar::computeWeekFields(UErrorCode &ec) { // first week of the next year. ASSUME that the year length is less than // 7000 days. int32_t yearOfWeekOfYear = eyear; - int32_t relDow = (dayOfWeek + 7 - getFirstDayOfWeek()) % 7; // 0..6 - int32_t relDowJan1 = (dayOfWeek - dayOfYear + 7001 - getFirstDayOfWeek()) % 7; // 0..6 + int32_t relDow = (dayOfWeek + 7 - firstDayOfWeek) % 7; // 0..6 + int32_t relDowJan1 = (dayOfWeek - dayOfYear + 7001 - firstDayOfWeek) % 7; // 0..6 int32_t woy = (dayOfYear - 1 + relDowJan1) / 7; // 0..53 - if ((7 - relDowJan1) >= getMinimalDaysInFirstWeek()) { + int32_t minimalDaysInFirstWeek = getMinimalDaysInFirstWeek(); + if ((7 - relDowJan1) >= minimalDaysInFirstWeek) { ++woy; } @@ -1639,11 +1599,13 @@ void Calendar::computeWeekFields(UErrorCode &ec) { // to handle the case in which we are the first week of the // next year. - int32_t prevDoy = dayOfYear + handleGetYearLength(eyear - 1); + int32_t prevDoy = dayOfYear + handleGetYearLength(eyear - 1, ec); + if(U_FAILURE(ec)) return; woy = weekNumber(prevDoy, dayOfWeek); yearOfWeekOfYear--; } else { - int32_t lastDoy = handleGetYearLength(eyear); + int32_t lastDoy = handleGetYearLength(eyear, ec); + if(U_FAILURE(ec)) return; // Fast check: For it to be week 1 of the next year, the DOY // must be on or after L-5, where L is yearLength(), then it // cannot possibly be week 1 of the next year: @@ -1655,7 +1617,7 @@ void Calendar::computeWeekFields(UErrorCode &ec) { if (lastRelDow < 0) { lastRelDow += 7; } - if (((6 - lastRelDow) >= getMinimalDaysInFirstWeek()) && + if (((6 - lastRelDow) >= minimalDaysInFirstWeek) && ((dayOfYear + 7 - relDow) > lastDoy)) { woy = 1; yearOfWeekOfYear++; @@ -2946,7 +2908,7 @@ void Calendar::validateField(UCalendarDateFields field, UErrorCode &status) { if (U_FAILURE(status)) { return; } - validateField(field, 1, handleGetYearLength(y), status); + validateField(field, 1, handleGetYearLength(y, status), status); break; case UCAL_DAY_OF_WEEK_IN_MONTH: if (internalGet(field) == 0) { @@ -3607,9 +3569,19 @@ int32_t Calendar::handleComputeJulianDay(UCalendarDateFields bestField, UErrorCo fprintf(stderr, "%s:%d - y=%d, y-1=%d doy%d, njd%d (C.F. %d)\n", __FILE__, __LINE__, year, year-1, testDate, julianDay+testDate, nextJulianDay); #endif - if(julianDay+testDate > nextJulianDay) { // is it past Dec 31? (nextJulianDay is day BEFORE year+1's Jan 1) + if (uprv_add32_overflow(julianDay, testDate, &testDate)) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; + } + + if(testDate > nextJulianDay) { // is it past Dec 31? (nextJulianDay is day BEFORE year+1's Jan 1) // Fire up the calculating engines.. retry YWOY = (year-1) - julianDay = handleComputeMonthStart(year-1, 0, false, status); // jd before Jan 1 of previous year + int32_t prevYear; + if (uprv_add32_overflow(year, -1, &prevYear)) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; + } + julianDay = handleComputeMonthStart(prevYear, 0, false, status); // jd before Jan 1 of previous year if (U_FAILURE(status)) { return 0; } @@ -3834,16 +3806,20 @@ int32_t Calendar::handleGetExtendedYearFromWeekFields(int32_t yearWoy, int32_t w int32_t Calendar::handleGetMonthLength(int32_t extendedYear, int32_t month, UErrorCode& status) const { - return handleComputeMonthStart(extendedYear, month+1, true, status) - + int32_t nextMonth; + if (uprv_add32_overflow(month, 1, &nextMonth)) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; + } + return handleComputeMonthStart(extendedYear, nextMonth, true, status) - handleComputeMonthStart(extendedYear, month, true, status); } -int32_t Calendar::handleGetYearLength(int32_t eyear) const +int32_t Calendar::handleGetYearLength(int32_t eyear, UErrorCode& status) const { - UErrorCode status = U_ZERO_ERROR; int32_t result = handleComputeMonthStart(eyear+1, 0, false, status) - handleComputeMonthStart(eyear, 0, false, status); - U_ASSERT(U_SUCCESS(status)); + if (U_FAILURE(status)) return 0; return result; } @@ -3882,7 +3858,7 @@ Calendar::getActualMaximum(UCalendarDateFields field, UErrorCode& status) const } cal->setLenient(true); cal->prepareGetActual(field,false,status); - result = handleGetYearLength(cal->get(UCAL_EXTENDED_YEAR, status)); + result = handleGetYearLength(cal->get(UCAL_EXTENDED_YEAR, status), status); delete cal; } break; @@ -4141,7 +4117,7 @@ Calendar::setWeekData(const Locale& desiredLocale, const char *type, UErrorCode& if (U_SUCCESS(status)) { U_LOCALE_BASED(locBased,*this); locBased.setLocaleIDs(ures_getLocaleByType(monthNames.getAlias(), ULOC_VALID_LOCALE, &status), - ures_getLocaleByType(monthNames.getAlias(), ULOC_ACTUAL_LOCALE, &status)); + ures_getLocaleByType(monthNames.getAlias(), ULOC_ACTUAL_LOCALE, &status), status); } else { status = U_USING_FALLBACK_WARNING; return; @@ -4229,14 +4205,12 @@ Calendar::updateTime(UErrorCode& status) Locale Calendar::getLocale(ULocDataLocaleType type, UErrorCode& status) const { - U_LOCALE_BASED(locBased, *this); - return locBased.getLocale(type, status); + return LocaleBased::getLocale(validLocale, actualLocale, type, status); } const char * Calendar::getLocaleID(ULocDataLocaleType type, UErrorCode& status) const { - U_LOCALE_BASED(locBased, *this); - return locBased.getLocaleID(type, status); + return LocaleBased::getLocaleID(validLocale, actualLocale, type, status); } void @@ -4245,7 +4219,7 @@ Calendar::recalculateStamp() { int32_t currentValue; int32_t j, i; - fNextStamp = 1; + fNextStamp = kInternallySet; for (j = 0; j < UCAL_FIELD_COUNT; j++) { currentValue = STAMP_MAX; diff --git a/contrib/libs/icu/i18n/cecal.cpp b/contrib/libs/icu/i18n/cecal.cpp index 7771c32efb30..33d32adab731 100644 --- a/contrib/libs/icu/i18n/cecal.cpp +++ b/contrib/libs/icu/i18n/cecal.cpp @@ -53,7 +53,6 @@ static const int32_t LIMITS[UCAL_FIELD_COUNT][4] = { CECalendar::CECalendar(const Locale& aLocale, UErrorCode& success) : Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, success) { - setTimeInMillis(getNow(), success); } CECalendar::CECalendar (const CECalendar& other) @@ -65,13 +64,6 @@ CECalendar::~CECalendar() { } -CECalendar& -CECalendar::operator=(const CECalendar& right) -{ - Calendar::operator=(right); - return *this; -} - //------------------------------------------------------------------------- // Calendar framework //------------------------------------------------------------------------- diff --git a/contrib/libs/icu/i18n/cecal.h b/contrib/libs/icu/i18n/cecal.h index 9c3332f3b84a..e6514e18f857 100644 --- a/contrib/libs/icu/i18n/cecal.h +++ b/contrib/libs/icu/i18n/cecal.h @@ -82,13 +82,6 @@ class U_I18N_API CECalendar : public Calendar { */ virtual ~CECalendar(); - /** - * Default assignment operator - * @param right Calendar object to be copied - * @internal - */ - CECalendar& operator=(const CECalendar& right); - protected: //------------------------------------------------------------------------- // Calendar framework diff --git a/contrib/libs/icu/i18n/chnsecal.cpp b/contrib/libs/icu/i18n/chnsecal.cpp index 050994fcbaf6..afb16d3e25a8 100644 --- a/contrib/libs/icu/i18n/chnsecal.cpp +++ b/contrib/libs/icu/i18n/chnsecal.cpp @@ -130,7 +130,6 @@ ChineseCalendar::ChineseCalendar(const Locale& aLocale, UErrorCode& success) : Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, success), hasLeapMonthBetweenWinterSolstices(false) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } ChineseCalendar::ChineseCalendar(const ChineseCalendar& other) : Calendar(other) { @@ -219,7 +218,9 @@ int32_t ChineseCalendar::handleGetExtendedYear(UErrorCode& status) { } int32_t year; - if (newestStamp(UCAL_ERA, UCAL_YEAR, kUnset) <= fStamp[UCAL_EXTENDED_YEAR]) { + // if UCAL_EXTENDED_YEAR is not older than UCAL_ERA nor UCAL_YEAR + if (newerField(UCAL_EXTENDED_YEAR, newerField(UCAL_ERA, UCAL_YEAR)) == + UCAL_EXTENDED_YEAR) { year = internalGet(UCAL_EXTENDED_YEAR, 1); // Default to year 1 } else { // adjust to the instance specific epoch @@ -252,11 +253,16 @@ int32_t ChineseCalendar::handleGetExtendedYear(UErrorCode& status) { * @stable ICU 2.8 */ int32_t ChineseCalendar::handleGetMonthLength(int32_t extendedYear, int32_t month, UErrorCode& status) const { + bool isLeapMonth = internalGet(UCAL_IS_LEAP_MONTH) == 1; + return handleGetMonthLengthWithLeap(extendedYear, month, isLeapMonth, status); +} + +int32_t ChineseCalendar::handleGetMonthLengthWithLeap(int32_t extendedYear, int32_t month, bool leap, UErrorCode& status) const { const Setting setting = getSetting(status); if (U_FAILURE(status)) { return 0; } - int32_t thisStart = handleComputeMonthStart(extendedYear, month, true, status); + int32_t thisStart = handleComputeMonthStartWithLeap(extendedYear, month, leap, status); if (U_FAILURE(status)) { return 0; } @@ -332,18 +338,24 @@ struct MonthInfo computeMonthInfo( * @stable ICU 2.8 */ int64_t ChineseCalendar::handleComputeMonthStart(int32_t eyear, int32_t month, UBool useMonth, UErrorCode& status) const { + bool isLeapMonth = false; + if (useMonth) { + isLeapMonth = internalGet(UCAL_IS_LEAP_MONTH) != 0; + } + return handleComputeMonthStartWithLeap(eyear, month, isLeapMonth, status); +} + +int64_t ChineseCalendar::handleComputeMonthStartWithLeap(int32_t eyear, int32_t month, bool isLeapMonth, UErrorCode& status) const { if (U_FAILURE(status)) { return 0; } // If the month is out of range, adjust it into range, and // modify the extended year value accordingly. if (month < 0 || month > 11) { - double m = month; - if (uprv_add32_overflow(eyear, ClockMath::floorDivide(m, 12.0, &m), &eyear)) { + if (uprv_add32_overflow(eyear, ClockMath::floorDivide(month, 12, &month), &eyear)) { status = U_ILLEGAL_ARGUMENT_ERROR; return 0; } - month = static_cast(m); } const Setting setting = getSetting(status); @@ -362,19 +374,9 @@ int64_t ChineseCalendar::handleComputeMonthStart(int32_t eyear, int32_t month, U return 0; } - // Ignore IS_LEAP_MONTH field if useMonth is false - bool isLeapMonth = false; - if (useMonth) { - isLeapMonth = internalGet(UCAL_IS_LEAP_MONTH) != 0; - } - - int32_t unusedMonth; - int32_t unusedDayOfWeek; - int32_t unusedDayOfMonth; - int32_t unusedDayOfYear; - Grego::dayToFields(newMoon, gyear, unusedMonth, unusedDayOfWeek, unusedDayOfMonth, unusedDayOfYear, status); + int32_t newMonthYear = Grego::dayToYear(newMoon, status); - struct MonthInfo monthInfo = computeMonthInfo(setting, gyear, newMoon, status); + struct MonthInfo monthInfo = computeMonthInfo(setting, newMonthYear, newMoon, status); if (U_FAILURE(status)) { return 0; } @@ -794,6 +796,9 @@ struct MonthInfo computeMonthInfo( solsticeBefore = solsticeAfter; solsticeAfter = winterSolstice(setting, gyear + 1, status); } + if (!(solsticeBefore <= days && days < solsticeAfter)) { + status = U_ILLEGAL_ARGUMENT_ERROR; + } if (U_FAILURE(status)) { return output; } @@ -1043,7 +1048,12 @@ void ChineseCalendar::offsetMonth(int32_t newMoon, int32_t dayOfMonth, int32_t d } // Find the target dayOfMonth - int32_t jd = newMoon + kEpochStartAsJulianDay - 1 + dayOfMonth; + int32_t jd; + if (uprv_add32_overflow(newMoon, kEpochStartAsJulianDay - 1, &jd) || + uprv_add32_overflow(jd, dayOfMonth, &jd)) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return; + } // Pin the dayOfMonth. In this calendar all months are 29 or 30 days // so pinning just means handling dayOfMonth 30. @@ -1182,6 +1192,27 @@ ChineseCalendar::Setting ChineseCalendar::getSetting(UErrorCode&) const { }; } +int32_t +ChineseCalendar::getActualMaximum(UCalendarDateFields field, UErrorCode& status) const +{ + if (U_FAILURE(status)) { + return 0; + } + if (field == UCAL_DATE) { + LocalPointer cal(clone(), status); + if(U_FAILURE(status)) { + return 0; + } + cal->setLenient(true); + cal->prepareGetActual(field,false,status); + int32_t year = cal->get(UCAL_EXTENDED_YEAR, status); + int32_t month = cal->get(UCAL_MONTH, status); + bool leap = cal->get(UCAL_IS_LEAP_MONTH, status) != 0; + return handleGetMonthLengthWithLeap(year, month, leap, status); + } + return Calendar::getActualMaximum(field, status); +} + U_NAMESPACE_END #endif diff --git a/contrib/libs/icu/i18n/chnsecal.h b/contrib/libs/icu/i18n/chnsecal.h index 41bd3557fcbf..410a5a0222cf 100644 --- a/contrib/libs/icu/i18n/chnsecal.h +++ b/contrib/libs/icu/i18n/chnsecal.h @@ -194,6 +194,10 @@ class U_I18N_API ChineseCalendar : public Calendar { virtual void handleComputeFields(int32_t julianDay, UErrorCode &status) override; virtual const UFieldResolutionTable* getFieldResolutionTable() const override; + private: + int32_t handleGetMonthLengthWithLeap(int32_t extendedYear, int32_t month, bool isLeap, UErrorCode& status) const; + int64_t handleComputeMonthStartWithLeap(int32_t eyear, int32_t month, bool isLeap, UErrorCode& status) const; + public: virtual void add(UCalendarDateFields field, int32_t amount, UErrorCode &status) override; virtual void add(EDateFields field, int32_t amount, UErrorCode &status) override; @@ -254,6 +258,8 @@ class U_I18N_API ChineseCalendar : public Calendar { */ virtual const char * getType() const override; + virtual int32_t getActualMaximum(UCalendarDateFields field, UErrorCode& status) const override; + struct Setting { int32_t epochYear; const TimeZone* zoneAstroCalc; diff --git a/contrib/libs/icu/i18n/collationruleparser.cpp b/contrib/libs/icu/i18n/collationruleparser.cpp index b20d2c9428c4..f5608cde7dc6 100644 --- a/contrib/libs/icu/i18n/collationruleparser.cpp +++ b/contrib/libs/icu/i18n/collationruleparser.cpp @@ -613,18 +613,24 @@ CollationRuleParser::parseSetting(UErrorCode &errorCode) { return; } // localeID minus all keywords - char baseID[ULOC_FULLNAME_CAPACITY]; - int32_t length = uloc_getBaseName(localeID.data(), baseID, ULOC_FULLNAME_CAPACITY, &errorCode); - if(U_FAILURE(errorCode) || length >= ULOC_KEYWORDS_CAPACITY) { + CharString baseID = ulocimp_getBaseName(localeID.toStringPiece(), errorCode); + if (U_FAILURE(errorCode)) { errorCode = U_ZERO_ERROR; setParseError("expected language tag in [import langTag]", errorCode); return; } - if(length == 0) { - uprv_strcpy(baseID, "root"); - } else if(*baseID == '_') { - uprv_memmove(baseID + 3, baseID, length + 1); - uprv_memcpy(baseID, "und", 3); + if (baseID.isEmpty()) { + baseID.copyFrom("root", errorCode); + } else if (baseID[0] == '_') { + // CharString doesn't have any insert() method, only append(). + constexpr char und[] = "und"; + constexpr int32_t length = sizeof und - 1; + int32_t dummy; + char* tail = baseID.getAppendBuffer(length, length, dummy, errorCode); + char* head = baseID.data(); + uprv_memmove(head + length, head, baseID.length()); + uprv_memcpy(head, und, length); + baseID.append(tail, length, errorCode); } // @collation=type, or length=0 if not specified CharString collationType = ulocimp_getKeywordValue(localeID.data(), "collation", errorCode); @@ -637,7 +643,7 @@ CollationRuleParser::parseSetting(UErrorCode &errorCode) { setParseError("[import langTag] is not supported", errorCode); } else { UnicodeString importedRules; - importer->getRules(baseID, + importer->getRules(baseID.data(), !collationType.isEmpty() ? collationType.data() : "standard", importedRules, errorReason, errorCode); if(U_FAILURE(errorCode)) { diff --git a/contrib/libs/icu/i18n/datefmt.cpp b/contrib/libs/icu/i18n/datefmt.cpp index 655cfbd1239d..de9efc7ca8f9 100644 --- a/contrib/libs/icu/i18n/datefmt.cpp +++ b/contrib/libs/icu/i18n/datefmt.cpp @@ -40,6 +40,7 @@ #if defined( U_DEBUG_CALSVC ) || defined (U_DEBUG_CAL) #include #endif +#include // ***************************************************************************** // class DateFormat @@ -279,9 +280,8 @@ UnicodeString& DateFormat::format(UDate date, UnicodeString& appendTo, FieldPosition& fieldPosition) const { if (fCalendar != nullptr) { UErrorCode ec = U_ZERO_ERROR; - const auto* calType = fCalendar->getType(); // Avoid a heap allocation and corresponding free for the common case - if (uprv_strcmp(calType, "gregorian") == 0) { + if (typeid(*fCalendar) == typeid(GregorianCalendar)) { GregorianCalendar cal(*static_cast(fCalendar)); cal.setTime(date, ec); if (U_SUCCESS(ec)) { @@ -309,9 +309,8 @@ DateFormat::format(UDate date, UnicodeString& appendTo, FieldPositionIterator* p UErrorCode& status) const { if (fCalendar != nullptr) { UErrorCode ec = U_ZERO_ERROR; - const auto* calType = fCalendar->getType(); // Avoid a heap allocation and corresponding free for the common case - if (uprv_strcmp(calType, "gregorian") == 0) { + if (typeid(*fCalendar) == typeid(GregorianCalendar)) { GregorianCalendar cal(*static_cast(fCalendar)); cal.setTime(date, ec); if (U_SUCCESS(ec)) { diff --git a/contrib/libs/icu/i18n/dcfmtsym.cpp b/contrib/libs/icu/i18n/dcfmtsym.cpp index b4c90e6765a7..b85f3ad134a2 100644 --- a/contrib/libs/icu/i18n/dcfmtsym.cpp +++ b/contrib/libs/icu/i18n/dcfmtsym.cpp @@ -118,7 +118,6 @@ DecimalFormatSymbols::DecimalFormatSymbols(const Locale& loc, const NumberingSys DecimalFormatSymbols::DecimalFormatSymbols() : UObject(), locale(Locale::getRoot()) { - *validLocale = *actualLocale = 0; initialize(); } @@ -136,6 +135,8 @@ DecimalFormatSymbols::createWithLastResortData(UErrorCode& status) { DecimalFormatSymbols::~DecimalFormatSymbols() { + delete actualLocale; + delete validLocale; } // ------------------------------------- @@ -163,8 +164,12 @@ DecimalFormatSymbols::operator=(const DecimalFormatSymbols& rhs) currencySpcAfterSym[i].fastCopyFrom(rhs.currencySpcAfterSym[i]); } locale = rhs.locale; - uprv_strcpy(validLocale, rhs.validLocale); - uprv_strcpy(actualLocale, rhs.actualLocale); + + UErrorCode status = U_ZERO_ERROR; + U_LOCALE_BASED(locBased, *this); + locBased.setLocaleIDs(rhs.validLocale, rhs.actualLocale, status); + U_ASSERT(U_SUCCESS(status)); + fIsCustomCurrencySymbol = rhs.fIsCustomCurrencySymbol; fIsCustomIntlCurrencySymbol = rhs.fIsCustomIntlCurrencySymbol; fCodePointZero = rhs.fCodePointZero; @@ -203,8 +208,8 @@ DecimalFormatSymbols::operator==(const DecimalFormatSymbols& that) const } // No need to check fCodePointZero since it is based on fSymbols return locale == that.locale && - uprv_strcmp(validLocale, that.validLocale) == 0 && - uprv_strcmp(actualLocale, that.actualLocale) == 0; + LocaleBased::equalIDs(actualLocale, that.actualLocale) && + LocaleBased::equalIDs(validLocale, that.validLocale); } // ------------------------------------- @@ -353,7 +358,6 @@ DecimalFormatSymbols::initialize(const Locale& loc, UErrorCode& status, UBool useLastResortData, const NumberingSystem* ns) { if (U_FAILURE(status)) { return; } - *validLocale = *actualLocale = 0; // First initialize all the symbols to the fallbacks for anything we can't find initialize(); @@ -409,7 +413,8 @@ DecimalFormatSymbols::initialize(const Locale& loc, UErrorCode& status, ULOC_VALID_LOCALE, &status), ures_getLocaleByType( numberElementsRes.getAlias(), - ULOC_ACTUAL_LOCALE, &status)); + ULOC_ACTUAL_LOCALE, &status), + status); // Now load the rest of the data from the data sink. // Start with loading this nsName if it is not Latin. @@ -568,8 +573,7 @@ void DecimalFormatSymbols::setCurrency(const char16_t* currency, UErrorCode& sta Locale DecimalFormatSymbols::getLocale(ULocDataLocaleType type, UErrorCode& status) const { - U_LOCALE_BASED(locBased, *this); - return locBased.getLocale(type, status); + return LocaleBased::getLocale(validLocale, actualLocale, type, status); } const UnicodeString& diff --git a/contrib/libs/icu/i18n/dtfmtsym.cpp b/contrib/libs/icu/i18n/dtfmtsym.cpp index 23cea3eba20a..339db48dba85 100644 --- a/contrib/libs/icu/i18n/dtfmtsym.cpp +++ b/contrib/libs/icu/i18n/dtfmtsym.cpp @@ -402,9 +402,8 @@ void DateFormatSymbols::copyData(const DateFormatSymbols& other) { UErrorCode status = U_ZERO_ERROR; U_LOCALE_BASED(locBased, *this); - locBased.setLocaleIDs( - other.getLocale(ULOC_VALID_LOCALE, status), - other.getLocale(ULOC_ACTUAL_LOCALE, status)); + locBased.setLocaleIDs(other.validLocale, other.actualLocale, status); + U_ASSERT(U_SUCCESS(status)); assignArray(fEras, fErasCount, other.fEras, other.fErasCount); assignArray(fEraNames, fEraNamesCount, other.fEraNames, other.fEraNamesCount); assignArray(fNarrowEras, fNarrowErasCount, other.fNarrowEras, other.fNarrowErasCount); @@ -497,6 +496,8 @@ DateFormatSymbols& DateFormatSymbols::operator=(const DateFormatSymbols& other) DateFormatSymbols::~DateFormatSymbols() { dispose(); + delete actualLocale; + delete validLocale; } void DateFormatSymbols::dispose() @@ -536,6 +537,10 @@ void DateFormatSymbols::dispose() delete[] fStandaloneWideDayPeriods; delete[] fStandaloneNarrowDayPeriods; + delete actualLocale; + actualLocale = nullptr; + delete validLocale; + validLocale = nullptr; disposeZoneStrings(); } @@ -2302,7 +2307,7 @@ DateFormatSymbols::initializeData(const Locale& locale, const char *type, UError // of it that we need except for the time-zone and localized-pattern data, which // are stored in a separate file locBased.setLocaleIDs(ures_getLocaleByType(cb.getAlias(), ULOC_VALID_LOCALE, &status), - ures_getLocaleByType(cb.getAlias(), ULOC_ACTUAL_LOCALE, &status)); + ures_getLocaleByType(cb.getAlias(), ULOC_ACTUAL_LOCALE, &status), status); // Load eras initField(&fEras, fErasCount, calendarSink, buildResourcePath(path, gErasTag, gNamesAbbrTag, status), status); @@ -2528,8 +2533,7 @@ DateFormatSymbols::initializeData(const Locale& locale, const char *type, UError Locale DateFormatSymbols::getLocale(ULocDataLocaleType type, UErrorCode& status) const { - U_LOCALE_BASED(locBased, *this); - return locBased.getLocale(type, status); + return LocaleBased::getLocale(validLocale, actualLocale, type, status); } U_NAMESPACE_END diff --git a/contrib/libs/icu/i18n/erarules.cpp b/contrib/libs/icu/i18n/erarules.cpp index 8ab6f00ae04b..d23d7d516c72 100644 --- a/contrib/libs/icu/i18n/erarules.cpp +++ b/contrib/libs/icu/i18n/erarules.cpp @@ -305,8 +305,9 @@ void EraRules::initCurrentEra() { localMillis += (rawOffset + dstOffset); } - int year, month0, dom, dow, doy, mid; - Grego::timeToFields(localMillis, year, month0, dom, dow, doy, mid, ec); + int32_t year, mid; + int8_t month0, dom; + Grego::timeToFields(localMillis, year, month0, dom, mid, ec); if (U_FAILURE(ec)) return; int currentEncodedDate = encodeDate(year, month0 + 1 /* changes to 1-base */, dom); int eraIdx = numEras - 1; diff --git a/contrib/libs/icu/i18n/format.cpp b/contrib/libs/icu/i18n/format.cpp index 10856a4acba2..b4aec1d98115 100644 --- a/contrib/libs/icu/i18n/format.cpp +++ b/contrib/libs/icu/i18n/format.cpp @@ -24,6 +24,7 @@ #include "utypeinfo.h" // for 'typeid' to work #include "unicode/utypes.h" +#include "charstr.h" #ifndef U_I18N_IMPLEMENTATION #error U_I18N_IMPLEMENTATION not set - must be set for all ICU source files in i18n/ - see https://unicode-org.github.io/icu/userguide/howtouseicu @@ -72,13 +73,14 @@ FieldPosition::clone() const { Format::Format() : UObject() { - *validLocale = *actualLocale = 0; } // ------------------------------------- Format::~Format() { + delete actualLocale; + delete validLocale; } // ------------------------------------- @@ -97,8 +99,10 @@ Format& Format::operator=(const Format& that) { if (this != &that) { - uprv_strcpy(validLocale, that.validLocale); - uprv_strcpy(actualLocale, that.actualLocale); + UErrorCode status = U_ZERO_ERROR; + U_LOCALE_BASED(locBased, *this); + locBased.setLocaleIDs(that.validLocale, that.actualLocale, status); + U_ASSERT(U_SUCCESS(status)); } return *this; } @@ -196,20 +200,20 @@ void Format::syntaxError(const UnicodeString& pattern, Locale Format::getLocale(ULocDataLocaleType type, UErrorCode& status) const { - U_LOCALE_BASED(locBased, *this); - return locBased.getLocale(type, status); + return LocaleBased::getLocale(validLocale, actualLocale, type, status); } const char * Format::getLocaleID(ULocDataLocaleType type, UErrorCode& status) const { - U_LOCALE_BASED(locBased, *this); - return locBased.getLocaleID(type, status); + return LocaleBased::getLocaleID(validLocale,actualLocale, type, status); } void Format::setLocaleIDs(const char* valid, const char* actual) { U_LOCALE_BASED(locBased, *this); - locBased.setLocaleIDs(valid, actual); + UErrorCode status = U_ZERO_ERROR; + locBased.setLocaleIDs(valid, actual, status); + U_ASSERT(U_SUCCESS(status)); } U_NAMESPACE_END diff --git a/contrib/libs/icu/i18n/formattedvalue.cpp b/contrib/libs/icu/i18n/formattedvalue.cpp index aacd6ac70e09..f2bfdda6e465 100644 --- a/contrib/libs/icu/i18n/formattedvalue.cpp +++ b/contrib/libs/icu/i18n/formattedvalue.cpp @@ -193,6 +193,11 @@ ucfpos_close(UConstrainedFieldPosition* ptr) { } +// -Wreturn-local-addr first found in https://gcc.gnu.org/onlinedocs/gcc-4.8.5/gcc/Warning-Options.html#Warning-Options +#if U_GCC_MAJOR_MINOR >= 409 +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wreturn-local-addr" +#endif U_CAPI const char16_t* U_EXPORT2 ufmtval_getString( const UFormattedValue* ufmtval, @@ -213,6 +218,9 @@ ufmtval_getString( // defined to return memory owned by the ufmtval argument. return readOnlyAlias.getBuffer(); } +#if U_GCC_MAJOR_MINOR >= 409 +#pragma GCC diagnostic pop +#endif U_CAPI UBool U_EXPORT2 diff --git a/contrib/libs/icu/i18n/gregocal.cpp b/contrib/libs/icu/i18n/gregocal.cpp index 23366c7ab7a3..8a4bb15c16d6 100644 --- a/contrib/libs/icu/i18n/gregocal.cpp +++ b/contrib/libs/icu/i18n/gregocal.cpp @@ -147,6 +147,7 @@ UOBJECT_DEFINE_RTTI_IMPLEMENTATION(GregorianCalendar) // in Java, -12219292800000L //const UDate GregorianCalendar::kPapalCutover = -12219292800000L; static const uint32_t kCutoverJulianDay = 2299161; +static const int32_t kDefaultCutoverYear = 1582; static const UDate kPapalCutover = (2299161.0 - kEpochStartAsJulianDay) * U_MILLIS_PER_DAY; //static const UDate kPapalCutoverJulian = (2299161.0 - kEpochStartAsJulianDay); @@ -155,7 +156,7 @@ static const UDate kPapalCutover = (2299161.0 - kEpochStartAsJulianDay) * U_MILL GregorianCalendar::GregorianCalendar(UErrorCode& status) : Calendar(status), fGregorianCutover(kPapalCutover), -fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), +fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(kDefaultCutoverYear), fIsGregorian(true), fInvertGregorian(false) { setTimeInMillis(getNow(), status); @@ -164,34 +165,22 @@ fIsGregorian(true), fInvertGregorian(false) // ------------------------------------- GregorianCalendar::GregorianCalendar(TimeZone* zone, UErrorCode& status) -: Calendar(zone, Locale::getDefault(), status), -fGregorianCutover(kPapalCutover), -fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), -fIsGregorian(true), fInvertGregorian(false) +: GregorianCalendar(zone, Locale::getDefault(), status) { - setTimeInMillis(getNow(), status); } // ------------------------------------- GregorianCalendar::GregorianCalendar(const TimeZone& zone, UErrorCode& status) -: Calendar(zone, Locale::getDefault(), status), -fGregorianCutover(kPapalCutover), -fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), -fIsGregorian(true), fInvertGregorian(false) +: GregorianCalendar(zone, Locale::getDefault(), status) { - setTimeInMillis(getNow(), status); } // ------------------------------------- GregorianCalendar::GregorianCalendar(const Locale& aLocale, UErrorCode& status) -: Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, status), -fGregorianCutover(kPapalCutover), -fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), -fIsGregorian(true), fInvertGregorian(false) +: GregorianCalendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, status) { - setTimeInMillis(getNow(), status); } // ------------------------------------- @@ -200,7 +189,7 @@ GregorianCalendar::GregorianCalendar(TimeZone* zone, const Locale& aLocale, UErrorCode& status) : Calendar(zone, aLocale, status), fGregorianCutover(kPapalCutover), - fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), + fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(kDefaultCutoverYear), fIsGregorian(true), fInvertGregorian(false) { setTimeInMillis(getNow(), status); @@ -212,7 +201,7 @@ GregorianCalendar::GregorianCalendar(const TimeZone& zone, const Locale& aLocale UErrorCode& status) : Calendar(zone, aLocale, status), fGregorianCutover(kPapalCutover), - fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), + fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(kDefaultCutoverYear), fIsGregorian(true), fInvertGregorian(false) { setTimeInMillis(getNow(), status); @@ -224,7 +213,7 @@ GregorianCalendar::GregorianCalendar(int32_t year, int32_t month, int32_t date, UErrorCode& status) : Calendar(TimeZone::createDefault(), Locale::getDefault(), status), fGregorianCutover(kPapalCutover), - fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), + fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(kDefaultCutoverYear), fIsGregorian(true), fInvertGregorian(false) { set(UCAL_ERA, AD); @@ -237,15 +226,8 @@ GregorianCalendar::GregorianCalendar(int32_t year, int32_t month, int32_t date, GregorianCalendar::GregorianCalendar(int32_t year, int32_t month, int32_t date, int32_t hour, int32_t minute, UErrorCode& status) - : Calendar(TimeZone::createDefault(), Locale::getDefault(), status), - fGregorianCutover(kPapalCutover), - fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), - fIsGregorian(true), fInvertGregorian(false) + : GregorianCalendar(year, month, date, status) { - set(UCAL_ERA, AD); - set(UCAL_YEAR, year); - set(UCAL_MONTH, month); - set(UCAL_DATE, date); set(UCAL_HOUR_OF_DAY, hour); set(UCAL_MINUTE, minute); } @@ -255,17 +237,8 @@ GregorianCalendar::GregorianCalendar(int32_t year, int32_t month, int32_t date, GregorianCalendar::GregorianCalendar(int32_t year, int32_t month, int32_t date, int32_t hour, int32_t minute, int32_t second, UErrorCode& status) - : Calendar(TimeZone::createDefault(), Locale::getDefault(), status), - fGregorianCutover(kPapalCutover), - fCutoverJulianDay(kCutoverJulianDay), fNormalizedGregorianCutover(fGregorianCutover), fGregorianCutoverYear(1582), - fIsGregorian(true), fInvertGregorian(false) + : GregorianCalendar(year, month, date, hour, minute, status) { - set(UCAL_ERA, AD); - set(UCAL_YEAR, year); - set(UCAL_MONTH, month); - set(UCAL_DATE, date); - set(UCAL_HOUR_OF_DAY, hour); - set(UCAL_MINUTE, minute); set(UCAL_SECOND, second); } @@ -601,7 +574,8 @@ int32_t GregorianCalendar::handleGetMonthLength(int32_t extendedYear, int32_t mo return isLeapYear(extendedYear) ? kLeapMonthLength[month] : kMonthLength[month]; } -int32_t GregorianCalendar::handleGetYearLength(int32_t eyear) const { +int32_t GregorianCalendar::handleGetYearLength(int32_t eyear, UErrorCode& status) const { + if (U_FAILURE(status)) return 0; return isLeapYear(eyear) ? 366 : 365; } @@ -871,13 +845,14 @@ GregorianCalendar::roll(UCalendarDateFields field, int32_t amount, UErrorCode& s } if (month == UCAL_JANUARY) { if (woy >= 52) { - isoDoy += handleGetYearLength(isoYear); + isoDoy += handleGetYearLength(isoYear, status); } } else { if (woy == 1) { - isoDoy -= handleGetYearLength(isoYear - 1); + isoDoy -= handleGetYearLength(isoYear - 1, status); } } + if (U_FAILURE(status)) return; if (uprv_add32_overflow(woy, amount, &woy)) { status = U_ILLEGAL_ARGUMENT_ERROR; return; @@ -890,7 +865,8 @@ GregorianCalendar::roll(UCalendarDateFields field, int32_t amount, UErrorCode& s // days at the end of the year are going to fall into // week 1 of the next year, we drop the last week by // subtracting 7 from the last day of the year. - int32_t lastDoy = handleGetYearLength(isoYear); + int32_t lastDoy = handleGetYearLength(isoYear, status); + if (U_FAILURE(status)) return; int32_t lastRelDow = (lastDoy - isoDoy + internalGet(UCAL_DAY_OF_WEEK) - getFirstDayOfWeek()) % 7; if (lastRelDow < 0) lastRelDow += 7; @@ -1186,14 +1162,10 @@ int32_t GregorianCalendar::handleGetExtendedYear(UErrorCode& status) { int32_t year = kEpochYear; // year field to use - int32_t yearField = UCAL_EXTENDED_YEAR; - // There are three separate fields which could be used to // derive the proper year. Use the one most recently set. - if (fStamp[yearField] < fStamp[UCAL_YEAR]) - yearField = UCAL_YEAR; - if (fStamp[yearField] < fStamp[UCAL_YEAR_WOY]) - yearField = UCAL_YEAR_WOY; + UCalendarDateFields yearField = newerField( + newerField(UCAL_EXTENDED_YEAR, UCAL_YEAR), UCAL_YEAR_WOY); // based on the "best" year field, get the year switch(yearField) { diff --git a/contrib/libs/icu/i18n/gregoimp.cpp b/contrib/libs/icu/i18n/gregoimp.cpp index d5c8437a9b80..03bf9d2c9fdf 100644 --- a/contrib/libs/icu/i18n/gregoimp.cpp +++ b/contrib/libs/icu/i18n/gregoimp.cpp @@ -117,57 +117,110 @@ int64_t Grego::fieldsToDay(int32_t year, int32_t month, int32_t dom) { return julian - JULIAN_1970_CE; // JD => epoch day } -void Grego::dayToFields(int32_t day, int32_t& year, int32_t& month, - int32_t& dom, int32_t& dow, int32_t& doy, UErrorCode& status) { - +void Grego::dayToFields(int32_t day, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, int16_t& doy, UErrorCode& status) { + year = dayToYear(day, doy, status); // one-based doy if (U_FAILURE(status)) return; + // Convert from 1970 CE epoch to 1 CE epoch (Gregorian calendar) if (uprv_add32_overflow(day, JULIAN_1970_CE - JULIAN_1_CE, &day)) { status = U_ILLEGAL_ARGUMENT_ERROR; return; } - // Convert from the day number to the multiple radix - // representation. We use 400-year, 100-year, and 4-year cycles. - // For example, the 4-year cycle has 4 years + 1 leap day; giving - // 1461 == 365*4 + 1 days. - int32_t n400 = ClockMath::floorDivide(day, 146097, &doy); // 400-year cycle length - int32_t n100 = ClockMath::floorDivide(doy, 36524, &doy); // 100-year cycle length - int32_t n4 = ClockMath::floorDivide(doy, 1461, &doy); // 4-year cycle length - int32_t n1 = ClockMath::floorDivide(doy, 365, &doy); - year = 400*n400 + 100*n100 + 4*n4 + n1; - if (n100 == 4 || n1 == 4) { - doy = 365; // Dec 31 at end of 4- or 400-year cycle - } else { - ++year; - } - - UBool isLeap = isLeapYear(year); - // Gregorian day zero is a Monday. dow = (day + 1) % 7; dow += (dow < 0) ? (UCAL_SUNDAY + 7) : UCAL_SUNDAY; // Common Julian/Gregorian calculation int32_t correction = 0; + bool isLeap = isLeapYear(year); int32_t march1 = isLeap ? 60 : 59; // zero-based DOY for March 1 - if (doy >= march1) { + if (doy > march1) { correction = isLeap ? 1 : 2; } - month = (12 * (doy + correction) + 6) / 367; // zero-based month - dom = doy - DAYS_BEFORE[month + (isLeap ? 12 : 0)] + 1; // one-based DOM + month = (12 * (doy - 1 + correction) + 6) / 367; // zero-based month + dom = doy - DAYS_BEFORE[month + (isLeap ? 12 : 0)]; // one-based DOM +} + +int32_t Grego::dayToYear(int32_t day, UErrorCode& status) { + int16_t unusedDOY; + return dayToYear(day, unusedDOY, status); +} + +int32_t Grego::dayToYear(int32_t day, int16_t& doy, UErrorCode& status) { + if (U_FAILURE(status)) return 0; + // Convert from 1970 CE epoch to 1 CE epoch (Gregorian calendar) + if (uprv_add32_overflow(day, JULIAN_1970_CE - JULIAN_1_CE, &day)) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; + } + + // Convert from the day number to the multiple radix + // representation. We use 400-year, 100-year, and 4-year cycles. + // For example, the 4-year cycle has 4 years + 1 leap day; giving + // 1461 == 365*4 + 1 days. + int32_t doy32; + int32_t n400 = ClockMath::floorDivide(day, 146097, &doy32); // 400-year cycle length + int32_t n100 = ClockMath::floorDivide(doy32, 36524, &doy32); // 100-year cycle length + int32_t n4 = ClockMath::floorDivide(doy32, 1461, &doy32); // 4-year cycle length + int32_t n1 = ClockMath::floorDivide(doy32, 365, &doy32); + int32_t year = 400*n400 + 100*n100 + 4*n4 + n1; + if (n100 == 4 || n1 == 4) { + doy = 365; // Dec 31 at end of 4- or 400-year cycle + } else { + doy = doy32; + ++year; + } doy++; // one-based doy + return year; +} + +void Grego::dayToFields(int32_t day, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, UErrorCode& status) { + int16_t unusedDOY; + dayToFields(day, year, month, dom, dow, unusedDOY, status); +} + +void Grego::dayToFields(int32_t day, int32_t& year, int8_t& month, + int8_t& dom, int16_t& doy, UErrorCode& status) { + int8_t unusedDOW; + dayToFields(day, year, month, dom, unusedDOW, doy, status); } -void Grego::timeToFields(UDate time, int32_t& year, int32_t& month, - int32_t& dom, int32_t& dow, int32_t& doy, int32_t& mid, UErrorCode& status) { +void Grego::timeToFields(UDate time, int32_t& year, int8_t& month, + int8_t& dom, int32_t& mid, UErrorCode& status) { + int8_t unusedDOW; + timeToFields(time, year, month, dom, unusedDOW, mid, status); +} + +void Grego::timeToFields(UDate time, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, int32_t& mid, UErrorCode& status) { + int16_t unusedDOY; + timeToFields(time, year, month, dom, dow, unusedDOY, mid, status); +} + +void Grego::timeToFields(UDate time, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, int16_t& doy, int32_t& mid, UErrorCode& status) { if (U_FAILURE(status)) return; - double millisInDay; - double day = ClockMath::floorDivide(static_cast(time), static_cast(U_MILLIS_PER_DAY), &millisInDay); - mid = static_cast(millisInDay); + double day = ClockMath::floorDivide(time, U_MILLIS_PER_DAY, &mid); + if (day > INT32_MAX || day < INT32_MIN) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return; + } dayToFields(day, year, month, dom, dow, doy, status); } +int32_t Grego::timeToYear(UDate time, UErrorCode& status) { + if (U_FAILURE(status)) return 0; + double day = ClockMath::floorDivide(time, double(U_MILLIS_PER_DAY)); + if (day > INT32_MAX || day < INT32_MIN) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; + } + return Grego::dayToYear(day, status); +} + int32_t Grego::dayOfWeek(int32_t day) { int32_t dow; ClockMath::floorDivide(day + int{UCAL_THURSDAY}, 7, &dow); diff --git a/contrib/libs/icu/i18n/gregoimp.h b/contrib/libs/icu/i18n/gregoimp.h index e069fb60de79..39881c0eefbe 100644 --- a/contrib/libs/icu/i18n/gregoimp.h +++ b/contrib/libs/icu/i18n/gregoimp.h @@ -210,8 +210,21 @@ class Grego { * @param doy output parameter to receive day-of-year (1-based) * @param status error code. */ - static void dayToFields(int32_t day, int32_t& year, int32_t& month, - int32_t& dom, int32_t& dow, int32_t& doy, UErrorCode& status); + static void dayToFields(int32_t day, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, int16_t& doy, UErrorCode& status); + + /** + * Convert a 1970-epoch day number to proleptic Gregorian year, + * month, day-of-month, and day-of-week. + * @param day 1970-epoch day + * @param year output parameter to receive year + * @param month output parameter to receive month (0-based, 0==Jan) + * @param dom output parameter to receive day-of-month (1-based) + * @param doy output parameter to receive day-of-year (1-based) + * @param status error code. + */ + static void dayToFields(int32_t day, int32_t& year, int8_t& month, + int8_t& dom, int16_t& doy, UErrorCode& status); /** * Convert a 1970-epoch day number to proleptic Gregorian year, @@ -223,8 +236,24 @@ class Grego { * @param dow output parameter to receive day-of-week (1-based, 1==Sun) * @param status error code. */ - static inline void dayToFields(int32_t day, int32_t& year, int32_t& month, - int32_t& dom, int32_t& dow, UErrorCode& status); + static void dayToFields(int32_t day, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, UErrorCode& status); + + /** + * Convert a 1970-epoch day number to proleptic Gregorian year. + * @param day 1970-epoch day + * @param status error code. + * @return year. + */ + static int32_t dayToYear(int32_t day, UErrorCode& status); + /** + * Convert a 1970-epoch day number to proleptic Gregorian year. + * @param day 1970-epoch day + * @param doy output parameter to receive day-of-year (1-based) + * @param status error code. + * @return year. + */ + static int32_t dayToYear(int32_t day, int16_t& doy, UErrorCode& status); /** * Convert a 1970-epoch milliseconds to proleptic Gregorian year, @@ -238,8 +267,43 @@ class Grego { * @param mid output parameter to receive millis-in-day * @param status error code. */ - static void timeToFields(UDate time, int32_t& year, int32_t& month, - int32_t& dom, int32_t& dow, int32_t& doy, int32_t& mid, UErrorCode& status); + static void timeToFields(UDate time, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, int16_t& doy, int32_t& mid, UErrorCode& status); + + /** + * Convert a 1970-epoch milliseconds to proleptic Gregorian year, + * month, day-of-month, and day-of-week, day of year and millis-in-day. + * @param time 1970-epoch milliseconds + * @param year output parameter to receive year + * @param month output parameter to receive month (0-based, 0==Jan) + * @param dom output parameter to receive day-of-month (1-based) + * @param dow output parameter to receive day-of-week (1-based, 1==Sun) + * @param mid output parameter to receive millis-in-day + * @param status error code. + */ + static void timeToFields(UDate time, int32_t& year, int8_t& month, + int8_t& dom, int8_t& dow, int32_t& mid, UErrorCode& status); + + /** + * Convert a 1970-epoch milliseconds to proleptic Gregorian year, + * month, day-of-month, and day-of-week, day of year and millis-in-day. + * @param time 1970-epoch milliseconds + * @param year output parameter to receive year + * @param month output parameter to receive month (0-based, 0==Jan) + * @param dom output parameter to receive day-of-month (1-based) + * @param mid output parameter to receive millis-in-day + * @param status error code. + */ + static void timeToFields(UDate time, int32_t& year, int8_t& month, + int8_t& dom, int32_t& mid, UErrorCode& status); + + /** + * Convert a 1970-epoch milliseconds to proleptic Gregorian year. + * @param time 1970-epoch milliseconds + * @param status error code. + * @return year. + */ + static int32_t timeToYear(UDate time, UErrorCode& status); /** * Return the day of week on the 1970-epoch day @@ -305,12 +369,6 @@ Grego::previousMonthLength(int y, int m) { return (m > 0) ? monthLength(y, m-1) : 31; } -inline void Grego::dayToFields(int32_t day, int32_t& year, int32_t& month, - int32_t& dom, int32_t& dow, UErrorCode& status) { - int32_t doy_unused; - dayToFields(day,year,month,dom,dow,doy_unused, status); -} - inline double Grego::julianDayToMillis(int32_t julian) { return (static_cast(julian) - kEpochStartAsJulianDay) * kOneDay; diff --git a/contrib/libs/icu/i18n/hebrwcal.cpp b/contrib/libs/icu/i18n/hebrwcal.cpp index ef70a48f2353..70dfe9b7c735 100644 --- a/contrib/libs/icu/i18n/hebrwcal.cpp +++ b/contrib/libs/icu/i18n/hebrwcal.cpp @@ -164,7 +164,6 @@ HebrewCalendar::HebrewCalendar(const Locale& aLocale, UErrorCode& success) : Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, success) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } @@ -591,13 +590,8 @@ int32_t HebrewCalendar::handleGetMonthLength(int32_t extendedYear, int32_t month * Returns the number of days in the given Hebrew year * @internal */ -int32_t HebrewCalendar::handleGetYearLength(int32_t eyear) const { - UErrorCode status = U_ZERO_ERROR; - int32_t len = daysInYear(eyear, status); - if (U_FAILURE(status)) { - return 12; - } - return len; +int32_t HebrewCalendar::handleGetYearLength(int32_t eyear, UErrorCode& status) const { + return daysInYear(eyear, status); } void HebrewCalendar::validateField(UCalendarDateFields field, UErrorCode &status) { diff --git a/contrib/libs/icu/i18n/hebrwcal.h b/contrib/libs/icu/i18n/hebrwcal.h index 5fb10993d307..33db1b7860ab 100644 --- a/contrib/libs/icu/i18n/hebrwcal.h +++ b/contrib/libs/icu/i18n/hebrwcal.h @@ -326,9 +326,9 @@ class U_I18N_API HebrewCalendar : public Calendar { * calendar system. Subclasses should override this method if they can * provide a more correct or more efficient implementation than the * default implementation in Calendar. - * @stable ICU 2.0 + * @internal */ - virtual int32_t handleGetYearLength(int32_t eyear) const override; + virtual int32_t handleGetYearLength(int32_t eyear, UErrorCode& status) const override; /** * Subclasses may override this method to compute several fields diff --git a/contrib/libs/icu/i18n/indiancal.cpp b/contrib/libs/icu/i18n/indiancal.cpp index b1fd39b9927e..bb4b6b9939c0 100644 --- a/contrib/libs/icu/i18n/indiancal.cpp +++ b/contrib/libs/icu/i18n/indiancal.cpp @@ -41,7 +41,6 @@ IndianCalendar* IndianCalendar::clone() const { IndianCalendar::IndianCalendar(const Locale& aLocale, UErrorCode& success) : Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, success) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } IndianCalendar::IndianCalendar(const IndianCalendar& other) : Calendar(other) { @@ -129,7 +128,8 @@ int32_t IndianCalendar::handleGetMonthLength(int32_t eyear, int32_t month, UErro * * @param eyear The year in Saka Era. */ -int32_t IndianCalendar::handleGetYearLength(int32_t eyear) const { +int32_t IndianCalendar::handleGetYearLength(int32_t eyear, UErrorCode& status) const { + if (U_FAILURE(status)) return 0; return isGregorianLeap(eyear + INDIAN_ERA_START) ? 366 : 365; } /* @@ -143,18 +143,6 @@ static double gregorianToJD(int32_t year, int32_t month, int32_t date) { return Grego::fieldsToDay(year, month, date) + kEpochStartAsJulianDay - 0.5; } -/* - * Returns the Gregorian Date corresponding to a given Julian Day - * Month is 0 based. - * @param jd The Julian Day - */ -static int32_t* jdToGregorian(double jd, int32_t gregorianDate[3], UErrorCode& status) { - int32_t gdow; - Grego::dayToFields(jd - kEpochStartAsJulianDay, - gregorianDate[0], gregorianDate[1], gregorianDate[2], gdow, status); - return gregorianDate; -} - //------------------------------------------------------------------------- // Functions for converting from field values to milliseconds.... @@ -266,10 +254,9 @@ int32_t IndianCalendar::handleGetExtendedYear(UErrorCode& status) { void IndianCalendar::handleComputeFields(int32_t julianDay, UErrorCode& status) { double jdAtStartOfGregYear; int32_t leapMonth, IndianYear, yday, IndianMonth, IndianDayOfMonth, mday; - int32_t gregorianYear; // Stores gregorian date corresponding to Julian day; - int32_t gd[3]; + // Stores gregorian date corresponding to Julian day; + int32_t gregorianYear = Grego::dayToYear(julianDay - kEpochStartAsJulianDay, status); - gregorianYear = jdToGregorian(julianDay, gd, status)[0]; // Gregorian date for Julian day if (U_FAILURE(status)) return; IndianYear = gregorianYear - INDIAN_ERA_START; // Year in Saka era jdAtStartOfGregYear = gregorianToJD(gregorianYear, 0, 1); // JD at start of Gregorian year diff --git a/contrib/libs/icu/i18n/indiancal.h b/contrib/libs/icu/i18n/indiancal.h index 2062bcec9103..ff067d0b3c3d 100644 --- a/contrib/libs/icu/i18n/indiancal.h +++ b/contrib/libs/icu/i18n/indiancal.h @@ -215,7 +215,7 @@ class U_I18N_API IndianCalendar : public Calendar { * Return the number of days in the given Indian year * @internal */ - virtual int32_t handleGetYearLength(int32_t extendedYear) const override; + virtual int32_t handleGetYearLength(int32_t extendedYear, UErrorCode& status) const override; //------------------------------------------------------------------------- // Functions for converting from field values to milliseconds.... diff --git a/contrib/libs/icu/i18n/islamcal.cpp b/contrib/libs/icu/i18n/islamcal.cpp index dfeac36a6651..e847ac28c894 100644 --- a/contrib/libs/icu/i18n/islamcal.cpp +++ b/contrib/libs/icu/i18n/islamcal.cpp @@ -202,7 +202,6 @@ IslamicCalendar* IslamicCalendar::clone() const { IslamicCalendar::IslamicCalendar(const Locale& aLocale, UErrorCode& success) : Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, success) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } IslamicCalendar::~IslamicCalendar() @@ -444,15 +443,8 @@ int32_t yearLength(int32_t extendedYear, UErrorCode& status) { * Return the number of days in the given Islamic year * @draft ICU 2.4 */ -int32_t IslamicCalendar::handleGetYearLength(int32_t extendedYear) const { - UErrorCode status = U_ZERO_ERROR; - int32_t length = yearLength(extendedYear, status); - if (U_FAILURE(status)) { - // fallback to normal Islamic calendar length 355 day a year if we - // encounter error and cannot propagate. - return 355; - } - return length; +int32_t IslamicCalendar::handleGetYearLength(int32_t extendedYear, UErrorCode& status) const { + return yearLength(extendedYear, status); } //------------------------------------------------------------------------- @@ -706,7 +698,8 @@ int32_t IslamicCivilCalendar::handleGetMonthLength(int32_t extendedYear, int32_t * Return the number of days in the given Islamic year * @draft ICU 2.4 */ -int32_t IslamicCivilCalendar::handleGetYearLength(int32_t extendedYear) const { +int32_t IslamicCivilCalendar::handleGetYearLength(int32_t extendedYear, UErrorCode& status) const { + if (U_FAILURE(status)) return 0; return 354 + (civilLeapYear(extendedYear) ? 1 : 0); } @@ -872,7 +865,7 @@ int32_t IslamicUmalquraCalendar::handleGetMonthLength(int32_t extendedYear, int3 int32_t IslamicUmalquraCalendar::yearLength(int32_t extendedYear, UErrorCode& status) const { if (extendedYearUMALQURA_YEAR_END) { - return IslamicCivilCalendar::handleGetYearLength(extendedYear); + return IslamicCivilCalendar::handleGetYearLength(extendedYear, status); } int length = 0; for(int i=0; i<12; i++) { @@ -888,15 +881,8 @@ int32_t IslamicUmalquraCalendar::yearLength(int32_t extendedYear, UErrorCode& st * Return the number of days in the given Islamic year * @draft ICU 2.4 */ -int32_t IslamicUmalquraCalendar::handleGetYearLength(int32_t extendedYear) const { - UErrorCode status = U_ZERO_ERROR; - int32_t length = yearLength(extendedYear, status); - if (U_FAILURE(status)) { - // fallback to normal Islamic calendar length 355 day a year if we - // encounter error and cannot propagate. - return 355; - } - return length; +int32_t IslamicUmalquraCalendar::handleGetYearLength(int32_t extendedYear, UErrorCode& status) const { + return yearLength(extendedYear, status); } /** diff --git a/contrib/libs/icu/i18n/islamcal.h b/contrib/libs/icu/i18n/islamcal.h index e42e681328b4..db90255b5b5a 100644 --- a/contrib/libs/icu/i18n/islamcal.h +++ b/contrib/libs/icu/i18n/islamcal.h @@ -235,7 +235,7 @@ class U_I18N_API IslamicCalendar : public Calendar { * Return the number of days in the given Islamic year * @internal */ - virtual int32_t handleGetYearLength(int32_t extendedYear) const override; + virtual int32_t handleGetYearLength(int32_t extendedYear, UErrorCode& status) const override; //------------------------------------------------------------------------- // Functions for converting from field values to milliseconds.... @@ -438,7 +438,7 @@ class U_I18N_API IslamicCivilCalendar : public IslamicCalendar { * Return the number of days in the given Islamic year * @internal */ - virtual int32_t handleGetYearLength(int32_t extendedYear) const override; + virtual int32_t handleGetYearLength(int32_t extendedYear, UErrorCode& status) const override; /** * Override Calendar to compute several fields specific to the Islamic @@ -621,7 +621,7 @@ class U_I18N_API IslamicUmalquraCalendar : public IslamicCivilCalendar { * Return the number of days in the given Islamic year * @internal */ - virtual int32_t handleGetYearLength(int32_t extendedYear) const override; + virtual int32_t handleGetYearLength(int32_t extendedYear, UErrorCode& status) const override; /** * Override Calendar to compute several fields specific to the Islamic diff --git a/contrib/libs/icu/i18n/japancal.cpp b/contrib/libs/icu/i18n/japancal.cpp index c0dd9fad0dc0..b389b4530b29 100644 --- a/contrib/libs/icu/i18n/japancal.cpp +++ b/contrib/libs/icu/i18n/japancal.cpp @@ -115,7 +115,6 @@ JapaneseCalendar::JapaneseCalendar(const Locale& aLocale, UErrorCode& success) : GregorianCalendar(aLocale, success) { init(success); - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } JapaneseCalendar::~JapaneseCalendar() @@ -130,12 +129,6 @@ JapaneseCalendar::JapaneseCalendar(const JapaneseCalendar& source) U_ASSERT(U_SUCCESS(status)); } -JapaneseCalendar& JapaneseCalendar::operator= ( const JapaneseCalendar& right) -{ - GregorianCalendar::operator=(right); - return *this; -} - JapaneseCalendar* JapaneseCalendar::clone() const { return new JapaneseCalendar(*this); diff --git a/contrib/libs/icu/i18n/japancal.h b/contrib/libs/icu/i18n/japancal.h index 627b12750b98..3271cbfb794a 100644 --- a/contrib/libs/icu/i18n/japancal.h +++ b/contrib/libs/icu/i18n/japancal.h @@ -104,13 +104,6 @@ class JapaneseCalendar : public GregorianCalendar { */ JapaneseCalendar(const JapaneseCalendar& source); - /** - * Default assignment operator - * @param right the object to be copied. - * @internal - */ - JapaneseCalendar& operator=(const JapaneseCalendar& right); - /** * Create and return a polymorphic copy of this calendar. * @return return a polymorphic copy of this calendar. diff --git a/contrib/libs/icu/i18n/measunit.cpp b/contrib/libs/icu/i18n/measunit.cpp index 2741b84aabf0..8dda799d0165 100644 --- a/contrib/libs/icu/i18n/measunit.cpp +++ b/contrib/libs/icu/i18n/measunit.cpp @@ -41,26 +41,26 @@ static const int32_t gOffsets[] = { 2, 7, 17, - 27, - 31, - 333, - 344, - 362, - 366, - 375, - 378, - 382, - 390, - 412, - 416, - 431, + 28, + 32, + 334, + 345, + 363, + 367, + 376, + 379, + 383, + 391, + 413, + 417, 432, - 438, - 449, - 455, - 459, - 461, - 495 + 433, + 439, + 450, + 456, + 460, + 462, + 496 }; static const int32_t kCurrencyOffset = 5; @@ -121,6 +121,7 @@ static const char * const gSubTypes[] = { "permille", "permillion", "permyriad", + "portion-per-1e9", "liter-per-100-kilometer", "liter-per-kilometer", "mile-per-gallon", @@ -811,6 +812,14 @@ MeasureUnit MeasureUnit::getPermyriad() { return MeasureUnit(3, 9); } +MeasureUnit *MeasureUnit::createPortionPer1E9(UErrorCode &status) { + return MeasureUnit::create(3, 10, status); +} + +MeasureUnit MeasureUnit::getPortionPer1E9() { + return MeasureUnit(3, 10); +} + MeasureUnit *MeasureUnit::createLiterPer100Kilometers(UErrorCode &status) { return MeasureUnit::create(4, 0, status); } @@ -2400,6 +2409,7 @@ MeasureUnitImpl MeasureUnitImpl::copy(UErrorCode &status) const { MeasureUnitImpl result; result.complexity = complexity; result.identifier.append(identifier, status); + result.constantDenominator = constantDenominator; for (int32_t i = 0; i < singleUnits.length(); i++) { SingleUnitImpl *item = result.singleUnits.emplaceBack(*singleUnits[i]); if (!item) { diff --git a/contrib/libs/icu/i18n/measunit_extra.cpp b/contrib/libs/icu/i18n/measunit_extra.cpp index a6348422738b..8eb9fe551670 100644 --- a/contrib/libs/icu/i18n/measunit_extra.cpp +++ b/contrib/libs/icu/i18n/measunit_extra.cpp @@ -15,6 +15,7 @@ #include "charstr.h" #include "cmemory.h" #include "cstring.h" +#include "double-conversion-string-to-double.h" #include "measunit_impl.h" #include "resource.h" #include "uarrsort.h" @@ -30,13 +31,15 @@ #include "unicode/ustringtrie.h" #include "uresimp.h" #include "util.h" +#include #include - U_NAMESPACE_BEGIN namespace { +using icu::double_conversion::StringToDoubleConverter; + // TODO: Propose a new error code for this? constexpr UErrorCode kUnitIdentifierSyntaxError = U_ILLEGAL_ARGUMENT_ERROR; @@ -467,37 +470,55 @@ void U_CALLCONV initUnitExtras(UErrorCode& status) { class Token { public: - Token(int32_t match) : fMatch(match) {} - - enum Type { - TYPE_UNDEFINED, - TYPE_PREFIX, - // Token type for "-per-", "-", and "-and-". - TYPE_COMPOUND_PART, - // Token type for "per-". - TYPE_INITIAL_COMPOUND_PART, - TYPE_POWER_PART, - TYPE_SIMPLE_UNIT, - }; - - // Calling getType() is invalid, resulting in an assertion failure, if Token - // value isn't positive. - Type getType() const { - U_ASSERT(fMatch > 0); - if (fMatch < kCompoundPartOffset) { - return TYPE_PREFIX; - } - if (fMatch < kInitialCompoundPartOffset) { - return TYPE_COMPOUND_PART; - } - if (fMatch < kPowerPartOffset) { - return TYPE_INITIAL_COMPOUND_PART; - } - if (fMatch < kSimpleUnitOffset) { - return TYPE_POWER_PART; - } - return TYPE_SIMPLE_UNIT; - } + Token(int64_t match) : fMatch(match) { + if (fMatch < kCompoundPartOffset) { + this->fType = TYPE_PREFIX; + } else if (fMatch < kInitialCompoundPartOffset) { + this->fType = TYPE_COMPOUND_PART; + } else if (fMatch < kPowerPartOffset) { + this->fType = TYPE_INITIAL_COMPOUND_PART; + } else if (fMatch < kSimpleUnitOffset) { + this->fType = TYPE_POWER_PART; + } else { + this->fType = TYPE_SIMPLE_UNIT; + } + } + + static Token constantToken(StringPiece str, UErrorCode &status) { + Token result; + auto value = Token::parseStringToLong(str, status); + if (U_FAILURE(status)) { + return result; + } + result.fMatch = value; + result.fType = TYPE_CONSTANT_DENOMINATOR; + return result; + } + + enum Type { + TYPE_UNDEFINED, + TYPE_PREFIX, + // Token type for "-per-", "-", and "-and-". + TYPE_COMPOUND_PART, + // Token type for "per-". + TYPE_INITIAL_COMPOUND_PART, + TYPE_POWER_PART, + TYPE_SIMPLE_UNIT, + TYPE_CONSTANT_DENOMINATOR, + }; + + // Calling getType() is invalid, resulting in an assertion failure, if Token + // value isn't positive. + Type getType() const { + U_ASSERT(fMatch >= 0); + return this->fType; + } + + // Retrieve the value of the constant denominator if the token is of type TYPE_CONSTANT_DENOMINATOR. + uint64_t getConstantDenominator() const { + U_ASSERT(getType() == TYPE_CONSTANT_DENOMINATOR); + return static_cast(fMatch); + } UMeasurePrefix getUnitPrefix() const { U_ASSERT(getType() == TYPE_PREFIX); @@ -530,8 +551,41 @@ class Token { return fMatch - kSimpleUnitOffset; } + // TODO: Consider moving this to a separate utility class. + // Utility function to parse a string into an unsigned long value. + // The value must be a positive integer within the range [1, INT64_MAX]. + // The input can be in integer or scientific notation. + static uint64_t parseStringToLong(const StringPiece strNum, UErrorCode &status) { + // We are processing well-formed input, so we don't need any special options to + // StringToDoubleConverter. + StringToDoubleConverter converter(0, 0, 0, "", ""); + int32_t count; + double double_result = converter.StringToDouble(strNum.data(), strNum.length(), &count); + if (count != strNum.length()) { + status = kUnitIdentifierSyntaxError; + return 0; + } + + if (U_FAILURE(status) || double_result < 1.0 || double_result > static_cast(INT64_MAX)) { + status = kUnitIdentifierSyntaxError; + return 0; + } + + // Check if the value is integer. + uint64_t int_result = static_cast(double_result); + const double kTolerance = 1e-9; + if (abs(double_result - int_result) > kTolerance) { + status = kUnitIdentifierSyntaxError; + return 0; + } + + return int_result; + } + private: - int32_t fMatch; + Token() = default; + int64_t fMatch; + Type fType = TYPE_UNDEFINED; }; class Parser { @@ -555,6 +609,50 @@ class Parser { return {source}; } + /** + * A single unit or a constant denominator. + */ + struct SingleUnitOrConstant { + enum ValueType { + kSingleUnit, + kConstantDenominator, + }; + + ValueType type = kSingleUnit; + SingleUnitImpl singleUnit; + uint64_t constantDenominator; + + static SingleUnitOrConstant singleUnitValue(SingleUnitImpl singleUnit) { + SingleUnitOrConstant result; + result.type = kSingleUnit; + result.singleUnit = singleUnit; + result.constantDenominator = 0; + return result; + } + + static SingleUnitOrConstant constantDenominatorValue(uint64_t constant) { + SingleUnitOrConstant result; + result.type = kConstantDenominator; + result.singleUnit = {}; + result.constantDenominator = constant; + return result; + } + + uint64_t getConstantDenominator() const { + U_ASSERT(type == kConstantDenominator); + return constantDenominator; + } + + SingleUnitImpl getSingleUnit() const { + U_ASSERT(type == kSingleUnit); + return singleUnit; + } + + bool isSingleUnit() const { return type == kSingleUnit; } + + bool isConstantDenominator() const { return type == kConstantDenominator; } + }; + MeasureUnitImpl parse(UErrorCode& status) { MeasureUnitImpl result; @@ -569,12 +667,19 @@ class Parser { while (hasNext()) { bool sawAnd = false; - SingleUnitImpl singleUnit = nextSingleUnit(sawAnd, status); + auto singleUnitOrConstant = nextSingleUnitOrConstant(sawAnd, status); if (U_FAILURE(status)) { return result; } - bool added = result.appendSingleUnit(singleUnit, status); + if (singleUnitOrConstant.isConstantDenominator()) { + result.constantDenominator = singleUnitOrConstant.getConstantDenominator(); + result.complexity = UMEASURE_UNIT_COMPOUND; + continue; + } + + U_ASSERT(singleUnitOrConstant.isSingleUnit()); + bool added = result.appendSingleUnit(singleUnitOrConstant.getSingleUnit(), status); if (U_FAILURE(status)) { return result; } @@ -604,6 +709,12 @@ class Parser { } } + if (result.singleUnits.length() == 0) { + // The identifier was empty or only had a constant denominator. + status = kUnitIdentifierSyntaxError; + return result; // add it for code consistency. + } + return result; } @@ -622,6 +733,10 @@ class Parser { // identifier is invalid pending TODO(CLDR-13701). bool fAfterPer = false; + // Set to true when we've just seen a "per-". This is used to determine if + // the next token can be a constant denominator token. + bool fJustSawPer = false; + Parser() : fSource(""), fTrie(u"") {} Parser(StringPiece source) @@ -640,6 +755,10 @@ class Parser { // Saves the position in the fSource string for the end of the most // recent matching token. int32_t previ = -1; + + // Saves the position in the fSource string for later use in case of unit constant found. + int32_t currentFIndex = fIndex; + // Find the longest token that matches a value in the trie: while (fIndex < fSource.length()) { auto result = fTrie.next(fSource.data()[fIndex++]); @@ -658,12 +777,25 @@ class Parser { // continue; } - if (match < 0) { - status = kUnitIdentifierSyntaxError; - } else { + if (match >= 0) { fIndex = previ; + return {match}; + } + + // If no match was found, we check if the token is a constant denominator. + // 1. We find the index of the start of the next token or the end of the string. + int32_t endOfConstantIndex = fSource.find("-", currentFIndex); + endOfConstantIndex = (endOfConstantIndex == -1) ? fSource.length() : endOfConstantIndex; + if (endOfConstantIndex <= currentFIndex) { + status = kUnitIdentifierSyntaxError; + return {match}; } - return {match}; + + // 2. We extract the substring from the start of the constant to the end of the constant. + StringPiece constantDenominatorStr = + fSource.substr(currentFIndex, endOfConstantIndex - currentFIndex); + fIndex = endOfConstantIndex; + return Token::constantToken(constantDenominatorStr, status); } /** @@ -680,10 +812,10 @@ class Parser { * unit", sawAnd is set to true. If not, it is left as is. * @param status ICU error code. */ - SingleUnitImpl nextSingleUnit(bool &sawAnd, UErrorCode &status) { - SingleUnitImpl result; + SingleUnitOrConstant nextSingleUnitOrConstant(bool &sawAnd, UErrorCode &status) { + SingleUnitImpl singleUnitResult; if (U_FAILURE(status)) { - return result; + return {}; } // state: @@ -695,19 +827,22 @@ class Parser { bool atStart = fIndex == 0; Token token = nextToken(status); if (U_FAILURE(status)) { - return result; + return {}; } + fJustSawPer = false; + if (atStart) { // Identifiers optionally start with "per-". if (token.getType() == Token::TYPE_INITIAL_COMPOUND_PART) { U_ASSERT(token.getInitialCompoundPart() == INITIAL_COMPOUND_PART_PER); fAfterPer = true; - result.dimensionality = -1; + fJustSawPer = true; + singleUnitResult.dimensionality = -1; token = nextToken(status); if (U_FAILURE(status)) { - return result; + return {}; } } } else { @@ -715,7 +850,7 @@ class Parser { // via a compound part: if (token.getType() != Token::TYPE_COMPOUND_PART) { status = kUnitIdentifierSyntaxError; - return result; + return {}; } switch (token.getMatch()) { @@ -724,15 +859,16 @@ class Parser { // Mixed compound units not yet supported, // TODO(CLDR-13701). status = kUnitIdentifierSyntaxError; - return result; + return {}; } fAfterPer = true; - result.dimensionality = -1; + fJustSawPer = true; + singleUnitResult.dimensionality = -1; break; case COMPOUND_PART_TIMES: if (fAfterPer) { - result.dimensionality = -1; + singleUnitResult.dimensionality = -1; } break; @@ -741,7 +877,7 @@ class Parser { // Can't start with "-and-", and mixed compound units // not yet supported, TODO(CLDR-13701). status = kUnitIdentifierSyntaxError; - return result; + return {}; } sawAnd = true; break; @@ -749,52 +885,65 @@ class Parser { token = nextToken(status); if (U_FAILURE(status)) { - return result; + return {}; + } + } + + if (token.getType() == Token::TYPE_CONSTANT_DENOMINATOR) { + if (!fJustSawPer) { + status = kUnitIdentifierSyntaxError; + return {}; } + + return SingleUnitOrConstant::constantDenominatorValue(token.getConstantDenominator()); } // Read tokens until we have a complete SingleUnit or we reach the end. while (true) { switch (token.getType()) { - case Token::TYPE_POWER_PART: - if (state > 0) { - status = kUnitIdentifierSyntaxError; - return result; - } - result.dimensionality *= token.getPower(); - state = 1; - break; - - case Token::TYPE_PREFIX: - if (state > 1) { - status = kUnitIdentifierSyntaxError; - return result; - } - result.unitPrefix = token.getUnitPrefix(); - state = 2; - break; - - case Token::TYPE_SIMPLE_UNIT: - result.index = token.getSimpleUnitIndex(); - return result; + case Token::TYPE_POWER_PART: + if (state > 0) { + status = kUnitIdentifierSyntaxError; + return {}; + } + singleUnitResult.dimensionality *= token.getPower(); + state = 1; + break; - default: + case Token::TYPE_PREFIX: + if (state > 1) { status = kUnitIdentifierSyntaxError; - return result; + return {}; + } + singleUnitResult.unitPrefix = token.getUnitPrefix(); + state = 2; + break; + + case Token::TYPE_SIMPLE_UNIT: + singleUnitResult.index = token.getSimpleUnitIndex(); + break; + + default: + status = kUnitIdentifierSyntaxError; + return {}; + } + + if (token.getType() == Token::TYPE_SIMPLE_UNIT) { + break; } if (!hasNext()) { // We ran out of tokens before finding a complete single unit. status = kUnitIdentifierSyntaxError; - return result; + return {}; } token = nextToken(status); if (U_FAILURE(status)) { - return result; + return {}; } } - return result; + return SingleUnitOrConstant::singleUnitValue(singleUnitResult); } }; @@ -1120,6 +1269,51 @@ MeasureUnitImpl::extractIndividualUnitsWithIndices(UErrorCode &status) const { return result; } +int32_t countCharacter(const CharString &str, char c) { + int32_t count = 0; + for (int32_t i = 0, n = str.length(); i < n; i++) { + if (str[i] == c) { + count++; + } + } + return count; +} + +/** + * Internal function that returns a string of the constants in the correct + * format. + * + * Example: + * 1000 --> "-per-1000" + * 1000000 --> "-per-1e6" + * + * NOTE: this function is only used when the constant denominator is greater + * than 0. + */ +CharString getConstantsString(uint64_t constantDenominator, UErrorCode &status) { + U_ASSERT(constantDenominator > 0 && constantDenominator <= LLONG_MAX); + + CharString result; + result.appendNumber(constantDenominator, status); + if (U_FAILURE(status)) { + return result; + } + + if (constantDenominator <= 1000) { + return result; + } + + // Check if the constant is a power of 10. + int32_t zeros = countCharacter(result, '0'); + if (zeros == result.length() - 1 && result[0] == '1') { + result.clear(); + result.append(StringPiece("1e"), status); + result.appendNumber(zeros, status); + } + + return result; +} + /** * Normalize a MeasureUnitImpl and generate the identifier string in place. */ @@ -1128,7 +1322,7 @@ void MeasureUnitImpl::serialize(UErrorCode &status) { return; } - if (this->singleUnits.length() == 0) { + if (this->singleUnits.length() == 0 && this->constantDenominator == 0) { // Dimensionless, constructed by the default constructor. return; } @@ -1145,6 +1339,7 @@ void MeasureUnitImpl::serialize(UErrorCode &status) { CharString result; bool beforePer = true; bool firstTimeNegativeDimension = false; + bool constantDenominatorAppended = false; for (int32_t i = 0; i < this->singleUnits.length(); i++) { if (beforePer && (*this->singleUnits[i]).dimensionality < 0) { beforePer = false; @@ -1168,43 +1363,103 @@ void MeasureUnitImpl::serialize(UErrorCode &status) { } else { result.append(StringPiece("-per-"), status); } - } else { - if (result.length() != 0) { + + if (this->constantDenominator > 0) { + result.append(getConstantsString(this->constantDenominator, status), status); result.append(StringPiece("-"), status); + constantDenominatorAppended = true; } + + } else if (result.length() != 0) { + result.append(StringPiece("-"), status); } } this->singleUnits[i]->appendNeutralIdentifier(result, status); } + if (!constantDenominatorAppended && this->constantDenominator > 0) { + result.append(StringPiece("-per-"), status); + result.append(getConstantsString(this->constantDenominator, status), status); + } + + if (U_FAILURE(status)) { + return; + } this->identifier = CharString(result, status); } -MeasureUnit MeasureUnitImpl::build(UErrorCode& status) && { +MeasureUnit MeasureUnitImpl::build(UErrorCode &status) && { this->serialize(status); return MeasureUnit(std::move(*this)); } -MeasureUnit MeasureUnit::forIdentifier(StringPiece identifier, UErrorCode& status) { +MeasureUnit MeasureUnit::forIdentifier(StringPiece identifier, UErrorCode &status) { return Parser::from(identifier, status).parse(status).build(status); } -UMeasureUnitComplexity MeasureUnit::getComplexity(UErrorCode& status) const { +UMeasureUnitComplexity MeasureUnit::getComplexity(UErrorCode &status) const { MeasureUnitImpl temp; return MeasureUnitImpl::forMeasureUnit(*this, temp, status).complexity; } -UMeasurePrefix MeasureUnit::getPrefix(UErrorCode& status) const { +UMeasurePrefix MeasureUnit::getPrefix(UErrorCode &status) const { return SingleUnitImpl::forMeasureUnit(*this, status).unitPrefix; } -MeasureUnit MeasureUnit::withPrefix(UMeasurePrefix prefix, UErrorCode& status) const UPRV_NO_SANITIZE_UNDEFINED { +MeasureUnit MeasureUnit::withPrefix(UMeasurePrefix prefix, + UErrorCode &status) const UPRV_NO_SANITIZE_UNDEFINED { SingleUnitImpl singleUnit = SingleUnitImpl::forMeasureUnit(*this, status); singleUnit.unitPrefix = prefix; return singleUnit.build(status); } +uint64_t MeasureUnit::getConstantDenominator(UErrorCode &status) const { + auto complexity = this->getComplexity(status); + if (U_FAILURE(status)) { + return 0; + } + + if (complexity != UMEASURE_UNIT_SINGLE && complexity != UMEASURE_UNIT_COMPOUND) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return 0; + } + + if (this->fImpl == nullptr) { + return 0; + } + + return this->fImpl->constantDenominator; +} + +MeasureUnit MeasureUnit::withConstantDenominator(uint64_t denominator, UErrorCode &status) const { + // To match the behavior of the Java API, we do not allow a constant denominator + // bigger than LONG_MAX. + if (denominator > LONG_MAX) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return {}; + } + + auto complexity = this->getComplexity(status); + if (U_FAILURE(status)) { + return {}; + } + if (complexity != UMEASURE_UNIT_SINGLE && complexity != UMEASURE_UNIT_COMPOUND) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return {}; + } + + MeasureUnitImpl impl = MeasureUnitImpl::forMeasureUnitMaybeCopy(*this, status); + if (U_FAILURE(status)) { + return {}; + } + + impl.constantDenominator = denominator; + impl.complexity = (impl.singleUnits.length() < 2 && denominator == 0) ? UMEASURE_UNIT_SINGLE + : UMEASURE_UNIT_COMPOUND; + return std::move(impl).build(status); +} + int32_t MeasureUnit::getDimensionality(UErrorCode& status) const { SingleUnitImpl singleUnit = SingleUnitImpl::forMeasureUnit(*this, status); if (U_FAILURE(status)) { return 0; } @@ -1222,6 +1477,11 @@ MeasureUnit MeasureUnit::withDimensionality(int32_t dimensionality, UErrorCode& MeasureUnit MeasureUnit::reciprocal(UErrorCode& status) const { MeasureUnitImpl impl = MeasureUnitImpl::forMeasureUnitMaybeCopy(*this, status); + // The reciprocal of a unit that has a constant denominator is not allowed. + if (impl.constantDenominator != 0) { + status = U_ILLEGAL_ARGUMENT_ERROR; + return {}; + } impl.takeReciprocal(status); return std::move(impl).build(status); } @@ -1237,9 +1497,25 @@ MeasureUnit MeasureUnit::product(const MeasureUnit& other, UErrorCode& status) c for (int32_t i = 0; i < otherImpl.singleUnits.length(); i++) { impl.appendSingleUnit(*otherImpl.singleUnits[i], status); } - if (impl.singleUnits.length() > 1) { + + uint64_t currentConstatDenominator = this->getConstantDenominator(status); + uint64_t otherConstantDenominator = other.getConstantDenominator(status); + + // TODO: we can also multiply the constant denominators instead of returning an error. + if (currentConstatDenominator != 0 && otherConstantDenominator != 0) { + // There is only `one` constant denominator in a compound unit. + // Therefore, we Cannot multiply units that both of them have a constant denominator + status = U_ILLEGAL_ARGUMENT_ERROR; + return {}; + } + + // Because either one of the constant denominators is zero, we can use the maximum of them. + impl.constantDenominator = uprv_max(currentConstatDenominator, otherConstantDenominator); + + if (impl.singleUnits.length() > 1 || impl.constantDenominator > 0) { impl.complexity = UMEASURE_UNIT_COMPOUND; } + return std::move(impl).build(status); } diff --git a/contrib/libs/icu/i18n/measunit_impl.h b/contrib/libs/icu/i18n/measunit_impl.h index f6a8f90dc94f..db31435944c2 100644 --- a/contrib/libs/icu/i18n/measunit_impl.h +++ b/contrib/libs/icu/i18n/measunit_impl.h @@ -328,6 +328,14 @@ class U_I18N_API MeasureUnitImpl : public UMemory { */ CharString identifier; + /** + * Represents the unit constant denominator. + * + * NOTE: + * if set to 0, it means that the constant is not set. + */ + uint64_t constantDenominator = 0; + // For calling serialize // TODO(icu-units#147): revisit serialization friend class number::impl::LongNameHandler; diff --git a/contrib/libs/icu/i18n/messageformat2.cpp b/contrib/libs/icu/i18n/messageformat2.cpp index 73f7fa45e69f..50d87422b64c 100644 --- a/contrib/libs/icu/i18n/messageformat2.cpp +++ b/contrib/libs/icu/i18n/messageformat2.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -11,8 +13,10 @@ #include "unicode/messageformat2_data_model.h" #include "unicode/messageformat2_formattable.h" #include "unicode/messageformat2.h" +#include "unicode/normalizer2.h" #include "unicode/unistr.h" #include "messageformat2_allocation.h" +#include "messageformat2_checker.h" #include "messageformat2_evaluation.h" #include "messageformat2_macros.h" @@ -37,7 +41,7 @@ static Formattable evalLiteral(const Literal& lit) { // The fallback for a variable name is itself. UnicodeString str(DOLLAR); str += var; - const Formattable* val = context.getGlobal(var, errorCode); + const Formattable* val = context.getGlobal(*this, var, errorCode); if (U_SUCCESS(errorCode)) { return (FormattedPlaceholder(*val, str)); } @@ -51,16 +55,16 @@ static Formattable evalLiteral(const Literal& lit) { return FormattedPlaceholder(evalLiteral(lit), lit.quoted()); } -[[nodiscard]] FormattedPlaceholder MessageFormatter::formatOperand(const Environment& env, - const Operand& rand, - MessageContext& context, - UErrorCode &status) const { +[[nodiscard]] InternalValue* MessageFormatter::formatOperand(const Environment& env, + const Operand& rand, + MessageContext& context, + UErrorCode &status) const { if (U_FAILURE(status)) { return {}; } if (rand.isNull()) { - return FormattedPlaceholder(); + return create(InternalValue(FormattedPlaceholder()), status); } if (rand.isVariable()) { // Check if it's local or global @@ -71,15 +75,19 @@ static Formattable evalLiteral(const Literal& lit) { // Eager vs. lazy evaluation is an open issue: // see https://github.com/unicode-org/message-format-wg/issues/299 + // NFC-normalize the variable name. See + // https://github.com/unicode-org/message-format-wg/blob/main/spec/syntax.md#names-and-identifiers + const VariableName normalized = normalizeNFC(var); + // Look up the variable in the environment - if (env.has(var)) { + if (env.has(normalized)) { // `var` is a local -- look it up - const Closure& rhs = env.lookup(var); + const Closure& rhs = env.lookup(normalized); // Format the expression using the environment from the closure return formatExpression(rhs.getEnv(), rhs.getExpr(), context, status); } // Variable wasn't found in locals -- check if it's global - FormattedPlaceholder result = evalArgument(var, context, status); + FormattedPlaceholder result = evalArgument(normalized, context, status); if (status == U_ILLEGAL_ARGUMENT_ERROR) { status = U_ZERO_ERROR; // Unbound variable -- set a resolution error @@ -88,12 +96,12 @@ static Formattable evalLiteral(const Literal& lit) { // https://github.com/unicode-org/message-format-wg/blob/main/spec/formatting.md#fallback-resolution UnicodeString str(DOLLAR); str += var; - return FormattedPlaceholder(str); + return create(InternalValue(FormattedPlaceholder(str)), status); } - return result; + return create(InternalValue(std::move(result)), status); } else { U_ASSERT(rand.isLiteral()); - return formatLiteral(rand.asLiteral()); + return create(InternalValue(formatLiteral(rand.asLiteral())), status); } } @@ -114,28 +122,32 @@ FunctionOptions MessageFormatter::resolveOptions(const Environment& env, const O // Options are fully evaluated before calling the function // Format the operand - FormattedPlaceholder rhsVal = formatOperand(env, v, context, status); + LocalPointer rhsVal(formatOperand(env, v, context, status)); if (U_FAILURE(status)) { return {}; } - if (!rhsVal.isFallback()) { - resolvedOpt.adoptInstead(create(ResolvedFunctionOption(k, rhsVal.asFormattable()), status)); - if (U_FAILURE(status)) { - return {}; - } - optionsVector->adoptElement(resolvedOpt.orphan(), status); + // Note: this means option values are "eagerly" evaluated. + // Currently, options don't have options. This will be addressed by the + // full FormattedPlaceholder redesign. + FormattedPlaceholder optValue = rhsVal->forceFormatting(context.getErrors(), status); + resolvedOpt.adoptInstead(create + (ResolvedFunctionOption(k, + optValue.asFormattable()), + status)); + if (U_FAILURE(status)) { + return {}; } + optionsVector->adoptElement(resolvedOpt.orphan(), status); } - return FunctionOptions(std::move(*optionsVector), status); } // Overload that dispatches on argument type. Syntax doesn't provide for options in this case. -[[nodiscard]] FormattedPlaceholder MessageFormatter::evalFormatterCall(FormattedPlaceholder&& argument, - MessageContext& context, - UErrorCode& status) const { +[[nodiscard]] InternalValue* MessageFormatter::evalFunctionCall(FormattedPlaceholder&& argument, + MessageContext& context, + UErrorCode& status) const { if (U_FAILURE(status)) { - return {}; + return nullptr; } // These cases should have been checked for already @@ -153,11 +165,11 @@ FunctionOptions MessageFormatter::resolveOptions(const Environment& env, const O // No formatter for this type -- follow default behavior break; } - return evalFormatterCall(functionName, - std::move(argument), - FunctionOptions(), - context, - status); + return evalFunctionCall(functionName, + create(std::move(argument), status), + FunctionOptions(), + context, + status); } default: { // TODO: The array case isn't handled yet; not sure whether it's desirable @@ -167,104 +179,76 @@ FunctionOptions MessageFormatter::resolveOptions(const Environment& env, const O } // No formatter for this type, or it's a primitive type (which will be formatted later) // -- just return the argument itself - return std::move(argument); + return create(std::move(argument), status); } // Overload that dispatches on function name -[[nodiscard]] FormattedPlaceholder MessageFormatter::evalFormatterCall(const FunctionName& functionName, - FormattedPlaceholder&& argument, - FunctionOptions&& options, - MessageContext& context, - UErrorCode& status) const { +// Adopts `arg` +[[nodiscard]] InternalValue* MessageFormatter::evalFunctionCall(const FunctionName& functionName, + InternalValue* arg_, + FunctionOptions&& options, + MessageContext& context, + UErrorCode& status) const { if (U_FAILURE(status)) { return {}; } - DynamicErrors& errs = context.getErrors(); - - UnicodeString fallback(COLON); - fallback += functionName; - if (!argument.isNullOperand()) { - fallback = argument.fallback; - } + LocalPointer arg(arg_); + // Look up the formatter or selector + LocalPointer formatterImpl(nullptr); + LocalPointer selectorImpl(nullptr); if (isFormatter(functionName)) { - LocalPointer formatterImpl(getFormatter(functionName, status)); - if (U_FAILURE(status)) { - if (status == U_MF_FORMATTING_ERROR) { - errs.setFormattingError(functionName, status); - status = U_ZERO_ERROR; - return {}; - } - if (status == U_MF_UNKNOWN_FUNCTION_ERROR) { - errs.setUnknownFunction(functionName, status); - status = U_ZERO_ERROR; - return {}; - } - // Other errors are non-recoverable - return {}; - } - U_ASSERT(formatterImpl != nullptr); - - UErrorCode savedStatus = status; - FormattedPlaceholder result = formatterImpl->format(std::move(argument), std::move(options), status); - // Update errors - if (savedStatus != status) { - if (U_FAILURE(status)) { - if (status == U_MF_OPERAND_MISMATCH_ERROR) { - status = U_ZERO_ERROR; - errs.setOperandMismatchError(functionName, status); - } else { - status = U_ZERO_ERROR; - // Convey any error generated by the formatter - // as a formatting error, except for operand mismatch errors - errs.setFormattingError(functionName, status); - } - return FormattedPlaceholder(fallback); - } else { - // Ignore warnings - status = savedStatus; - } - } - // Ignore the output if any errors occurred - if (errs.hasFormattingError()) { - return FormattedPlaceholder(fallback); - } - return result; + formatterImpl.adoptInstead(getFormatter(functionName, status)); + U_ASSERT(U_SUCCESS(status)); } - // No formatter with this name -- set error if (isSelector(functionName)) { - errs.setFormattingError(functionName, status); - } else { - errs.setUnknownFunction(functionName, status); + selectorImpl.adoptInstead(getSelector(context, functionName, status)); + U_ASSERT(U_SUCCESS(status)); + } + if (formatterImpl == nullptr && selectorImpl == nullptr) { + // Unknown function error + context.getErrors().setUnknownFunction(functionName, status); + + if (arg->hasNullOperand()) { + // Non-selector used as selector; an error would have been recorded earlier + UnicodeString fallback(COLON); + fallback += functionName; + return new InternalValue(FormattedPlaceholder(fallback)); + } else { + return new InternalValue(FormattedPlaceholder(arg->getFallback())); + } } - return FormattedPlaceholder(fallback); + return new InternalValue(arg.orphan(), + std::move(options), + functionName, + formatterImpl.isValid() ? formatterImpl.orphan() : nullptr, + selectorImpl.isValid() ? selectorImpl.orphan() : nullptr); } // Formats an expression using `globalEnv` for the values of variables -[[nodiscard]] FormattedPlaceholder MessageFormatter::formatExpression(const Environment& globalEnv, - const Expression& expr, - MessageContext& context, - UErrorCode &status) const { +[[nodiscard]] InternalValue* MessageFormatter::formatExpression(const Environment& globalEnv, + const Expression& expr, + MessageContext& context, + UErrorCode &status) const { if (U_FAILURE(status)) { return {}; } const Operand& rand = expr.getOperand(); // Format the operand (formatOperand handles the case of a null operand) - FormattedPlaceholder randVal = formatOperand(globalEnv, rand, context, status); + LocalPointer randVal(formatOperand(globalEnv, rand, context, status)); - // Don't call the function on error values - if (randVal.isFallback()) { - return randVal; - } + FormattedPlaceholder maybeRand = randVal->takeArgument(status); - if (!expr.isFunctionCall()) { + if (!expr.isFunctionCall() && U_SUCCESS(status)) { // Dispatch based on type of `randVal` - return evalFormatterCall(std::move(randVal), - context, - status); - } else { + if (maybeRand.isFallback()) { + return randVal.orphan(); + } + return evalFunctionCall(std::move(maybeRand), context, status); + } else if (expr.isFunctionCall()) { + status = U_ZERO_ERROR; const Operator* rator = expr.getOperator(status); U_ASSERT(U_SUCCESS(status)); const FunctionName& functionName = rator->getFunctionName(); @@ -273,19 +257,14 @@ FunctionOptions MessageFormatter::resolveOptions(const Environment& env, const O FunctionOptions resolvedOptions = resolveOptions(globalEnv, options, context, status); // Call the formatter function - // The fallback for a nullary function call is the function name - UnicodeString fallback; - if (rand.isNull()) { - fallback = UnicodeString(COLON); - fallback += functionName; - } else { - fallback = randVal.fallback; - } - return evalFormatterCall(functionName, - std::move(randVal), - std::move(resolvedOptions), - context, - status); + return evalFunctionCall(functionName, + randVal.orphan(), + std::move(resolvedOptions), + context, + status); + } else { + status = U_ZERO_ERROR; + return randVal.orphan(); } } @@ -301,11 +280,13 @@ void MessageFormatter::formatPattern(MessageContext& context, const Environment& // Markup is ignored } else { // Format the expression - FormattedPlaceholder partVal = formatExpression(globalEnv, part.contents(), context, status); - // Force full evaluation, e.g. applying default formatters to + LocalPointer partVal( + formatExpression(globalEnv, part.contents(), context, status)); + FormattedPlaceholder partResult = partVal->forceFormatting(context.getErrors(), + status); + // Force full evaluation, e.g. applying default formatters to // unformatted input (or formatting numbers as strings) - UnicodeString partResult = partVal.formatToString(locale, status); - result += partResult; + result += partResult.formatToString(locale, status); // Handle formatting errors. `formatToString()` can't take a context and thus can't // register an error directly if (status == U_MF_FORMATTING_ERROR) { @@ -328,14 +309,14 @@ void MessageFormatter::resolveSelectors(MessageContext& context, const Environme CHECK_ERROR(status); U_ASSERT(!dataModel.hasPattern()); - const Expression* selectors = dataModel.getSelectorsInternal(); + const VariableName* selectors = dataModel.getSelectorsInternal(); // 1. Let res be a new empty list of resolved values that support selection. // (Implicit, since `res` is an out-parameter) // 2. For each expression exp of the message's selectors for (int32_t i = 0; i < dataModel.numSelectors(); i++) { // 2i. Let rv be the resolved value of exp. - ResolvedSelector rv = formatSelectorExpression(env, selectors[i], context, status); - if (rv.hasSelector()) { + LocalPointer rv(formatOperand(env, Operand(selectors[i]), context, status)); + if (rv->canSelect()) { // 2ii. If selection is supported for rv: // (True if this code has been reached) } else { @@ -344,17 +325,17 @@ void MessageFormatter::resolveSelectors(MessageContext& context, const Environme // Append nomatch as the last element of the list res. // Emit a Selection Error. // (Note: in this case, rv, being a fallback, serves as `nomatch`) - #if U_DEBUG - const DynamicErrors& err = context.getErrors(); - U_ASSERT(err.hasError()); - U_ASSERT(rv.argument().isFallback()); - #endif + DynamicErrors& err = context.getErrors(); + err.setSelectorError(rv->getFunctionName(), status); + rv.adoptInstead(new InternalValue(FormattedPlaceholder(rv->getFallback()))); + if (!rv.isValid()) { + status = U_MEMORY_ALLOCATION_ERROR; + return; + } } // 2ii(a). Append rv as the last element of the list res. // (Also fulfills 2iii) - LocalPointer v(create(std::move(rv), status)); - CHECK_ERROR(status); - res.adoptElement(v.orphan(), status); + res.adoptElement(rv.orphan(), status); } } @@ -362,18 +343,17 @@ void MessageFormatter::resolveSelectors(MessageContext& context, const Environme // `keys` and `matches` are vectors of strings void MessageFormatter::matchSelectorKeys(const UVector& keys, MessageContext& context, - ResolvedSelector&& rv, + InternalValue* rv, // Does not adopt `rv` UVector& keysOut, UErrorCode& status) const { CHECK_ERROR(status); - if (!rv.hasSelector()) { + if (U_FAILURE(status)) { // Return an empty list of matches + status = U_ZERO_ERROR; return; } - auto selectorImpl = rv.getSelector(); - U_ASSERT(selectorImpl != nullptr); UErrorCode savedStatus = status; // Convert `keys` to an array @@ -400,15 +380,17 @@ void MessageFormatter::matchSelectorKeys(const UVector& keys, int32_t prefsLen = 0; // Call the selector - selectorImpl->selectKey(rv.takeArgument(), rv.takeOptions(), - adoptedKeys.getAlias(), keysLen, adoptedPrefs.getAlias(), prefsLen, - status); + FunctionName name = rv->getFunctionName(); + rv->forceSelection(context.getErrors(), + adoptedKeys.getAlias(), keysLen, + adoptedPrefs.getAlias(), prefsLen, + status); // Update errors if (savedStatus != status) { if (U_FAILURE(status)) { status = U_ZERO_ERROR; - context.getErrors().setSelectorError(rv.getSelectorName(), status); + context.getErrors().setSelectorError(name, status); } else { // Ignore warnings status = savedStatus; @@ -461,8 +443,8 @@ void MessageFormatter::resolvePreferences(MessageContext& context, UVector& res, if (!key.isWildcard()) { // 2ii(b)(a) Assert that key is a literal. // (Not needed) - // 2ii(b)(b) Let `ks` be the resolved value of `key`. - ks = key.asLiteral().unquoted(); + // 2ii(b)(b) Let `ks` be the resolved value of `key` in Unicode Normalization Form C. + ks = normalizeNFC(key.asLiteral().unquoted()); // 2ii(b)(c) Append `ks` as the last element of the list `keys`. ksP.adoptInstead(create(std::move(ks), status)); CHECK_ERROR(status); @@ -471,7 +453,7 @@ void MessageFormatter::resolvePreferences(MessageContext& context, UVector& res, } // 2iii. Let `rv` be the resolved value at index `i` of `res`. U_ASSERT(i < res.size()); - ResolvedSelector rv = std::move(*(static_cast(res[i]))); + InternalValue* rv = static_cast(res[i]); // 2iv. Let matches be the result of calling the method MatchSelectorKeys(rv, keys) LocalPointer matches(createUVector(status)); matchSelectorKeys(*keys, context, std::move(rv), *matches, status); @@ -523,7 +505,7 @@ void MessageFormatter::filterVariants(const UVector& pref, UVector& vars, UError // 2i(c). Assert that `key` is a literal. // (Not needed) // 2i(d). Let `ks` be the resolved value of `key`. - UnicodeString ks = key.asLiteral().unquoted(); + UnicodeString ks = normalizeNFC(key.asLiteral().unquoted()); // 2i(e). Let `matches` be the list of strings at index `i` of `pref`. const UVector& matches = *(static_cast(pref[i])); // `matches` is a vector of strings // 2i(f). If `matches` includes `ks` @@ -585,7 +567,7 @@ void MessageFormatter::sortVariants(const UVector& pref, UVector& vars, UErrorCo // 5iii(c)(a). Assert that `key` is a literal. // (Not needed) // 5iii(c)(b). Let `ks` be the resolved value of `key`. - UnicodeString ks = key.asLiteral().unquoted(); + UnicodeString ks = normalizeNFC(key.asLiteral().unquoted()); // 5iii(c)(c) Let matchpref be the integer position of ks in `matches`. matchpref = vectorFind(matches, ks); U_ASSERT(matchpref >= 0); @@ -604,123 +586,13 @@ void MessageFormatter::sortVariants(const UVector& pref, UVector& vars, UErrorCo // 7. Select the pattern of `var` } - -// Evaluate the operand -ResolvedSelector MessageFormatter::resolveVariables(const Environment& env, const Operand& rand, MessageContext& context, UErrorCode &status) const { - if (U_FAILURE(status)) { - return {}; - } - - if (rand.isNull()) { - return ResolvedSelector(FormattedPlaceholder()); - } - - if (rand.isLiteral()) { - return ResolvedSelector(formatLiteral(rand.asLiteral())); - } - - // Must be variable - const VariableName& var = rand.asVariable(); - // Resolve the variable - if (env.has(var)) { - const Closure& referent = env.lookup(var); - // Resolve the referent - return resolveVariables(referent.getEnv(), referent.getExpr(), context, status); - } - // Either this is a global var or an unbound var -- - // either way, it can't be bound to a function call. - // Check globals - FormattedPlaceholder val = evalArgument(var, context, status); - if (status == U_ILLEGAL_ARGUMENT_ERROR) { - status = U_ZERO_ERROR; - // Unresolved variable -- could be a previous warning. Nothing to resolve - U_ASSERT(context.getErrors().hasUnresolvedVariableError()); - return ResolvedSelector(FormattedPlaceholder(var)); - } - // Pass through other errors - return ResolvedSelector(std::move(val)); -} - -// Evaluate the expression except for not performing the top-level function call -// (which is expected to be a selector, but may not be, in error cases) -ResolvedSelector MessageFormatter::resolveVariables(const Environment& env, - const Expression& expr, - MessageContext& context, - UErrorCode &status) const { - if (U_FAILURE(status)) { - return {}; - } - - // Function call -- resolve the operand and options - if (expr.isFunctionCall()) { - const Operator* rator = expr.getOperator(status); - U_ASSERT(U_SUCCESS(status)); - // Already checked that rator is non-reserved - const FunctionName& selectorName = rator->getFunctionName(); - if (isSelector(selectorName)) { - auto selector = getSelector(context, selectorName, status); - if (U_SUCCESS(status)) { - FunctionOptions resolvedOptions = resolveOptions(env, rator->getOptionsInternal(), context, status); - // Operand may be the null argument, but resolveVariables() handles that - FormattedPlaceholder argument = formatOperand(env, expr.getOperand(), context, status); - return ResolvedSelector(selectorName, selector, std::move(resolvedOptions), std::move(argument)); - } - } else if (isFormatter(selectorName)) { - context.getErrors().setSelectorError(selectorName, status); - } else { - context.getErrors().setUnknownFunction(selectorName, status); - } - // Non-selector used as selector; an error would have been recorded earlier - UnicodeString fallback(COLON); - fallback += selectorName; - if (!expr.getOperand().isNull()) { - fallback = formatOperand(env, expr.getOperand(), context, status).fallback; - } - return ResolvedSelector(FormattedPlaceholder(fallback)); - } else { - // Might be a variable reference, so expand one more level of variable - return resolveVariables(env, expr.getOperand(), context, status); - } -} - -ResolvedSelector MessageFormatter::formatSelectorExpression(const Environment& globalEnv, const Expression& expr, MessageContext& context, UErrorCode &status) const { - if (U_FAILURE(status)) { - return {}; - } - - // Resolve expression to determine if it's a function call - ResolvedSelector exprResult = resolveVariables(globalEnv, expr, context, status); - - DynamicErrors& err = context.getErrors(); - - // If there is a selector, then `resolveVariables()` recorded it in the context - if (exprResult.hasSelector()) { - // Check if there was an error - if (exprResult.argument().isFallback()) { - // Use a null expression if it's a syntax or data model warning; - // create a valid (non-fallback) formatted placeholder from the - // fallback string otherwise - if (err.hasSyntaxError() || err.hasDataModelError()) { - return ResolvedSelector(FormattedPlaceholder()); // Null operand - } else { - return ResolvedSelector(exprResult.takeArgument()); - } - } - return exprResult; - } - - // No selector was found; error should already have been set - U_ASSERT(err.hasMissingSelectorAnnotationError() || err.hasUnknownFunctionError() || err.hasSelectorError()); - return ResolvedSelector(FormattedPlaceholder(exprResult.argument().fallback)); -} - void MessageFormatter::formatSelectors(MessageContext& context, const Environment& env, UErrorCode &status, UnicodeString& result) const { CHECK_ERROR(status); // See https://github.com/unicode-org/message-format-wg/blob/main/spec/formatting.md#pattern-selection // Resolve Selectors - // res is a vector of FormattedPlaceholders + // res is a vector of InternalValues LocalPointer res(createUVector(status)); CHECK_ERROR(status); resolveSelectors(context, env, status, *res); @@ -761,28 +633,35 @@ void MessageFormatter::formatSelectors(MessageContext& context, const Environmen UnicodeString MessageFormatter::formatToString(const MessageArguments& arguments, UErrorCode &status) { EMPTY_ON_ERROR(status); - // Create a new environment that will store closures for all local variables - Environment* env = Environment::create(status); // Create a new context with the given arguments and the `errors` structure MessageContext context(arguments, *errors, status); - - // Check for unresolved variable errors - checkDeclarations(context, env, status); - LocalPointer globalEnv(env); - UnicodeString result; - if (dataModel.hasPattern()) { - formatPattern(context, *globalEnv, dataModel.getPattern(), status, result); - } else { - // Check for errors/warnings -- if so, then the result of pattern selection is the fallback value - // See https://github.com/unicode-org/message-format-wg/blob/main/spec/formatting.md#pattern-selection - const DynamicErrors& err = context.getErrors(); - if (err.hasSyntaxError() || err.hasDataModelError()) { - result += REPLACEMENT; + + if (!(errors->hasSyntaxError() || errors->hasDataModelError())) { + // Create a new environment that will store closures for all local variables + // Check for unresolved variable errors + // checkDeclarations needs a reference to the pointer to the environment + // since it uses its `env` argument as an out-parameter. So it needs to be + // temporarily not a LocalPointer... + Environment* env(Environment::create(status)); + checkDeclarations(context, env, status); + // ...and then it's adopted to avoid leaks + LocalPointer globalEnv(env); + + if (dataModel.hasPattern()) { + formatPattern(context, *globalEnv, dataModel.getPattern(), status, result); } else { - formatSelectors(context, *globalEnv, status, result); + // Check for errors/warnings -- if so, then the result of pattern selection is the fallback value + // See https://github.com/unicode-org/message-format-wg/blob/main/spec/formatting.md#pattern-selection + const DynamicErrors& err = context.getErrors(); + if (err.hasSyntaxError() || err.hasDataModelError()) { + result += REPLACEMENT; + } else { + formatSelectors(context, *globalEnv, status, result); + } } } + // Update status according to all errors seen while formatting if (signalErrors) { context.checkErrors(status); @@ -813,12 +692,14 @@ void MessageFormatter::check(MessageContext& context, const Environment& localEn // Check that variable is in scope const VariableName& var = rand.asVariable(); + UnicodeString normalized = normalizeNFC(var); + // Check local scope - if (localEnv.has(var)) { + if (localEnv.has(normalized)) { return; } // Check global scope - context.getGlobal(var, status); + context.getGlobal(*this, normalized, status); if (status == U_ILLEGAL_ARGUMENT_ERROR) { status = U_ZERO_ERROR; context.getErrors().setUnresolvedVariable(var, status); @@ -855,7 +736,10 @@ void MessageFormatter::checkDeclarations(MessageContext& context, Environment*& // memoizing the value of localEnv up to this point // Add the LHS to the environment for checking the next declaration - env = Environment::create(decl.getVariable(), Closure(rhs, *env), env, status); + env = Environment::create(normalizeNFC(decl.getVariable()), + Closure(rhs, *env), + env, + status); CHECK_ERROR(status); } } @@ -866,3 +750,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_allocation.h b/contrib/libs/icu/i18n/messageformat2_allocation.h index 7be27e222520..5b06d0851296 100644 --- a/contrib/libs/icu/i18n/messageformat2_allocation.h +++ b/contrib/libs/icu/i18n/messageformat2_allocation.h @@ -10,6 +10,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -139,6 +141,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_UTILS_H diff --git a/contrib/libs/icu/i18n/messageformat2_arguments.cpp b/contrib/libs/icu/i18n/messageformat2_arguments.cpp index ded3f4dda160..c43c600a2f40 100644 --- a/contrib/libs/icu/i18n/messageformat2_arguments.cpp +++ b/contrib/libs/icu/i18n/messageformat2_arguments.cpp @@ -3,12 +3,16 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 +#include "unicode/messageformat2.h" #include "unicode/messageformat2_arguments.h" #include "unicode/messageformat2_data_model_names.h" +#include "messageformat2_evaluation.h" #include "uvector.h" // U_ASSERT U_NAMESPACE_BEGIN @@ -22,11 +26,15 @@ namespace message2 { using Arguments = MessageArguments; - const Formattable* Arguments::getArgument(const VariableName& arg, UErrorCode& errorCode) const { + const Formattable* Arguments::getArgument(const MessageFormatter& context, + const VariableName& arg, + UErrorCode& errorCode) const { if (U_SUCCESS(errorCode)) { U_ASSERT(argsLen == 0 || arguments.isValid()); for (int32_t i = 0; i < argsLen; i++) { - if (argumentNames[i] == arg) { + UnicodeString normalized = context.normalizeNFC(argumentNames[i]); + // arg already assumed to be normalized + if (normalized == arg) { return &arguments[i]; } } @@ -57,3 +65,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_checker.cpp b/contrib/libs/icu/i18n/messageformat2_checker.cpp index bdc5c383b6e8..46b25ff389b5 100644 --- a/contrib/libs/icu/i18n/messageformat2_checker.cpp +++ b/contrib/libs/icu/i18n/messageformat2_checker.cpp @@ -3,12 +3,16 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 +#include "unicode/messageformat2.h" #include "messageformat2_allocation.h" #include "messageformat2_checker.h" +#include "messageformat2_evaluation.h" #include "messageformat2_macros.h" #include "uvector.h" // U_ASSERT @@ -104,6 +108,14 @@ TypeEnvironment::~TypeEnvironment() {} // --------------------- +Key Checker::normalizeNFC(const Key& k) const { + if (k.isWildcard()) { + return k; + } + return Key(Literal(k.asLiteral().isQuoted(), + context.normalizeNFC(k.asLiteral().unquoted()))); +} + static bool areDefaultKeys(const Key* keys, int32_t len) { U_ASSERT(len > 0); for (int32_t i = 0; i < len; i++) { @@ -185,7 +197,7 @@ void Checker::checkVariants(UErrorCode& status) { // This variant was already checked, // so we know keys1.len == len for (int32_t kk = 0; kk < len; kk++) { - if (!(keys[kk] == keys1[kk])) { + if (!(normalizeNFC(keys[kk]) == normalizeNFC(keys1[kk]))) { allEqual = false; break; } @@ -205,18 +217,14 @@ void Checker::checkVariants(UErrorCode& status) { } } -void Checker::requireAnnotated(const TypeEnvironment& t, const Expression& selectorExpr, UErrorCode& status) { +void Checker::requireAnnotated(const TypeEnvironment& t, + const VariableName& selectorVar, + UErrorCode& status) { CHECK_ERROR(status); - if (selectorExpr.isFunctionCall()) { + if (t.get(selectorVar) == TypeEnvironment::Type::Annotated) { return; // No error } - const Operand& rand = selectorExpr.getOperand(); - if (rand.isVariable()) { - if (t.get(rand.asVariable()) == TypeEnvironment::Type::Annotated) { - return; // No error - } - } // If this code is reached, an error was detected errors.addError(StaticErrorType::MissingSelectorAnnotation, status); } @@ -226,7 +234,7 @@ void Checker::checkSelectors(const TypeEnvironment& t, UErrorCode& status) { // Check each selector; if it's not annotated, emit a // "missing selector annotation" error - const Expression* selectors = dataModel.getSelectorsInternal(); + const VariableName* selectors = dataModel.getSelectorsInternal(); for (int32_t i = 0; i < dataModel.numSelectors(); i++) { requireAnnotated(t, selectors[i], status); } @@ -312,3 +320,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_checker.h b/contrib/libs/icu/i18n/messageformat2_checker.h index 4bb0498efb99..122f668f4b7e 100644 --- a/contrib/libs/icu/i18n/messageformat2_checker.h +++ b/contrib/libs/icu/i18n/messageformat2_checker.h @@ -10,6 +10,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -56,15 +58,20 @@ namespace message2 { // an explicit declaration }; // class TypeEnvironment + class MessageFormatter; + // Checks a data model for semantic errors // (Errors are defined in https://github.com/unicode-org/message-format-wg/blob/main/spec/formatting.md ) class Checker { public: void check(UErrorCode&); - Checker(const MFDataModel& m, StaticErrors& e) : dataModel(m), errors(e) {} + Checker(const MFDataModel& d, StaticErrors& e, const MessageFormatter& mf) + : dataModel(d), errors(e), context(mf) {} private: - void requireAnnotated(const TypeEnvironment&, const Expression&, UErrorCode&); + Key normalizeNFC(const Key&) const; + + void requireAnnotated(const TypeEnvironment&, const VariableName&, UErrorCode&); void addFreeVars(TypeEnvironment& t, const Operand&, UErrorCode&); void addFreeVars(TypeEnvironment& t, const Operator&, UErrorCode&); void addFreeVars(TypeEnvironment& t, const OptionMap&, UErrorCode&); @@ -78,6 +85,9 @@ namespace message2 { void check(const Pattern&); const MFDataModel& dataModel; StaticErrors& errors; + + // Used for NFC normalization + const MessageFormatter& context; }; // class Checker } // namespace message2 @@ -88,6 +98,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT_CHECKER_H diff --git a/contrib/libs/icu/i18n/messageformat2_data_model.cpp b/contrib/libs/icu/i18n/messageformat2_data_model.cpp index 3fe5f65b5323..3406080695c6 100644 --- a/contrib/libs/icu/i18n/messageformat2_data_model.cpp +++ b/contrib/libs/icu/i18n/messageformat2_data_model.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -691,9 +693,9 @@ Matcher::Matcher(const Matcher& other) { numSelectors = other.numSelectors; numVariants = other.numVariants; UErrorCode localErrorCode = U_ZERO_ERROR; - selectors.adoptInstead(copyArray(other.selectors.getAlias(), - numSelectors, - localErrorCode)); + selectors.adoptInstead(copyArray(other.selectors.getAlias(), + numSelectors, + localErrorCode)); variants.adoptInstead(copyArray(other.variants.getAlias(), numVariants, localErrorCode)); @@ -702,7 +704,7 @@ Matcher::Matcher(const Matcher& other) { } } -Matcher::Matcher(Expression* ss, int32_t ns, Variant* vs, int32_t nv) +Matcher::Matcher(VariableName* ss, int32_t ns, Variant* vs, int32_t nv) : selectors(ss), numSelectors(ns), variants(vs), numVariants(nv) {} Matcher::~Matcher() {} @@ -724,7 +726,7 @@ const Binding* MFDataModel::getLocalVariablesInternal() const { return bindings.getAlias(); } -const Expression* MFDataModel::getSelectorsInternal() const { +const VariableName* MFDataModel::getSelectorsInternal() const { U_ASSERT(!bogus); U_ASSERT(!hasPattern()); return std::get_if(&body)->selectors.getAlias(); @@ -786,15 +788,13 @@ MFDataModel::Builder& MFDataModel::Builder::addBinding(Binding&& b, UErrorCode& return *this; } -/* - selector must be non-null -*/ -MFDataModel::Builder& MFDataModel::Builder::addSelector(Expression&& selector, UErrorCode& status) noexcept { +MFDataModel::Builder& MFDataModel::Builder::addSelector(VariableName&& selector, + UErrorCode& status) { THIS_ON_ERROR(status); buildSelectorsMessage(status); U_ASSERT(selectors != nullptr); - selectors->adoptElement(create(std::move(selector), status), status); + selectors->adoptElement(create(std::move(selector), status), status); return *this; } @@ -830,11 +830,11 @@ MFDataModel::MFDataModel(const MFDataModel& other) : body(Pattern()) { if (other.hasPattern()) { body = *std::get_if(&other.body); } else { - const Expression* otherSelectors = other.getSelectorsInternal(); + const VariableName* otherSelectors = other.getSelectorsInternal(); const Variant* otherVariants = other.getVariantsInternal(); int32_t numSelectors = other.numSelectors(); int32_t numVariants = other.numVariants(); - Expression* copiedSelectors = copyArray(otherSelectors, numSelectors, localErrorCode); + VariableName* copiedSelectors = copyArray(otherSelectors, numSelectors, localErrorCode); Variant* copiedVariants = copyArray(otherVariants, numVariants, localErrorCode); if (U_FAILURE(localErrorCode)) { bogus = true; @@ -863,7 +863,9 @@ MFDataModel::MFDataModel(const MFDataModel::Builder& builder, UErrorCode& errorC int32_t numVariants = builder.variants->size(); int32_t numSelectors = builder.selectors->size(); LocalArray variants(copyVectorToArray(*builder.variants, errorCode), errorCode); - LocalArray selectors(copyVectorToArray(*builder.selectors, errorCode), errorCode); + LocalArray selectors(copyVectorToArray(*builder.selectors, + errorCode), + errorCode); if (U_FAILURE(errorCode)) { bogus = true; return; @@ -918,3 +920,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_errors.cpp b/contrib/libs/icu/i18n/messageformat2_errors.cpp index 9d1d6bab81a1..5d3d938f0203 100644 --- a/contrib/libs/icu/i18n/messageformat2_errors.cpp +++ b/contrib/libs/icu/i18n/messageformat2_errors.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -290,3 +292,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_errors.h b/contrib/libs/icu/i18n/messageformat2_errors.h index f84aa7362837..085263e88b06 100644 --- a/contrib/libs/icu/i18n/messageformat2_errors.h +++ b/contrib/libs/icu/i18n/messageformat2_errors.h @@ -15,6 +15,8 @@ * \brief C++ API: Formats messages using the draft MessageFormat 2.0. */ +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -151,6 +153,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_ERRORS_H diff --git a/contrib/libs/icu/i18n/messageformat2_evaluation.cpp b/contrib/libs/icu/i18n/messageformat2_evaluation.cpp index 41e4c9a8020a..fcccbf5ae5e7 100644 --- a/contrib/libs/icu/i18n/messageformat2_evaluation.cpp +++ b/contrib/libs/icu/i18n/messageformat2_evaluation.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -89,34 +91,53 @@ FunctionOptions::FunctionOptions(FunctionOptions&& other) { FunctionOptions::~FunctionOptions() { if (options != nullptr) { delete[] options; + options = nullptr; } } -// ResolvedSelector -// ---------------- - -ResolvedSelector::ResolvedSelector(const FunctionName& fn, - Selector* sel, - FunctionOptions&& opts, - FormattedPlaceholder&& val) - : selectorName(fn), selector(sel), options(std::move(opts)), value(std::move(val)) { - U_ASSERT(sel != nullptr); + +static bool containsOption(const UVector& opts, const ResolvedFunctionOption& opt) { + for (int32_t i = 0; i < opts.size(); i++) { + if (static_cast(opts[i])->getName() + == opt.getName()) { + return true; + } + } + return false; } -ResolvedSelector::ResolvedSelector(FormattedPlaceholder&& val) : value(std::move(val)) {} +// Options in `this` take precedence +// `this` can't be used after mergeOptions is called +FunctionOptions FunctionOptions::mergeOptions(FunctionOptions&& other, + UErrorCode& status) { + UVector mergedOptions(status); + mergedOptions.setDeleter(uprv_deleteUObject); -ResolvedSelector& ResolvedSelector::operator=(ResolvedSelector&& other) noexcept { - selectorName = std::move(other.selectorName); - selector.adoptInstead(other.selector.orphan()); - options = std::move(other.options); - value = std::move(other.value); - return *this; -} + if (U_FAILURE(status)) { + return {}; + } -ResolvedSelector::ResolvedSelector(ResolvedSelector&& other) { - *this = std::move(other); -} + // Create a new vector consisting of the options from this `FunctionOptions` + for (int32_t i = 0; i < functionOptionsLen; i++) { + mergedOptions.adoptElement(create(std::move(options[i]), status), + status); + } -ResolvedSelector::~ResolvedSelector() {} + // Add each option from `other` that doesn't appear in this `FunctionOptions` + for (int i = 0; i < other.functionOptionsLen; i++) { + // Note: this is quadratic in the length of `options` + if (!containsOption(mergedOptions, other.options[i])) { + mergedOptions.adoptElement(create(std::move(other.options[i]), + status), + status); + } + } + + delete[] options; + options = nullptr; + functionOptionsLen = 0; + + return FunctionOptions(std::move(mergedOptions), status); +} // PrioritizedVariant // ------------------ @@ -190,18 +211,210 @@ PrioritizedVariant::~PrioritizedVariant() {} errors.checkErrors(status); } - const Formattable* MessageContext::getGlobal(const VariableName& v, UErrorCode& errorCode) const { - return arguments.getArgument(v, errorCode); + const Formattable* MessageContext::getGlobal(const MessageFormatter& context, + const VariableName& v, + UErrorCode& errorCode) const { + return arguments.getArgument(context, v, errorCode); } MessageContext::MessageContext(const MessageArguments& args, const StaticErrors& e, UErrorCode& status) : arguments(args), errors(e, status) {} + MessageContext::~MessageContext() {} + // InternalValue + // ------------- + + bool InternalValue::isFallback() const { + return std::holds_alternative(argument) + && std::get_if(&argument)->isFallback(); + } + + bool InternalValue::hasNullOperand() const { + return std::holds_alternative(argument) + && std::get_if(&argument)->isNullOperand(); + } + + FormattedPlaceholder InternalValue::takeArgument(UErrorCode& errorCode) { + if (U_FAILURE(errorCode)) { + return {}; + } + + if (std::holds_alternative(argument)) { + return std::move(*std::get_if(&argument)); + } + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + return {}; + } + + const UnicodeString& InternalValue::getFallback() const { + if (std::holds_alternative(argument)) { + return std::get_if(&argument)->getFallback(); + } + return (*std::get_if(&argument))->getFallback(); + } + + const Selector* InternalValue::getSelector(UErrorCode& errorCode) const { + if (U_FAILURE(errorCode)) { + return nullptr; + } + + if (selector == nullptr) { + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + } + return selector; + } + + InternalValue::InternalValue(FormattedPlaceholder&& arg) { + argument = std::move(arg); + selector = nullptr; + formatter = nullptr; + } + + InternalValue::InternalValue(InternalValue* operand, + FunctionOptions&& opts, + const FunctionName& functionName, + const Formatter* f, + const Selector* s) { + argument = operand; + options = std::move(opts); + name = functionName; + selector = s; + formatter = f; + U_ASSERT(selector != nullptr || formatter != nullptr); + } + + // `this` cannot be used after calling this method + void InternalValue::forceSelection(DynamicErrors& errs, + const UnicodeString* keys, + int32_t keysLen, + UnicodeString* prefs, + int32_t& prefsLen, + UErrorCode& errorCode) { + if (U_FAILURE(errorCode)) { + return; + } + + if (!canSelect()) { + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + return; + } + // Find the argument and complete set of options by traversing `argument` + FunctionOptions opts; + InternalValue* p = this; + FunctionName selectorName = name; + while (std::holds_alternative(p->argument)) { + if (p->name != selectorName) { + // Can only compose calls to the same selector + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + return; + } + // First argument to mergeOptions takes precedence + opts = opts.mergeOptions(std::move(p->options), errorCode); + if (U_FAILURE(errorCode)) { + return; + } + InternalValue* next = *std::get_if(&p->argument); + p = next; + } + FormattedPlaceholder arg = std::move(*std::get_if(&p->argument)); + + selector->selectKey(std::move(arg), std::move(opts), + keys, keysLen, + prefs, prefsLen, errorCode); + if (U_FAILURE(errorCode)) { + errorCode = U_ZERO_ERROR; + errs.setSelectorError(selectorName, errorCode); + } + } + + FormattedPlaceholder InternalValue::forceFormatting(DynamicErrors& errs, UErrorCode& errorCode) { + if (U_FAILURE(errorCode)) { + return {}; + } + + if (formatter == nullptr && selector == nullptr) { + U_ASSERT(std::holds_alternative(argument)); + return std::move(*std::get_if(&argument)); + } + if (formatter == nullptr) { + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + return {}; + } + + FormattedPlaceholder arg; + + if (std::holds_alternative(argument)) { + arg = std::move(*std::get_if(&argument)); + } else { + arg = (*std::get_if(&argument))->forceFormatting(errs, + errorCode); + } + + if (U_FAILURE(errorCode)) { + return {}; + } + + // The fallback for a nullary function call is the function name + UnicodeString fallback; + if (arg.isNullOperand()) { + fallback = u":"; + fallback += name; + } else { + fallback = arg.getFallback(); + } + + // Call the function with the argument + FormattedPlaceholder result = formatter->format(std::move(arg), std::move(options), errorCode); + if (U_FAILURE(errorCode)) { + if (errorCode == U_MF_OPERAND_MISMATCH_ERROR) { + errorCode = U_ZERO_ERROR; + errs.setOperandMismatchError(name, errorCode); + } else { + errorCode = U_ZERO_ERROR; + // Convey any error generated by the formatter + // as a formatting error, except for operand mismatch errors + errs.setFormattingError(name, errorCode); + } + } + // Ignore the output if any error occurred + if (errs.hasFormattingError()) { + return FormattedPlaceholder(fallback); + } + + return result; + } + + InternalValue& InternalValue::operator=(InternalValue&& other) noexcept { + argument = std::move(other.argument); + other.argument = nullptr; + options = std::move(other.options); + name = other.name; + selector = other.selector; + formatter = other.formatter; + other.selector = nullptr; + other.formatter = nullptr; + + return *this; + } + + InternalValue::~InternalValue() { + delete selector; + selector = nullptr; + delete formatter; + formatter = nullptr; + if (std::holds_alternative(argument)) { + delete *std::get_if(&argument); + argument = nullptr; + } + } + } // namespace message2 U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_evaluation.h b/contrib/libs/icu/i18n/messageformat2_evaluation.h index b8ae0242367d..fcb30bc3e638 100644 --- a/contrib/libs/icu/i18n/messageformat2_evaluation.h +++ b/contrib/libs/icu/i18n/messageformat2_evaluation.h @@ -14,6 +14,7 @@ * \file * \brief C++ API: Formats messages using the draft MessageFormat 2.0. */ +#if !UCONFIG_NO_NORMALIZATION #if !UCONFIG_NO_FORMATTING @@ -63,38 +64,6 @@ namespace message2 { return 1; } - // Encapsulates a value to be scrutinized by a `match` with its resolved - // options and the name of the selector - class ResolvedSelector : public UObject { - public: - ResolvedSelector() {} - ResolvedSelector(const FunctionName& fn, - Selector* selector, - FunctionOptions&& options, - FormattedPlaceholder&& value); - // Used either for errors, or when selector isn't yet known - explicit ResolvedSelector(FormattedPlaceholder&& value); - bool hasSelector() const { return selector.isValid(); } - const FormattedPlaceholder& argument() const { return value; } - FormattedPlaceholder&& takeArgument() { return std::move(value); } - const Selector* getSelector() { - U_ASSERT(selector.isValid()); - return selector.getAlias(); - } - FunctionOptions&& takeOptions() { - return std::move(options); - } - const FunctionName& getSelectorName() const { return selectorName; } - virtual ~ResolvedSelector(); - ResolvedSelector& operator=(ResolvedSelector&&) noexcept; - ResolvedSelector(ResolvedSelector&&); - private: - FunctionName selectorName; // For error reporting - LocalPointer selector; - FunctionOptions options; - FormattedPlaceholder value; - }; // class ResolvedSelector - // Closures and environments // ------------------------- @@ -174,11 +143,15 @@ namespace message2 { // The context contains all the information needed to process // an entire message: arguments, formatter cache, and error list + class MessageFormatter; + class MessageContext : public UMemory { public: MessageContext(const MessageArguments&, const StaticErrors&, UErrorCode&); - const Formattable* getGlobal(const VariableName&, UErrorCode&) const; + const Formattable* getGlobal(const MessageFormatter&, + const VariableName&, + UErrorCode&) const; // If any errors were set, update `status` accordingly void checkErrors(UErrorCode& status) const; @@ -191,8 +164,47 @@ namespace message2 { const MessageArguments& arguments; // External message arguments // Errors accumulated during parsing/formatting DynamicErrors errors; + }; // class MessageContext + // InternalValue + // ---------------- + + class InternalValue : public UObject { + public: + const FunctionName& getFunctionName() const { return name; } + bool canSelect() const { return selector != nullptr; } + const Selector* getSelector(UErrorCode&) const; + FormattedPlaceholder forceFormatting(DynamicErrors& errs, + UErrorCode& errorCode); + void forceSelection(DynamicErrors& errs, + const UnicodeString* keys, + int32_t keysLen, + UnicodeString* prefs, + int32_t& prefsLen, + UErrorCode& errorCode); + // Needs to be deep-copyable and movable + virtual ~InternalValue(); + InternalValue(FormattedPlaceholder&&); + // Formatter and selector may be null + InternalValue(InternalValue*, FunctionOptions&&, const FunctionName&, const Formatter*, + const Selector*); + const UnicodeString& getFallback() const; + bool isFallback() const; + bool hasNullOperand() const; + // Can't be used anymore after calling this + FormattedPlaceholder takeArgument(UErrorCode& errorCode); + InternalValue(InternalValue&& other) { *this = std::move(other); } + InternalValue& operator=(InternalValue&& other) noexcept; + private: + // InternalValue is owned (if present) + std::variant argument; + FunctionOptions options; + FunctionName name; + const Selector* selector; // May be null + const Formatter* formatter; // May be null, but one or the other should be non-null unless argument is a FormattedPlaceholder + }; // class InternalValue + } // namespace message2 U_NAMESPACE_END @@ -201,6 +213,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_EVALUATION_H diff --git a/contrib/libs/icu/i18n/messageformat2_formattable.cpp b/contrib/libs/icu/i18n/messageformat2_formattable.cpp index 3152ccb44fd8..4e2df49aeccf 100644 --- a/contrib/libs/icu/i18n/messageformat2_formattable.cpp +++ b/contrib/libs/icu/i18n/messageformat2_formattable.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -336,3 +338,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_formatter.cpp b/contrib/libs/icu/i18n/messageformat2_formatter.cpp index 8d17ae49b99a..ead6f62a7899 100644 --- a/contrib/libs/icu/i18n/messageformat2_formatter.cpp +++ b/contrib/libs/icu/i18n/messageformat2_formatter.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -43,7 +45,8 @@ namespace message2 { // Parse the pattern MFDataModel::Builder tree(errorCode); - Parser(pat, tree, *errors, normalizedInput).parse(parseError, errorCode); + Parser(pat, tree, *errors, normalizedInput, errorCode) + .parse(parseError, errorCode); // Fail on syntax errors if (errors->hasSyntaxError()) { @@ -116,6 +119,24 @@ namespace message2 { // MessageFormatter + // Returns the NFC-normalized version of s, returning s itself + // if it's already normalized. + UnicodeString MessageFormatter::normalizeNFC(const UnicodeString& s) const { + UErrorCode status = U_ZERO_ERROR; + // Check if string is already normalized + UNormalizationCheckResult result = nfcNormalizer->quickCheck(s, status); + // If so, return it + if (U_SUCCESS(status) && result == UNORM_YES) { + return s; + } + // Otherwise, normalize it + UnicodeString normalized = nfcNormalizer->normalize(s, status); + if (U_FAILURE(status)) { + return {}; + } + return normalized; + } + MessageFormatter::MessageFormatter(const MessageFormatter::Builder& builder, UErrorCode &success) : locale(builder.locale), customMFFunctionRegistry(builder.customMFFunctionRegistry) { CHECK_ERROR(success); @@ -132,9 +153,13 @@ namespace message2 { .adoptFormatter(FunctionName(UnicodeString("time")), time, success) .adoptFormatter(FunctionName(UnicodeString("number")), number, success) .adoptFormatter(FunctionName(UnicodeString("integer")), integer, success) + .adoptFormatter(FunctionName(UnicodeString("test:function")), new StandardFunctions::TestFormatFactory(), success) + .adoptFormatter(FunctionName(UnicodeString("test:format")), new StandardFunctions::TestFormatFactory(), success) .adoptSelector(FunctionName(UnicodeString("number")), new StandardFunctions::PluralFactory(UPLURAL_TYPE_CARDINAL), success) .adoptSelector(FunctionName(UnicodeString("integer")), new StandardFunctions::PluralFactory(StandardFunctions::PluralFactory::integer()), success) - .adoptSelector(FunctionName(UnicodeString("string")), new StandardFunctions::TextFactory(), success); + .adoptSelector(FunctionName(UnicodeString("string")), new StandardFunctions::TextFactory(), success) + .adoptSelector(FunctionName(UnicodeString("test:function")), new StandardFunctions::TestSelectFactory(), success) + .adoptSelector(FunctionName(UnicodeString("test:select")), new StandardFunctions::TestSelectFactory(), success); CHECK_ERROR(success); standardMFFunctionRegistry = standardFunctionsBuilder.build(); CHECK_ERROR(success); @@ -163,6 +188,8 @@ namespace message2 { errors = errorsNew.orphan(); } + nfcNormalizer = Normalizer2::getNFCInstance(success); + // Note: we currently evaluate variables lazily, // without memoization. This call is still necessary // to check out-of-scope uses of local variables in @@ -170,7 +197,7 @@ namespace message2 { // only be checked when arguments are known) // Check for resolution errors - Checker(dataModel, *errors).check(success); + Checker(dataModel, *errors, *this).check(success); } void MessageFormatter::cleanup() noexcept { @@ -191,6 +218,7 @@ namespace message2 { signalErrors = other.signalErrors; errors = other.errors; other.errors = nullptr; + nfcNormalizer = other.nfcNormalizer; return *this; } @@ -256,8 +284,11 @@ namespace message2 { return formatter; } - bool MessageFormatter::getDefaultFormatterNameByType(const UnicodeString& type, FunctionName& name) const { - U_ASSERT(hasCustomMFFunctionRegistry()); + bool MessageFormatter::getDefaultFormatterNameByType(const UnicodeString& type, + FunctionName& name) const { + if (!hasCustomMFFunctionRegistry()) { + return false; + } const MFFunctionRegistry& reg = getCustomMFFunctionRegistry(); return reg.getDefaultFormatterNameByType(type, name); } @@ -352,3 +383,5 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_MF2 */ #endif /* #if !UCONFIG_NO_FORMATTING */ + +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_function_registry.cpp b/contrib/libs/icu/i18n/messageformat2_function_registry.cpp index 17955760ecfb..e45fb3544ec5 100644 --- a/contrib/libs/icu/i18n/messageformat2_function_registry.cpp +++ b/contrib/libs/icu/i18n/messageformat2_function_registry.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -85,10 +87,11 @@ MFFunctionRegistry::Builder::Builder(UErrorCode& errorCode) { formattersByType = new Hashtable(); if (!(formatters != nullptr && selectors != nullptr && formattersByType != nullptr)) { errorCode = U_MEMORY_ALLOCATION_ERROR; + } else { + formatters->setValueDeleter(uprv_deleteUObject); + selectors->setValueDeleter(uprv_deleteUObject); + formattersByType->setValueDeleter(uprv_deleteUObject); } - formatters->setValueDeleter(uprv_deleteUObject); - selectors->setValueDeleter(uprv_deleteUObject); - formattersByType->setValueDeleter(uprv_deleteUObject); } MFFunctionRegistry::Builder::~Builder() { @@ -158,9 +161,13 @@ void MFFunctionRegistry::checkStandard() const { checkFormatter("time"); checkFormatter("number"); checkFormatter("integer"); + checkFormatter("test:function"); + checkFormatter("test:format"); checkSelector("number"); checkSelector("integer"); checkSelector("string"); + checkSelector("test:function"); + checkSelector("test:select"); } // Formatter/selector helpers @@ -424,14 +431,14 @@ static FormattedPlaceholder notANumber(const FormattedPlaceholder& input) { return FormattedPlaceholder(input, FormattedValue(UnicodeString("NaN"))); } -static double parseNumberLiteral(const FormattedPlaceholder& input, UErrorCode& errorCode) { +static double parseNumberLiteral(const Formattable& input, UErrorCode& errorCode) { if (U_FAILURE(errorCode)) { return {}; } // Copying string to avoid GCC dangling-reference warning // (although the reference is safe) - UnicodeString inputStr = input.asFormattable().getString(errorCode); + UnicodeString inputStr = input.getString(errorCode); // Precondition: `input`'s source Formattable has type string if (U_FAILURE(errorCode)) { return {}; @@ -463,8 +470,42 @@ static double parseNumberLiteral(const FormattedPlaceholder& input, UErrorCode& return result; } +static UChar32 digitToChar(int32_t val, UErrorCode errorCode) { + if (U_FAILURE(errorCode)) { + return '0'; + } + if (val < 0 || val > 9) { + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + } + switch(val) { + case 0: + return '0'; + case 1: + return '1'; + case 2: + return '2'; + case 3: + return '3'; + case 4: + return '4'; + case 5: + return '5'; + case 6: + return '6'; + case 7: + return '7'; + case 8: + return '8'; + case 9: + return '9'; + default: + errorCode = U_ILLEGAL_ARGUMENT_ERROR; + return '0'; + } +} + static FormattedPlaceholder tryParsingNumberLiteral(const number::LocalizedNumberFormatter& nf, const FormattedPlaceholder& input, UErrorCode& errorCode) { - double numberValue = parseNumberLiteral(input, errorCode); + double numberValue = parseNumberLiteral(input.asFormattable(), errorCode); if (U_FAILURE(errorCode)) { return notANumber(input); } @@ -1235,6 +1276,273 @@ void StandardFunctions::TextSelector::selectKey(FormattedPlaceholder&& toFormat, StandardFunctions::TextFactory::~TextFactory() {} StandardFunctions::TextSelector::~TextSelector() {} +// ------------ TestFormatFactory + +Formatter* StandardFunctions::TestFormatFactory::createFormatter(const Locale& locale, UErrorCode& errorCode) { + NULL_ON_ERROR(errorCode); + + // Results are not locale-dependent + (void) locale; + + Formatter* result = new TestFormat(); + if (result == nullptr) { + errorCode = U_MEMORY_ALLOCATION_ERROR; + } + return result; +} + +StandardFunctions::TestFormatFactory::~TestFormatFactory() {} +StandardFunctions::TestFormat::~TestFormat() {} + +// Extract numeric value from a Formattable or, if it's a string, +// parse it as a number according to the MF2 `number-literal` grammar production +double formattableToNumber(const Formattable& arg, UErrorCode& status) { + if (U_FAILURE(status)) { + return 0; + } + + double result = 0; + + switch (arg.getType()) { + case UFMT_DOUBLE: { + result = arg.getDouble(status); + U_ASSERT(U_SUCCESS(status)); + break; + } + case UFMT_LONG: { + result = (double) arg.getLong(status); + U_ASSERT(U_SUCCESS(status)); + break; + } + case UFMT_INT64: { + result = (double) arg.getInt64(status); + U_ASSERT(U_SUCCESS(status)); + break; + } + case UFMT_STRING: { + // Try to parse the string as a number + result = parseNumberLiteral(arg, status); + if (U_FAILURE(status)) { + status = U_MF_OPERAND_MISMATCH_ERROR; + } + break; + } + default: { + // Other types can't be parsed as a number + status = U_MF_OPERAND_MISMATCH_ERROR; + break; + } + } + return result; +} + + +/* static */ void StandardFunctions::TestFormat::testFunctionParameters(const FormattedPlaceholder& arg, + const FunctionOptions& options, + int32_t& decimalPlaces, + bool& failsFormat, + bool& failsSelect, + double& input, + UErrorCode& status) { + CHECK_ERROR(status); + + // 1. Let DecimalPlaces be 0. + decimalPlaces = 0; + + // 2. Let FailsFormat be false. + failsFormat = false; + + // 3. Let FailsSelect be false. + failsSelect = false; + + // 4. Let arg be the resolved value of the expression operand. + // (already true) + + // Step 5 omitted because composition isn't fully implemented yet + // 6. Else if arg is a numerical value or a string matching the number-literal production, then + input = formattableToNumber(arg.asFormattable(), status); + if (U_FAILURE(status)) { + // 7. Else, + // 7i. Emit "bad-input" Resolution Error. + status = U_MF_OPERAND_MISMATCH_ERROR; + // 7ii. Use a fallback value as the resolved value of the expression. + // Further steps of this algorithm are not followed. + } + // 8. If the decimalPlaces option is set, then + Formattable opt; + if (options.getFunctionOption(UnicodeString("decimalPlaces"), opt)) { + // 8i. If its value resolves to a numerical integer value 0 or 1 + // or their corresponding string representations '0' or '1', then + double decimalPlacesInput = formattableToNumber(opt, status); + if (U_SUCCESS(status)) { + if (decimalPlacesInput == 0 || decimalPlacesInput == 1) { + // 8ia. Set DecimalPlaces to be the numerical value of the option. + decimalPlaces = decimalPlacesInput; + } + } + // 8ii. Else if its value is not an unresolved value set by option resolution, + else { + // 8iia. Emit "bad-option" Resolution Error. + status = U_MF_BAD_OPTION; + // 8iib. Use a fallback value as the resolved value of the expression. + } + } + // 9. If the fails option is set, then + Formattable failsOpt; + if (options.getFunctionOption(UnicodeString("fails"), failsOpt)) { + UnicodeString failsString = failsOpt.getString(status); + if (U_SUCCESS(status)) { + // 9i. If its value resolves to the string 'always', then + if (failsString == u"always") { + // 9ia. Set FailsFormat to be true + failsFormat = true; + // 9ib. Set FailsSelect to be true. + failsSelect = true; + } + // 9ii. Else if its value resolves to the string "format", then + else if (failsString == u"format") { + // 9ia. Set FailsFormat to be true + failsFormat = true; + } + // 9iii. Else if its value resolves to the string "select", then + else if (failsString == u"select") { + // 9iiia. Set FailsSelect to be true. + failsSelect = true; + } + // 9iv. Else if its value does not resolve to the string "never", then + else if (failsString != u"never") { + // 9iv(a). Emit "bad-option" Resolution Error. + status = U_MF_BAD_OPTION; + } + } else { + // 9iv. again + status = U_MF_BAD_OPTION; + } + } +} + +FormattedPlaceholder StandardFunctions::TestFormat::format(FormattedPlaceholder&& arg, + FunctionOptions&& options, + UErrorCode& status) const{ + + int32_t decimalPlaces; + bool failsFormat; + bool failsSelect; + double input; + + testFunctionParameters(arg, options, decimalPlaces, + failsFormat, failsSelect, input, status); + if (U_FAILURE(status)) { + return FormattedPlaceholder(arg.getFallback()); + } + + // If FailsFormat is true, attempting to format the placeholder to any + // formatting target will fail. + if (failsFormat) { + status = U_MF_FORMATTING_ERROR; + return FormattedPlaceholder(arg.getFallback()); + } + UnicodeString result; + // When :test:function is used as a formatter, a placeholder resolving to a value + // with a :test:function expression is formatted as a concatenation of the following parts: + // 1. If Input is less than 0, the character - U+002D Hyphen-Minus. + if (input < 0) { + result += HYPHEN; + } + // 2. The truncated absolute integer value of Input, i.e. floor(abs(Input)), formatted as a + // sequence of decimal digit characters (U+0030...U+0039). + char buffer[256]; + bool ignore; + int ignoreLen; + int ignorePoint; + double_conversion::DoubleToStringConverter::DoubleToAscii(floor(abs(input)), + double_conversion::DoubleToStringConverter::DtoaMode::SHORTEST, + 0, + buffer, + 256, + &ignore, + &ignoreLen, + &ignorePoint); + result += UnicodeString(buffer); + // 3. If DecimalPlaces is 1, then + if (decimalPlaces == 1) { + // 3i. The character . U+002E Full Stop. + result += u"."; + // 3ii. The single decimal digit character representing the value + // floor((abs(Input) - floor(abs(Input))) * 10) + int32_t val = floor((abs(input) - floor(abs(input)) * 10)); + result += digitToChar(val, status); + U_ASSERT(U_SUCCESS(status)); + } + return FormattedPlaceholder(result); +} + +// ------------ TestSelectFactory + +StandardFunctions::TestSelectFactory::~TestSelectFactory() {} +StandardFunctions::TestSelect::~TestSelect() {} + +Selector* StandardFunctions::TestSelectFactory::createSelector(const Locale& locale, + UErrorCode& errorCode) const { + NULL_ON_ERROR(errorCode); + + // Results are not locale-dependent + (void) locale; + + Selector* result = new TestSelect(); + if (result == nullptr) { + errorCode = U_MEMORY_ALLOCATION_ERROR; + } + return result; +} + +void StandardFunctions::TestSelect::selectKey(FormattedPlaceholder&& val, + FunctionOptions&& options, + const UnicodeString* keys, + int32_t keysLen, + UnicodeString* prefs, + int32_t& prefsLen, + UErrorCode& status) const { + int32_t decimalPlaces; + bool failsFormat; + bool failsSelect; + double input; + + TestFormat::testFunctionParameters(val, options, decimalPlaces, + failsFormat, failsSelect, input, status); + + if (U_FAILURE(status)) { + return; + } + + if (failsSelect) { + status = U_MF_SELECTOR_ERROR; + return; + } + + // If the Input is 1 and DecimalPlaces is 1, the method will return some slice + // of the list « '1.0', '1' », depending on whether those values are included in keys. + bool include1point0 = false; + bool include1 = false; + if (input == 1 && decimalPlaces == 1) { + include1point0 = true; + include1 = true; + } else if (input == 1 && decimalPlaces == 0) { + include1 = true; + } + + // If the Input is 1 and DecimalPlaces is 0, the method will return the list « '1' » if + // keys includes '1', or an empty list otherwise. + // If the Input is any other value, the method will return an empty list. + for (int32_t i = 0; i < keysLen; i++) { + if ((keys[i] == u"1" && include1) + || (keys[i] == u"1.0" && include1point0)) { + prefs[prefsLen] = keys[i]; + prefsLen++; + } + } +} + } // namespace message2 U_NAMESPACE_END @@ -1242,3 +1550,4 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_function_registry_internal.h b/contrib/libs/icu/i18n/messageformat2_function_registry_internal.h index 733fc5e945d5..9599b67bb2ba 100644 --- a/contrib/libs/icu/i18n/messageformat2_function_registry_internal.h +++ b/contrib/libs/icu/i18n/messageformat2_function_registry_internal.h @@ -10,6 +10,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -209,6 +211,60 @@ namespace message2 { TextSelector(const Locale& l) : locale(l) {} }; + + // See https://github.com/unicode-org/message-format-wg/blob/main/test/README.md + class TestFormatFactory : public FormatterFactory { + public: + Formatter* createFormatter(const Locale& locale, UErrorCode& status) override; + TestFormatFactory() {} + virtual ~TestFormatFactory(); + }; + + class TestSelect; + + class TestFormat : public Formatter { + public: + FormattedPlaceholder format(FormattedPlaceholder&& toFormat, FunctionOptions&& options, UErrorCode& status) const override; + virtual ~TestFormat(); + + private: + friend class TestFormatFactory; + friend class TestSelect; + TestFormat() {} + static void testFunctionParameters(const FormattedPlaceholder& arg, + const FunctionOptions& options, + int32_t& decimalPlaces, + bool& failsFormat, + bool& failsSelect, + double& input, + UErrorCode& status); + + }; + + // See https://github.com/unicode-org/message-format-wg/blob/main/test/README.md + class TestSelectFactory : public SelectorFactory { + public: + Selector* createSelector(const Locale& locale, UErrorCode& status) const override; + TestSelectFactory() {} + virtual ~TestSelectFactory(); + }; + + class TestSelect : public Selector { + public: + void selectKey(FormattedPlaceholder&& val, + FunctionOptions&& options, + const UnicodeString* keys, + int32_t keysLen, + UnicodeString* prefs, + int32_t& prefsLen, + UErrorCode& status) const override; + virtual ~TestSelect(); + + private: + friend class TestSelectFactory; + TestSelect() {} + }; + }; extern void formatDateWithDefaults(const Locale& locale, UDate date, UnicodeString&, UErrorCode& errorCode); @@ -226,6 +282,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_FUNCTION_REGISTRY_INTERNAL_H diff --git a/contrib/libs/icu/i18n/messageformat2_macros.h b/contrib/libs/icu/i18n/messageformat2_macros.h index f06ed1a5a977..20e81377d4d5 100644 --- a/contrib/libs/icu/i18n/messageformat2_macros.h +++ b/contrib/libs/icu/i18n/messageformat2_macros.h @@ -10,6 +10,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -97,6 +99,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_MACROS_H diff --git a/contrib/libs/icu/i18n/messageformat2_parser.cpp b/contrib/libs/icu/i18n/messageformat2_parser.cpp index b4768756c5ea..9a9f8e78df03 100644 --- a/contrib/libs/icu/i18n/messageformat2_parser.cpp +++ b/contrib/libs/icu/i18n/messageformat2_parser.cpp @@ -3,13 +3,18 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 +#include "unicode/uniset.h" #include "messageformat2_errors.h" #include "messageformat2_macros.h" #include "messageformat2_parser.h" +#include "ucln_in.h" +#include "umutex.h" #include "uvector.h" // U_ASSERT U_NAMESPACE_BEGIN @@ -91,14 +96,282 @@ static void copyContext(const UChar in[U_PARSE_CONTEXT_LEN], UChar out[U_PARSE_C } // ------------------------------------- -// Predicates +// Initialization of UnicodeSets + +namespace unisets { + +UnicodeSet* gUnicodeSets[unisets::UNISETS_KEY_COUNT] = {}; + +inline UnicodeSet* getImpl(Key key) { + return gUnicodeSets[key]; +} + +icu::UInitOnce gMF2ParseUniSetsInitOnce {}; +} + +UnicodeSet* initContentChars(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } + + UnicodeSet* result = new UnicodeSet(0x0001, 0x0008); // Omit NULL, HTAB and LF + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + } + result->add(0x000B, 0x000C); // Omit CR + result->add(0x000E, 0x001F); // Omit SP + result->add(0x0021, 0x002D); // Omit '.' + result->add(0x002F, 0x003F); // Omit '@' + result->add(0x0041, 0x005B); // Omit '\' + result->add(0x005D, 0x007A); // Omit { | } + result->add(0x007E, 0x2FFF); // Omit IDEOGRAPHIC_SPACE + result->add(0x3001, 0x10FFFF); // Allowing surrogates is intentional + result->freeze(); + return result; +} + +UnicodeSet* initWhitespace(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } + + UnicodeSet* result = new UnicodeSet(); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + } + result->add(SPACE); + result->add(HTAB); + result->add(CR); + result->add(LF); + result->add(IDEOGRAPHIC_SPACE); + result->freeze(); + return result; +} + +UnicodeSet* initBidiControls(UErrorCode& status) { + UnicodeSet* result = new UnicodeSet(UnicodeString("[\\u061C]"), status); + if (U_FAILURE(status)) { + return nullptr; + } + result->add(0x200E, 0x200F); + result->add(0x2066, 0x2069); + result->freeze(); + return result; +} + +UnicodeSet* initAlpha(UErrorCode& status) { + UnicodeSet* result = new UnicodeSet(UnicodeString("[:letter:]"), status); + if (U_FAILURE(status)) { + return nullptr; + } + result->freeze(); + return result; +} + +UnicodeSet* initDigits(UErrorCode& status) { + UnicodeSet* result = new UnicodeSet(UnicodeString("[:number:]"), status); + if (U_FAILURE(status)) { + return nullptr; + } + result->freeze(); + return result; +} + +UnicodeSet* initNameStartChars(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } + + UnicodeSet* isAlpha = unisets::gUnicodeSets[unisets::ALPHA] = initAlpha(status); + if (U_FAILURE(status)) { + return nullptr; + } + UnicodeSet* result = new UnicodeSet(*isAlpha); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + }; + result->add(UNDERSCORE); + result->add(0x00C0, 0x00D6); + result->add(0x00D8, 0x00F6); + result->add(0x00F8, 0x02FF); + result->add(0x0370, 0x037D); + result->add(0x037F, 0x061B); + result->add(0x061D, 0x1FFF); + result->add(0x200C, 0x200D); + result->add(0x2070, 0x218F); + result->add(0x2C00, 0x2FEF); + result->add(0x3001, 0xD7FF); + result->add(0xF900, 0xFDCF); + result->add(0xFDF0, 0xFFFD); + result->add(0x100000, 0xEFFFF); + result->freeze(); + return result; +} + +UnicodeSet* initNameChars(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } + + UnicodeSet* nameStart = unisets::gUnicodeSets[unisets::NAME_START] = initNameStartChars(status); + UnicodeSet* digit = unisets::gUnicodeSets[unisets::DIGIT] = initDigits(status); + if (U_FAILURE(status)) { + return nullptr; + } + UnicodeSet* result = new UnicodeSet(); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + }; + result->addAll(*nameStart); + result->addAll(*digit); + result->add(HYPHEN); + result->add(PERIOD); + result->add(0x00B7); + result->add(0x0300, 0x036F); + result->add(0x203F, 0x2040); + result->freeze(); + return result; +} + +UnicodeSet* initTextChars(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } + + UnicodeSet* content = unisets::gUnicodeSets[unisets::CONTENT] = initContentChars(status); + UnicodeSet* whitespace = unisets::gUnicodeSets[unisets::WHITESPACE] = initWhitespace(status); + if (U_FAILURE(status)) { + return nullptr; + } + UnicodeSet* result = new UnicodeSet(); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + }; + result->addAll(*content); + result->addAll(*whitespace); + result->add(PERIOD); + result->add(AT); + result->add(PIPE); + result->freeze(); + return result; +} + +UnicodeSet* initQuotedChars(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } + + unisets::gUnicodeSets[unisets::TEXT] = initTextChars(status); + if (U_FAILURE(status)) { + return nullptr; + } + UnicodeSet* result = new UnicodeSet(); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + }; + // content and whitespace were initialized by `initTextChars()` + UnicodeSet* content = unisets::getImpl(unisets::CONTENT); + if (content == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + } + result->addAll(*content); + UnicodeSet* whitespace = unisets::getImpl(unisets::WHITESPACE); + if (whitespace == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + } + result->addAll(*whitespace); + result->add(PERIOD); + result->add(AT); + result->add(LEFT_CURLY_BRACE); + result->add(RIGHT_CURLY_BRACE); + result->freeze(); + return result; +} + +UnicodeSet* initEscapableChars(UErrorCode& status) { + if (U_FAILURE(status)) { + return nullptr; + } -// Returns true if `c` is in the interval [`first`, `last`] -static bool inRange(UChar32 c, UChar32 first, UChar32 last) { - U_ASSERT(first < last); - return c >= first && c <= last; + UnicodeSet* result = new UnicodeSet(); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + return nullptr; + } + result->add(PIPE); + result->add(BACKSLASH); + result->add(LEFT_CURLY_BRACE); + result->add(RIGHT_CURLY_BRACE); + result->freeze(); + return result; } +namespace unisets { + +UBool U_CALLCONV cleanupMF2ParseUniSets() { + for (int32_t i = 0; i < UNISETS_KEY_COUNT; i++) { + delete gUnicodeSets[i]; + gUnicodeSets[i] = nullptr; + } + gMF2ParseUniSetsInitOnce.reset(); + return true; +} + +void U_CALLCONV initMF2ParseUniSets(UErrorCode& status) { + ucln_i18n_registerCleanup(UCLN_I18N_MF2_UNISETS, cleanupMF2ParseUniSets); + /* + Each of the init functions initializes the UnicodeSets + that it depends on. + + initBidiControls (no dependencies) + + initEscapableChars (no dependencies) + + initNameChars depends on + initDigits + initNameStartChars depends on + initAlpha + + initQuotedChars depends on + initTextChars depends on + initContentChars + initWhitespace + */ + gUnicodeSets[unisets::BIDI] = initBidiControls(status); + gUnicodeSets[unisets::NAME_CHAR] = initNameChars(status); + gUnicodeSets[unisets::QUOTED] = initQuotedChars(status); + gUnicodeSets[unisets::ESCAPABLE] = initEscapableChars(status); + + if (U_FAILURE(status)) { + cleanupMF2ParseUniSets(); + } +} + +const UnicodeSet* get(Key key, UErrorCode& status) { + umtx_initOnce(gMF2ParseUniSetsInitOnce, &initMF2ParseUniSets, status); + if (U_FAILURE(status)) { + return nullptr; + } + UnicodeSet* result = getImpl(key); + if (result == nullptr) { + status = U_MEMORY_ALLOCATION_ERROR; + } + return result; +} + +} + +// ------------------------------------- +// Predicates + /* The following helper predicates should exactly match nonterminals in the MessageFormat 2 grammar: @@ -113,76 +386,50 @@ static bool inRange(UChar32 c, UChar32 first, UChar32 last) { `isWhitespace()` : `s` */ -static bool isContentChar(UChar32 c) { - return inRange(c, 0x0001, 0x0008) // Omit NULL, HTAB and LF - || inRange(c, 0x000B, 0x000C) // Omit CR - || inRange(c, 0x000E, 0x001F) // Omit SP - || inRange(c, 0x0021, 0x002D) // Omit '.' - || inRange(c, 0x002F, 0x003F) // Omit '@' - || inRange(c, 0x0041, 0x005B) // Omit '\' - || inRange(c, 0x005D, 0x007A) // Omit { | } - || inRange(c, 0x007E, 0xD7FF) // Omit surrogates - || inRange(c, 0xE000, 0x10FFFF); +bool Parser::isContentChar(UChar32 c) const { + return contentChars->contains(c); } -// See `s` in the MessageFormat 2 grammar -inline bool isWhitespace(UChar32 c) { - switch (c) { - case SPACE: - case HTAB: - case CR: - case LF: - case IDEOGRAPHIC_SPACE: - return true; - default: - return false; - } +// See `bidi` in the MF2 grammar +bool Parser::isBidiControl(UChar32 c) const { + return bidiControlChars->contains(c); } -static bool isTextChar(UChar32 c) { - return isContentChar(c) - || isWhitespace(c) - || c == PERIOD - || c == AT - || c == PIPE; +// See `ws` in the MessageFormat 2 grammar +bool Parser::isWhitespace(UChar32 c) const { + return whitespaceChars->contains(c); } -static bool isAlpha(UChar32 c) { return inRange(c, 0x0041, 0x005A) || inRange(c, 0x0061, 0x007A); } +bool Parser::isTextChar(UChar32 c) const { + return textChars->contains(c); +} + +bool Parser::isAlpha(UChar32 c) const { + return alphaChars->contains(c); +} -static bool isDigit(UChar32 c) { return inRange(c, 0x0030, 0x0039); } +bool Parser::isDigit(UChar32 c) const { + return digitChars->contains(c); +} -static bool isNameStart(UChar32 c) { - return isAlpha(c) || c == UNDERSCORE || inRange(c, 0x00C0, 0x00D6) || inRange(c, 0x00D8, 0x00F6) || - inRange(c, 0x00F8, 0x02FF) || inRange(c, 0x0370, 0x037D) || inRange(c, 0x037F, 0x1FFF) || - inRange(c, 0x200C, 0x200D) || inRange(c, 0x2070, 0x218F) || inRange(c, 0x2C00, 0x2FEF) || - inRange(c, 0x3001, 0xD7FF) || inRange(c, 0xF900, 0xFDCF) || inRange(c, 0xFDF0, 0xFFFD) || - inRange(c, 0x10000, 0xEFFFF); +bool Parser::isNameStart(UChar32 c) const { + return nameStartChars->contains(c); } -static bool isNameChar(UChar32 c) { - return isNameStart(c) || isDigit(c) || c == HYPHEN || c == PERIOD || c == 0x00B7 || - inRange(c, 0x0300, 0x036F) || inRange(c, 0x203F, 0x2040); +bool Parser::isNameChar(UChar32 c) const { + return nameChars->contains(c); } -static bool isUnquotedStart(UChar32 c) { - return isNameStart(c) || isDigit(c) || c == HYPHEN || c == PERIOD || c == 0x00B7 || - inRange(c, 0x0300, 0x036F) || inRange(c, 0x203F, 0x2040); +bool Parser::isUnquotedStart(UChar32 c) const { + return isNameChar(c); } -static bool isQuotedChar(UChar32 c) { - return isContentChar(c) - || isWhitespace(c) - || c == PERIOD - || c == AT - || c == LEFT_CURLY_BRACE - || c == RIGHT_CURLY_BRACE; +bool Parser::isQuotedChar(UChar32 c) const { + return quotedChars->contains(c); } -static bool isEscapableChar(UChar32 c) { - return c == PIPE - || c == BACKSLASH - || c == LEFT_CURLY_BRACE - || c == RIGHT_CURLY_BRACE; +bool Parser::isEscapableChar(UChar32 c) const { + return escapableChars->contains(c); } // Returns true iff `c` can begin a `function` nonterminal @@ -203,12 +450,12 @@ static bool isAnnotationStart(UChar32 c) { } // Returns true iff `c` can begin a `literal` nonterminal -static bool isLiteralStart(UChar32 c) { +bool Parser::isLiteralStart(UChar32 c) const { return (c == PIPE || isNameStart(c) || c == HYPHEN || isDigit(c)); } // Returns true iff `c` can begin a `key` nonterminal -static bool isKeyStart(UChar32 c) { +bool Parser::isKeyStart(UChar32 c) const { return (c == ASTERISK || isLiteralStart(c)); } @@ -347,7 +594,7 @@ option, or the optional space before an attribute. No pre, no post. A message may end with whitespace, so `index` may equal `len()` on exit. */ -void Parser::parseWhitespaceMaybeRequired(bool required, UErrorCode& errorCode) { +void Parser::parseRequiredWS(UErrorCode& errorCode) { bool sawWhitespace = false; // The loop exits either when we consume all the input, @@ -358,7 +605,7 @@ void Parser::parseWhitespaceMaybeRequired(bool required, UErrorCode& errorCode) // If whitespace isn't required -- or if we saw it already -- // then the caller is responsible for checking this case and // setting an error if necessary. - if (!required || sawWhitespace) { + if (sawWhitespace) { // Not an error. return; } @@ -380,24 +627,51 @@ void Parser::parseWhitespaceMaybeRequired(bool required, UErrorCode& errorCode) } } - if (!sawWhitespace && required) { + if (!sawWhitespace) { ERROR(errorCode); } } +void Parser::parseOptionalBidi() { + while (true) { + if (!inBounds()) { + return; + } + if (isBidiControl(peek())) { + next(); + } else { + break; + } + } +} + /* - No pre, no post, for the same reason as `parseWhitespaceMaybeRequired()`. + No pre, no post, because a message may end with whitespace + Matches `s` in the MF2 grammar */ void Parser::parseRequiredWhitespace(UErrorCode& errorCode) { - parseWhitespaceMaybeRequired(true, errorCode); + parseOptionalBidi(); + parseRequiredWS(errorCode); + parseOptionalWhitespace(); normalizedInput += SPACE; } /* No pre, no post, for the same reason as `parseWhitespaceMaybeRequired()`. */ -void Parser::parseOptionalWhitespace(UErrorCode& errorCode) { - parseWhitespaceMaybeRequired(false, errorCode); +void Parser::parseOptionalWhitespace() { + while (true) { + if (!inBounds()) { + return; + } + auto cp = peek(); + if (isWhitespace(cp) || isBidiControl(cp)) { + maybeAdvanceLine(); + next(); + } else { + break; + } + } } // Consumes a single character, signaling an error if `peek()` != `c` @@ -442,11 +716,11 @@ void Parser::parseToken(const std::u16string_view& token, UErrorCode& errorCode) */ void Parser::parseTokenWithWhitespace(const std::u16string_view& token, UErrorCode& errorCode) { // No need for error check or bounds check before parseOptionalWhitespace - parseOptionalWhitespace(errorCode); + parseOptionalWhitespace(); // Establish precondition CHECK_BOUNDS(errorCode); parseToken(token, errorCode); - parseOptionalWhitespace(errorCode); + parseOptionalWhitespace(); // Guarantee postcondition CHECK_BOUNDS(errorCode); } @@ -458,12 +732,12 @@ void Parser::parseTokenWithWhitespace(const std::u16string_view& token, UErrorCo then consumes optional whitespace again */ void Parser::parseTokenWithWhitespace(UChar32 c, UErrorCode& errorCode) { - // No need for error check or bounds check before parseOptionalWhitespace(errorCode) - parseOptionalWhitespace(errorCode); + // No need for error check or bounds check before parseOptionalWhitespace() + parseOptionalWhitespace(); // Establish precondition CHECK_BOUNDS(errorCode); parseToken(c, errorCode); - parseOptionalWhitespace(errorCode); + parseOptionalWhitespace(); // Guarantee postcondition CHECK_BOUNDS(errorCode); } @@ -482,11 +756,17 @@ UnicodeString Parser::parseName(UErrorCode& errorCode) { U_ASSERT(inBounds()); - if (!isNameStart(peek())) { + if (!(isNameStart(peek()) || isBidiControl(peek()))) { ERROR(errorCode); return name; } + // name = [bidi] name-start *name-char [bidi] + + // [bidi] + parseOptionalBidi(); + + // name-start *name-char while (isNameChar(peek())) { UChar32 c = peek(); name += c; @@ -497,6 +777,10 @@ UnicodeString Parser::parseName(UErrorCode& errorCode) { break; } } + + // [bidi] + parseOptionalBidi(); + return name; } @@ -510,21 +794,13 @@ VariableName Parser::parseVariableName(UErrorCode& errorCode) { VariableName result; U_ASSERT(inBounds()); - // If the '$' is missing, we don't want a binding - // for this variable to be created. - bool valid = peek() == DOLLAR; + parseToken(DOLLAR, errorCode); if (!inBounds()) { ERROR(errorCode); return result; } - UnicodeString varName = parseName(errorCode); - // Set the name to "" if the variable wasn't - // declared correctly - if (!valid) { - varName.remove(); - } - return VariableName(varName); + return VariableName(parseName(errorCode)); } /* @@ -853,7 +1129,7 @@ void Parser::parseAttribute(AttributeAdder& attrAdder, UErrorCode& errorCode) // about whether whitespace precedes another // attribute, or the '=' sign int32_t savedIndex = index; - parseOptionalWhitespace(errorCode); + parseOptionalWhitespace(); Operand rand; if (peek() == EQUALS) { @@ -861,19 +1137,9 @@ void Parser::parseAttribute(AttributeAdder& attrAdder, UErrorCode& errorCode) parseTokenWithWhitespace(EQUALS, errorCode); UnicodeString rhsStr; - // Parse RHS, which is either a literal or variable - switch (peek()) { - case DOLLAR: { - rand = Operand(parseVariableName(errorCode)); - break; - } - default: { - // Must be a literal - rand = Operand(parseLiteral(errorCode)); - break; - } - } - U_ASSERT(!rand.isNull()); + // Parse RHS, which must be a literal + // attribute = "@" identifier [o "=" o literal] + rand = Operand(parseLiteral(errorCode)); } else { // attribute -> "@" identifier [[s] "=" [s]] // Use null operand, which `rand` is already set to @@ -881,7 +1147,7 @@ void Parser::parseAttribute(AttributeAdder& attrAdder, UErrorCode& errorCode) index = savedIndex; } - attrAdder.addAttribute(lhs, std::move(rand), errorCode); + attrAdder.addAttribute(lhs, std::move(Operand(rand)), errorCode); } /* @@ -1149,7 +1415,7 @@ the comment in `parseOptions()` for details. // (the character is either the required space before an annotation, or optional // trailing space after the literal or variable). It's still ambiguous which // one does apply. - parseOptionalWhitespace(status); + parseOptionalWhitespace(); // Restore precondition CHECK_BOUNDS(status); @@ -1220,7 +1486,7 @@ Expression Parser::parseExpression(UErrorCode& status) { // Parse opening brace parseToken(LEFT_CURLY_BRACE, status); // Optional whitespace after opening brace - parseOptionalWhitespace(status); + parseOptionalWhitespace(); Expression::Builder exprBuilder(status); // Restore precondition @@ -1263,7 +1529,7 @@ Expression Parser::parseExpression(UErrorCode& status) { // Parse optional space // (the last [s] in e.g. "{" [s] literal [s annotation] *(s attribute) [s] "}") - parseOptionalWhitespace(status); + parseOptionalWhitespace(); // Either an operand or operator (or both) must have been set already, // so there can't be an error @@ -1339,7 +1605,7 @@ void Parser::parseInputDeclaration(UErrorCode& status) { CHECK_BOUNDS(status); parseToken(ID_INPUT, status); - parseOptionalWhitespace(status); + parseOptionalWhitespace(); // Restore precondition before calling parseExpression() CHECK_BOUNDS(status); @@ -1400,7 +1666,7 @@ void Parser::parseDeclarations(UErrorCode& status) { // Avoid looping infinitely CHECK_ERROR(status); - parseOptionalWhitespace(status); + parseOptionalWhitespace(); // Restore precondition CHECK_BOUNDS(status); } @@ -1510,8 +1776,8 @@ This is addressed using "backtracking" (similarly to `parseOptions()`). // We've seen at least one whitespace-key pair, so now we can parse // *(s key) [s] - while (peek() != LEFT_CURLY_BRACE || isWhitespace(peek())) { // Try to recover from errors - bool wasWhitespace = isWhitespace(peek()); + while (peek() != LEFT_CURLY_BRACE || isWhitespace(peek()) || isBidiControl(peek())) { + bool wasWhitespace = isWhitespace(peek()) || isBidiControl(peek()); parseRequiredWhitespace(status); if (!wasWhitespace) { // Avoid infinite loop when parsing something like: @@ -1569,7 +1835,7 @@ Markup Parser::parseMarkup(UErrorCode& status) { // Consume the '{' next(); normalizedInput += LEFT_CURLY_BRACE; - parseOptionalWhitespace(status); + parseOptionalWhitespace(); bool closing = false; switch (peek()) { case NUMBER_SIGN: { @@ -1596,19 +1862,19 @@ Markup Parser::parseMarkup(UErrorCode& status) { // Parse the options, which must begin with a ' ' // if present - if (inBounds() && isWhitespace(peek())) { + if (inBounds() && (isWhitespace(peek()) || isBidiControl(peek()))) { OptionAdder optionAdder(builder); parseOptions(optionAdder, status); } // Parse the attributes, which also must begin // with a ' ' - if (inBounds() && isWhitespace(peek())) { + if (inBounds() && (isWhitespace(peek()) || isBidiControl(peek()))) { AttributeAdder attrAdder(builder); parseAttributes(attrAdder, status); } - parseOptionalWhitespace(status); + parseOptionalWhitespace(); bool standalone = false; // Check if this is a standalone or not @@ -1656,7 +1922,7 @@ std::variant Parser::parsePlaceholder(UErrorCode& status) { isMarkup = true; break; } - if (!isWhitespace(c)){ + if (!(isWhitespace(c) || isBidiControl(c))) { break; } tempIndex++; @@ -1712,7 +1978,7 @@ Pattern Parser::parseSimpleMessage(UErrorCode& status) { break; } // Don't loop infinitely - if (errors.hasSyntaxError()) { + if (errors.hasSyntaxError() || U_FAILURE(status)) { break; } } @@ -1720,6 +1986,22 @@ Pattern Parser::parseSimpleMessage(UErrorCode& status) { return result.build(status); } +void Parser::parseVariant(UErrorCode& status) { + CHECK_ERROR(status); + + // At least one key is required + SelectorKeys keyList(parseNonEmptyKeys(status)); + + // parseNonEmptyKeys() consumes any trailing whitespace, + // so the pattern can be consumed next. + + // Restore precondition before calling parsePattern() + // (which must return a non-null value) + CHECK_BOUNDS(status); + Pattern rhs = parseQuotedPattern(status); + + dataModel.addVariant(std::move(keyList), std::move(rhs), status); +} /* Consume a `selectors` (matching the nonterminal in the grammar), @@ -1739,22 +2021,25 @@ void Parser::parseSelectors(UErrorCode& status) { // Parse selectors // "Backtracking" is required here. It's not clear if whitespace is // (`[s]` selector) or (`[s]` variant) - while (isWhitespace(peek()) || peek() == LEFT_CURLY_BRACE) { - parseOptionalWhitespace(status); + while (isWhitespace(peek()) || peek() == DOLLAR) { + int32_t whitespaceStart = index; + parseRequiredWhitespace(status); // Restore precondition CHECK_BOUNDS(status); - if (peek() != LEFT_CURLY_BRACE) { + if (peek() != DOLLAR) { // This is not necessarily an error, but rather, // means the whitespace we parsed was the optional // whitespace preceding the first variant, not the - // optional whitespace preceding a subsequent expression. + // required whitespace preceding a subsequent variable. + // In that case, "push back" the whitespace. + normalizedInput.truncate(normalizedInput.length() - 1); + index = whitespaceStart; break; } - Expression expression; - expression = parseExpression(status); + VariableName var = parseVariableName(status); empty = false; - dataModel.addSelector(std::move(expression), status); + dataModel.addSelector(std::move(var), status); CHECK_ERROR(status); } @@ -1770,27 +2055,29 @@ void Parser::parseSelectors(UErrorCode& status) { } \ // Parse variants - while (isWhitespace(peek()) || isKeyStart(peek())) { - // Trailing whitespace is allowed - parseOptionalWhitespace(status); + // matcher = match-statement s variant *(o variant) + + // Parse first variant + parseRequiredWhitespace(status); + if (!inBounds()) { + ERROR(status); + return; + } + parseVariant(status); + if (!inBounds()) { + // Not an error; there might be only one variant + return; + } + + while (isWhitespace(peek()) || isBidiControl(peek()) || isKeyStart(peek())) { + parseOptionalWhitespace(); + // Restore the precondition. + // Trailing whitespace is allowed. if (!inBounds()) { return; } - // At least one key is required - SelectorKeys keyList(parseNonEmptyKeys(status)); - - CHECK_ERROR(status); - - // parseNonEmptyKeys() consumes any trailing whitespace, - // so the pattern can be consumed next. - - // Restore precondition before calling parsePattern() - // (which must return a non-null value) - CHECK_BOUNDS(status); - Pattern rhs = parseQuotedPattern(status); - - dataModel.addVariant(std::move(keyList), std::move(rhs), status); + parseVariant(status); // Restore the precondition, *without* erroring out if we've // reached the end of input. That's because it's valid for the @@ -1799,6 +2086,10 @@ void Parser::parseSelectors(UErrorCode& status) { // Because if we don't check it here, the `isWhitespace()` call in // the loop head will read off the end of the input string. CHECK_END_OF_INPUT + + if (errors.hasSyntaxError() || U_FAILURE(status)) { + break; + } } } @@ -1871,7 +2162,7 @@ void Parser::parse(UParseError &parseErrorResult, UErrorCode& status) { bool complex = false; // First, "look ahead" to determine if this is a simple or complex // message. To do that, check the first non-whitespace character. - while (inBounds(index) && isWhitespace(peek())) { + while (inBounds(index) && (isWhitespace(peek()) || isBidiControl(peek()))) { next(); } @@ -1891,10 +2182,10 @@ void Parser::parse(UParseError &parseErrorResult, UErrorCode& status) { // Message can be empty, so we need to only look ahead // if we know it's non-empty if (complex) { - parseOptionalWhitespace(status); + parseOptionalWhitespace(); parseDeclarations(status); parseBody(status); - parseOptionalWhitespace(status); + parseOptionalWhitespace(); } else { // Simple message // For normalization, quote the pattern @@ -1926,3 +2217,4 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_parser.h b/contrib/libs/icu/i18n/messageformat2_parser.h index b62cbe9200b9..62a52d8f680a 100644 --- a/contrib/libs/icu/i18n/messageformat2_parser.h +++ b/contrib/libs/icu/i18n/messageformat2_parser.h @@ -10,12 +10,15 @@ #include "unicode/messageformat2_data_model.h" #include "unicode/parseerr.h" +#include "unicode/uniset.h" #include "messageformat2_allocation.h" #include "messageformat2_errors.h" #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -54,6 +57,26 @@ namespace message2 { } }; + + // Initialization of UnicodeSets + namespace unisets { + enum Key { + CONTENT, + WHITESPACE, + BIDI, + ALPHA, + DIGIT, + NAME_START, + NAME_CHAR, + TEXT, + QUOTED, + ESCAPABLE, + UNISETS_KEY_COUNT + }; + + U_I18N_API const UnicodeSet* get(Key key, UErrorCode& status); + } + // Parser class (private) class Parser : public UMemory { public: @@ -82,8 +105,23 @@ namespace message2 { UChar postContext[U_PARSE_CONTEXT_LEN]; } MessageParseError; - Parser(const UnicodeString &input, MFDataModel::Builder& dataModelBuilder, StaticErrors& e, UnicodeString& normalizedInputRef) - : source(input), index(0), errors(e), normalizedInput(normalizedInputRef), dataModel(dataModelBuilder) { + Parser(const UnicodeString &input, + MFDataModel::Builder& dataModelBuilder, + StaticErrors& e, + UnicodeString& normalizedInputRef, + UErrorCode& status) + : contentChars(unisets::get(unisets::CONTENT, status)), + whitespaceChars(unisets::get(unisets::WHITESPACE, status)), + bidiControlChars(unisets::get(unisets::BIDI, status)), + alphaChars(unisets::get(unisets::ALPHA, status)), + digitChars(unisets::get(unisets::DIGIT, status)), + nameStartChars(unisets::get(unisets::NAME_START, status)), + nameChars(unisets::get(unisets::NAME_CHAR, status)), + textChars(unisets::get(unisets::TEXT, status)), + quotedChars(unisets::get(unisets::QUOTED, status)), + escapableChars(unisets::get(unisets::ESCAPABLE, status)), + source(input), index(0), errors(e), normalizedInput(normalizedInputRef), dataModel(dataModelBuilder) { + (void) status; parseError.line = 0; parseError.offset = 0; parseError.lengthBeforeCurrentLine = 0; @@ -91,6 +129,20 @@ namespace message2 { parseError.postContext[0] = '\0'; } + bool isContentChar(UChar32) const; + bool isBidiControl(UChar32) const; + bool isWhitespace(UChar32) const; + bool isTextChar(UChar32) const; + bool isQuotedChar(UChar32) const; + bool isEscapableChar(UChar32) const; + bool isAlpha(UChar32) const; + bool isDigit(UChar32) const; + bool isNameStart(UChar32) const; + bool isNameChar(UChar32) const; + bool isUnquotedStart(UChar32) const; + bool isLiteralStart(UChar32) const; + bool isKeyStart(UChar32) const; + static void translateParseError(const MessageParseError&, UParseError&); static void setParseError(MessageParseError&, uint32_t); void maybeAdvanceLine(); @@ -100,11 +152,13 @@ namespace message2 { void parseUnsupportedStatement(UErrorCode&); void parseLocalDeclaration(UErrorCode&); void parseInputDeclaration(UErrorCode&); - void parseSelectors(UErrorCode&); + void parseSelectors(UErrorCode&); + void parseVariant(UErrorCode&); - void parseWhitespaceMaybeRequired(bool, UErrorCode&); + void parseRequiredWS(UErrorCode&); void parseRequiredWhitespace(UErrorCode&); - void parseOptionalWhitespace(UErrorCode&); + void parseOptionalBidi(); + void parseOptionalWhitespace(); void parseToken(UChar32, UErrorCode&); void parseTokenWithWhitespace(UChar32, UErrorCode&); void parseToken(const std::u16string_view&, UErrorCode&); @@ -149,6 +203,18 @@ namespace message2 { bool inBounds(uint32_t i) const { return source.moveIndex32(index, i) < source.length(); } bool allConsumed() const { return (int32_t) index == source.length(); } + // UnicodeSets for checking character ranges + const UnicodeSet* contentChars; + const UnicodeSet* whitespaceChars; + const UnicodeSet* bidiControlChars; + const UnicodeSet* alphaChars; + const UnicodeSet* digitChars; + const UnicodeSet* nameStartChars; + const UnicodeSet* nameChars; + const UnicodeSet* textChars; + const UnicodeSet* quotedChars; + const UnicodeSet* escapableChars; + // The input string const UnicodeString &source; // The current position within the input string -- counting in UChar32 @@ -165,8 +231,8 @@ namespace message2 { // The parent builder MFDataModel::Builder &dataModel; - }; // class Parser + }; // class Parser } // namespace message2 U_NAMESPACE_END @@ -175,6 +241,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT_PARSER_H diff --git a/contrib/libs/icu/i18n/messageformat2_serializer.cpp b/contrib/libs/icu/i18n/messageformat2_serializer.cpp index b2765f5acf43..dfae0083392b 100644 --- a/contrib/libs/icu/i18n/messageformat2_serializer.cpp +++ b/contrib/libs/icu/i18n/messageformat2_serializer.cpp @@ -3,6 +3,8 @@ #include "unicode/utypes.h" +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -244,11 +246,12 @@ void Serializer::serializeDeclarations() { void Serializer::serializeSelectors() { U_ASSERT(!dataModel.hasPattern()); - const Expression* selectors = dataModel.getSelectorsInternal(); + const VariableName* selectors = dataModel.getSelectorsInternal(); emit(ID_MATCH); for (int32_t i = 0; i < dataModel.numSelectors(); i++) { - // No whitespace needed here -- see `selectors` in the grammar + whitespace(); + emit(DOLLAR); emit(selectors[i]); } } @@ -256,6 +259,7 @@ void Serializer::serializeSelectors() { void Serializer::serializeVariants() { U_ASSERT(!dataModel.hasPattern()); const Variant* variants = dataModel.getVariantsInternal(); + whitespace(); for (int32_t i = 0; i < dataModel.numVariants(); i++) { const Variant& v = variants[i]; emit(v.getKeys()); @@ -285,3 +289,4 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ diff --git a/contrib/libs/icu/i18n/messageformat2_serializer.h b/contrib/libs/icu/i18n/messageformat2_serializer.h index 1b97b3b93008..f190b255f0d3 100644 --- a/contrib/libs/icu/i18n/messageformat2_serializer.h +++ b/contrib/libs/icu/i18n/messageformat2_serializer.h @@ -10,6 +10,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -63,6 +65,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT_SERIALIZER_H diff --git a/contrib/libs/icu/i18n/nfrs.cpp b/contrib/libs/icu/i18n/nfrs.cpp index be2ab2932e7a..b7ffb561461b 100644 --- a/contrib/libs/icu/i18n/nfrs.cpp +++ b/contrib/libs/icu/i18n/nfrs.cpp @@ -152,7 +152,7 @@ NFRuleSet::NFRuleSet(RuleBasedNumberFormat *_owner, UnicodeString* descriptions, UnicodeString& description = descriptions[index]; // !!! make sure index is valid - if (description.length() == 0) { + if (description.isEmpty()) { // throw new IllegalArgumentException("Empty rule set description"); status = U_PARSE_ERROR; return; @@ -177,16 +177,16 @@ NFRuleSet::NFRuleSet(RuleBasedNumberFormat *_owner, UnicodeString* descriptions, name.setTo(UNICODE_STRING_SIMPLE("%default")); } - if (description.length() == 0) { + if (description.isEmpty()) { // throw new IllegalArgumentException("Empty rule set description"); status = U_PARSE_ERROR; } fIsPublic = name.indexOf(gPercentPercent, 2, 0) != 0; - if ( name.endsWith(gNoparse,8) ) { + if (name.endsWith(gNoparse, 8)) { fIsParseable = false; - name.truncate(name.length()-8); // remove the @noparse from the name + name.truncate(name.length() - 8); // remove the @noparse from the name } // all of the other members of NFRuleSet are initialized diff --git a/contrib/libs/icu/i18n/nfrule.cpp b/contrib/libs/icu/i18n/nfrule.cpp index 264e8d79e2d9..ef7f5924c4eb 100644 --- a/contrib/libs/icu/i18n/nfrule.cpp +++ b/contrib/libs/icu/i18n/nfrule.cpp @@ -19,7 +19,6 @@ #if U_HAVE_RBNF -#include #include "unicode/localpointer.h" #include "unicode/rbnf.h" #include "unicode/tblcoll.h" @@ -65,6 +64,7 @@ NFRule::~NFRule() static const char16_t gLeftBracket = 0x005b; static const char16_t gRightBracket = 0x005d; +static const char16_t gVerticalLine = 0x007C; static const char16_t gColon = 0x003a; static const char16_t gZero = 0x0030; static const char16_t gNine = 0x0039; @@ -147,6 +147,7 @@ NFRule::makeRules(UnicodeString& description, // then it's really shorthand for two rules (with one exception) LocalPointer rule2; UnicodeString sbuf; + int32_t orElseOp = description.indexOf(gVerticalLine); // we'll actually only split the rule into two rules if its // base value is an even multiple of its divisor (or it's one @@ -194,9 +195,13 @@ NFRule::makeRules(UnicodeString& description, rule2->radix = rule1->radix; rule2->exponent = rule1->exponent; - // rule2's rule text omits the stuff in brackets: initialize - // its rule text and substitutions accordingly + // By default, rule2's rule text omits the stuff in brackets, + // unless it contains a | between the brackets. + // Initialize its rule text and substitutions accordingly. sbuf.append(description, 0, brack1); + if (orElseOp >= 0) { + sbuf.append(description, orElseOp + 1, brack2 - orElseOp - 1); + } if (brack2 + 1 < description.length()) { sbuf.append(description, brack2 + 1, description.length() - brack2 - 1); } @@ -207,7 +212,12 @@ NFRule::makeRules(UnicodeString& description, // the brackets themselves: initialize _its_ rule text and // substitutions accordingly sbuf.setTo(description, 0, brack1); - sbuf.append(description, brack1 + 1, brack2 - brack1 - 1); + if (orElseOp >= 0) { + sbuf.append(description, brack1 + 1, orElseOp - brack1 - 1); + } + else { + sbuf.append(description, brack1 + 1, brack2 - brack1 - 1); + } if (brack2 + 1 < description.length()) { sbuf.append(description, brack2 + 1, description.length() - brack2 - 1); } @@ -286,18 +296,17 @@ NFRule::parseRuleDescriptor(UnicodeString& description, UErrorCode& status) // into "tempValue", skip periods, commas, and spaces, // stop on a slash or > sign (or at the end of the string), // and throw an exception on any other character - int64_t ll_10 = 10; while (p < descriptorLength) { c = descriptor.charAt(p); if (c >= gZero && c <= gNine) { - int32_t single_digit = static_cast(c - gZero); - if ((val > 0 && val > (std::numeric_limits::max() - single_digit) / 10) || - (val < 0 && val < (std::numeric_limits::min() - single_digit) / 10)) { + int64_t digit = static_cast(c - gZero); + if ((val > 0 && val > (INT64_MAX - digit) / 10) || + (val < 0 && val < (INT64_MIN - digit) / 10)) { // out of int64_t range status = U_PARSE_ERROR; return; } - val = val * ll_10 + single_digit; + val = val * 10 + digit; } else if (c == gSlash || c == gGreaterThan) { break; @@ -322,11 +331,17 @@ NFRule::parseRuleDescriptor(UnicodeString& description, UErrorCode& status) if (c == gSlash) { val = 0; ++p; - ll_10 = 10; while (p < descriptorLength) { c = descriptor.charAt(p); if (c >= gZero && c <= gNine) { - val = val * ll_10 + static_cast(c - gZero); + int64_t digit = static_cast(c - gZero); + if ((val > 0 && val > (INT64_MAX - digit) / 10) || + (val < 0 && val < (INT64_MIN - digit) / 10)) { + // out of int64_t range + status = U_PARSE_ERROR; + return; + } + val = val * 10 + digit; } else if (c == gGreaterThan) { break; @@ -400,7 +415,7 @@ NFRule::parseRuleDescriptor(UnicodeString& description, UErrorCode& status) // finally, if the rule body begins with an apostrophe, strip it off // (this is generally used to put whitespace at the beginning of // a rule's rule text) - if (description.length() > 0 && description.charAt(0) == gTick) { + if (!description.isEmpty() && description.charAt(0) == gTick) { description.removeBetween(0, 1); } diff --git a/contrib/libs/icu/i18n/number_decimalquantity.cpp b/contrib/libs/icu/i18n/number_decimalquantity.cpp index f9350d5d5cc8..ca1dacd3579d 100644 --- a/contrib/libs/icu/i18n/number_decimalquantity.cpp +++ b/contrib/libs/icu/i18n/number_decimalquantity.cpp @@ -1133,7 +1133,7 @@ void DecimalQuantity::setDigitPos(int32_t position, int8_t value) { } void DecimalQuantity::shiftLeft(int32_t numDigits) { - if (!usingBytes && precision + numDigits > 16) { + if (!usingBytes && precision + numDigits >= 16) { switchStorage(); } if (usingBytes) { diff --git a/contrib/libs/icu/i18n/number_longnames.cpp b/contrib/libs/icu/i18n/number_longnames.cpp index de6aad7c3e8a..bf2617e773d0 100644 --- a/contrib/libs/icu/i18n/number_longnames.cpp +++ b/contrib/libs/icu/i18n/number_longnames.cpp @@ -48,8 +48,12 @@ constexpr int32_t PER_INDEX = StandardPlural::Form::COUNT + 1; * Gender of the word, in languages with grammatical gender. */ constexpr int32_t GENDER_INDEX = StandardPlural::Form::COUNT + 2; +/** + * Denominator constant of the unit. + */ +constexpr int32_t CONSTANT_DENOMINATOR_INDEX = StandardPlural::Form::COUNT + 3; // Number of keys in the array populated by PluralTableSink. -constexpr int32_t ARRAY_LENGTH = StandardPlural::Form::COUNT + 3; +constexpr int32_t ARRAY_LENGTH = StandardPlural::Form::COUNT + 4; // TODO(icu-units#28): load this list from resources, after creating a "&set" // function for use in ldml2icu rules. @@ -1010,6 +1014,11 @@ void LongNameHandler::forArbitraryUnit(const Locale &loc, // denominator (the part after the "-per-). If both are empty, fail MeasureUnitImpl unit; MeasureUnitImpl perUnit; + + if (unitRef.getConstantDenominator(status) != 0) { + perUnit.constantDenominator = unitRef.getConstantDenominator(status); + } + { MeasureUnitImpl fullUnit = MeasureUnitImpl::forMeasureUnitMaybeCopy(unitRef, status); if (U_FAILURE(status)) { @@ -1196,6 +1205,12 @@ void LongNameHandler::processPatternTimes(MeasureUnitImpl &&productUnit, DerivedComponents derivedTimesCases(loc, "case", "times"); DerivedComponents derivedPowerCases(loc, "case", "power"); + if (productUnit.constantDenominator != 0) { + CharString constantString; + constantString.appendNumber(productUnit.constantDenominator, status); + outArray[CONSTANT_DENOMINATOR_INDEX] = UnicodeString::fromUTF8(constantString.toStringPiece()); + } + // 4. For each single_unit in product_unit for (int32_t singleUnitIndex = 0; singleUnitIndex < productUnit.singleUnits.length(); singleUnitIndex++) { @@ -1454,6 +1469,39 @@ void LongNameHandler::processPatternTimes(MeasureUnitImpl &&productUnit, } } } + + // 5. Handling constant denominator if it exists. + if (productUnit.constantDenominator != 0) { + int32_t pluralIndex = -1; + for (int32_t index = 0; index < StandardPlural::Form::COUNT; index++) { + if (!outArray[index].isBogus()) { + pluralIndex = index; + break; + } + } + + U_ASSERT(pluralIndex >= 0); // "No plural form found for constant denominator" + + // TODO(ICU-23039): + // Improve the handling of constant_denominator representation. + // For instance, a constant_denominator of 1000000 should be adaptable to + // formats like + // 1,000,000, 1e6, or 1 million. + // Furthermore, ensure consistent pluralization rules for units. For example, + // "meter per 100 seconds" should be evaluated for correct singular/plural + // usage: "second" or "seconds"? + // Similarly, "kilogram per 1000 meters" should be checked for "meter" or + // "meters"? + if (outArray[pluralIndex].length() == 0) { + outArray[pluralIndex] = outArray[CONSTANT_DENOMINATOR_INDEX]; + } else { + UnicodeString tmp; + timesPatternFormatter.format(outArray[CONSTANT_DENOMINATOR_INDEX], outArray[pluralIndex], + tmp, status); + outArray[pluralIndex] = tmp; + } + } + for (int32_t pluralIndex = 0; pluralIndex < StandardPlural::Form::COUNT; pluralIndex++) { if (globalPlaceholder[pluralIndex] == PH_BEGINNING) { UnicodeString tmp; diff --git a/contrib/libs/icu/i18n/number_mapper.cpp b/contrib/libs/icu/i18n/number_mapper.cpp index 2f398d4a9392..457fbc0d0712 100644 --- a/contrib/libs/icu/i18n/number_mapper.cpp +++ b/contrib/libs/icu/i18n/number_mapper.cpp @@ -74,9 +74,11 @@ MacroProps NumberPropertyMapper::oldToNew(const DecimalFormatProperties& propert !properties.currencyPluralInfo.fPtr.isNull() || !properties.currencyUsage.isNull() || warehouse.affixProvider.get().hasCurrencySign()); - CurrencyUnit currency = resolveCurrency(properties, locale, status); - UCurrencyUsage currencyUsage = properties.currencyUsage.getOrDefault(UCURR_USAGE_STANDARD); + CurrencyUnit currency; + UCurrencyUsage currencyUsage; if (useCurrency) { + currency = resolveCurrency(properties, locale, status); + currencyUsage = properties.currencyUsage.getOrDefault(UCURR_USAGE_STANDARD); // NOTE: Slicing is OK. macros.unit = currency; // NOLINT } @@ -129,6 +131,7 @@ MacroProps NumberPropertyMapper::oldToNew(const DecimalFormatProperties& propert } Precision precision; if (!properties.currencyUsage.isNull()) { + U_ASSERT(useCurrency); precision = Precision::constructCurrency(currencyUsage).withCurrency(currency); } else if (roundingIncrement != 0.0) { if (PatternStringUtils::ignoreRoundingIncrement(roundingIncrement, maxFrac)) { @@ -276,7 +279,7 @@ MacroProps NumberPropertyMapper::oldToNew(const DecimalFormatProperties& propert exportedProperties->maximumIntegerDigits = maxInt == -1 ? INT32_MAX : maxInt; Precision rounding_; - if (precision.fType == Precision::PrecisionType::RND_CURRENCY) { + if (useCurrency && precision.fType == Precision::PrecisionType::RND_CURRENCY) { rounding_ = precision.withCurrency(currency, status); } else { rounding_ = precision; diff --git a/contrib/libs/icu/i18n/number_rounding.cpp b/contrib/libs/icu/i18n/number_rounding.cpp index 8f1aa453ada4..0f3975393c58 100644 --- a/contrib/libs/icu/i18n/number_rounding.cpp +++ b/contrib/libs/icu/i18n/number_rounding.cpp @@ -278,23 +278,23 @@ Precision IncrementPrecision::withMinFraction(int32_t minFrac) const { } FractionPrecision Precision::constructFraction(int32_t minFrac, int32_t maxFrac) { - FractionSignificantSettings settings; + FractionSignificantSettings settings{}; settings.fMinFrac = static_cast(minFrac); settings.fMaxFrac = static_cast(maxFrac); settings.fMinSig = -1; settings.fMaxSig = -1; - PrecisionUnion union_; + PrecisionUnion union_{}; union_.fracSig = settings; return {RND_FRACTION, union_}; } Precision Precision::constructSignificant(int32_t minSig, int32_t maxSig) { - FractionSignificantSettings settings; + FractionSignificantSettings settings{}; settings.fMinFrac = -1; settings.fMaxFrac = -1; settings.fMinSig = static_cast(minSig); settings.fMaxSig = static_cast(maxSig); - PrecisionUnion union_; + PrecisionUnion union_{}; union_.fracSig = settings; return {RND_SIGNIFICANT, union_}; } @@ -311,20 +311,20 @@ Precision::constructFractionSignificant( settings.fMaxSig = static_cast(maxSig); settings.fPriority = priority; settings.fRetain = retain; - PrecisionUnion union_; + PrecisionUnion union_{}; union_.fracSig = settings; return {RND_FRACTION_SIGNIFICANT, union_}; } IncrementPrecision Precision::constructIncrement(uint64_t increment, digits_t magnitude) { - IncrementSettings settings; + IncrementSettings settings{}; // Note: For number formatting, fIncrement is used for RND_INCREMENT but not // RND_INCREMENT_ONE or RND_INCREMENT_FIVE. However, fIncrement is used in all // three when constructing a skeleton. settings.fIncrement = increment; settings.fIncrementMagnitude = magnitude; settings.fMinFrac = magnitude > 0 ? 0 : -magnitude; - PrecisionUnion union_; + PrecisionUnion union_{}; union_.increment = settings; if (increment == 1) { // NOTE: In C++, we must return the correct value type with the correct union. @@ -339,7 +339,7 @@ IncrementPrecision Precision::constructIncrement(uint64_t increment, digits_t ma } CurrencyPrecision Precision::constructCurrency(UCurrencyUsage usage) { - PrecisionUnion union_; + PrecisionUnion union_{}; union_.currencyUsage = usage; return {RND_CURRENCY, union_}; } diff --git a/contrib/libs/icu/i18n/number_skeletons.cpp b/contrib/libs/icu/i18n/number_skeletons.cpp index 562a8663d057..67a38dad0737 100644 --- a/contrib/libs/icu/i18n/number_skeletons.cpp +++ b/contrib/libs/icu/i18n/number_skeletons.cpp @@ -1015,6 +1015,12 @@ blueprint_helpers::parseExponentSignOption(const StringSegment& segment, MacroPr return true; } +// The function is called by skeleton::parseOption which called by skeleton::parseSkeleton +// the data pointed in the return macros.unit is stack allocated in the parseSkeleton function. +#if U_GCC_MAJOR_MINOR >= 1204 +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wdangling-pointer" +#endif void blueprint_helpers::parseCurrencyOption(const StringSegment& segment, MacroProps& macros, UErrorCode& status) { // Unlike ICU4J, have to check length manually because ICU4C CurrencyUnit does not check it for us @@ -1034,6 +1040,9 @@ void blueprint_helpers::parseCurrencyOption(const StringSegment& segment, MacroP // Slicing is OK macros.unit = currency; // NOLINT } +#if U_GCC_MAJOR_MINOR >= 1204 +#pragma GCC diagnostic pop +#endif void blueprint_helpers::generateCurrencyOption(const CurrencyUnit& currency, UnicodeString& sb, UErrorCode&) { diff --git a/contrib/libs/icu/i18n/olsontz.cpp b/contrib/libs/icu/i18n/olsontz.cpp index 9d9770dd4224..7826d47a7d06 100644 --- a/contrib/libs/icu/i18n/olsontz.cpp +++ b/contrib/libs/icu/i18n/olsontz.cpp @@ -436,11 +436,11 @@ int32_t OlsonTimeZone::getRawOffset() const { #if defined U_DEBUG_TZ void printTime(double ms) { - int32_t year, month, dom, dow; - double millis=0; - double days = ClockMath::floorDivide(((double)ms), (double)U_MILLIS_PER_DAY, millis); - - Grego::dayToFields(days, year, month, dom, dow); + int32_t year; + int8_t month, dom, dow; + int32_t millis=0; + UErrorCode status = U_ZERO_ERROR; + Grego::timeToFields(ms, year, month, dom, dow, millis, status); U_DEBUG_TZ_MSG((" getHistoricalOffset: time %.1f (%04d.%02d.%02d+%.1fh)\n", ms, year, month+1, dom, (millis/kOneHour))); } @@ -568,9 +568,8 @@ UBool OlsonTimeZone::useDaylightTime() const { return finalZone->useDaylightTime(); } - int32_t year, month, dom, dow, doy, mid; UErrorCode status = U_ZERO_ERROR; - Grego::timeToFields(current, year, month, dom, dow, doy, mid, status); + int32_t year = Grego::timeToYear(current, status); U_ASSERT(U_SUCCESS(status)); if (U_FAILURE(status)) return false; // If error, just return false. diff --git a/contrib/libs/icu/i18n/persncal.cpp b/contrib/libs/icu/i18n/persncal.cpp index 31f7ae252b5e..792a88807956 100644 --- a/contrib/libs/icu/i18n/persncal.cpp +++ b/contrib/libs/icu/i18n/persncal.cpp @@ -25,6 +25,9 @@ #include "umutex.h" #include "gregoimp.h" // Math #include +#include "cmemory.h" +#include "ucln_in.h" +#include "unicode/uniset.h" static const int16_t kPersianNumDays[] = {0,31,62,93,124,155,186,216,246,276,306,336}; // 0-based, for day-in-year @@ -62,6 +65,45 @@ static const int32_t kPersianCalendarLimits[UCAL_FIELD_COUNT][4] = { { 0, 0, 11, 11}, // ORDINAL_MONTH }; +namespace { // anonymous + +static const icu::UnicodeSet *gLeapCorrection = nullptr; +static icu::UInitOnce gCorrectionInitOnce {}; +static int32_t gMinCorrection; +} // namespace +U_CDECL_BEGIN +static UBool calendar_persian_cleanup() { + if (gLeapCorrection) { + delete gLeapCorrection; + gLeapCorrection = nullptr; + } + gCorrectionInitOnce.reset(); + return true; +} +U_CDECL_END + +namespace { // anonymous +static void U_CALLCONV initLeapCorrection() { + static int16_t nonLeapYears[] = { + 1502, 1601, 1634, 1667, 1700, 1733, 1766, 1799, 1832, 1865, 1898, 1931, 1964, 1997, 2030, 2059, + 2063, 2096, 2129, 2158, 2162, 2191, 2195, 2224, 2228, 2257, 2261, 2290, 2294, 2323, 2327, 2356, + 2360, 2389, 2393, 2422, 2426, 2455, 2459, 2488, 2492, 2521, 2525, 2554, 2558, 2587, 2591, 2620, + 2624, 2653, 2657, 2686, 2690, 2719, 2723, 2748, 2752, 2756, 2781, 2785, 2789, 2818, 2822, 2847, + 2851, 2855, 2880, 2884, 2888, 2913, 2917, 2921, 2946, 2950, 2954, 2979, 2983, 2987, + }; + gMinCorrection = nonLeapYears[0]; + icu::UnicodeSet prefab; + for (auto year : nonLeapYears) { + prefab.add(year); + } + gLeapCorrection = prefab.cloneAsThawed()->freeze(); + ucln_i18n_registerCleanup(UCLN_I18N_PERSIAN_CALENDAR, calendar_persian_cleanup); +} +const icu::UnicodeSet* getLeapCorrection() { + umtx_initOnce(gCorrectionInitOnce, &initLeapCorrection); + return gLeapCorrection; +} +} // namespace anonymous U_NAMESPACE_BEGIN static const int32_t PERSIAN_EPOCH = 1948320; @@ -83,7 +125,6 @@ PersianCalendar* PersianCalendar::clone() const { PersianCalendar::PersianCalendar(const Locale& aLocale, UErrorCode& success) : Calendar(TimeZone::forLocaleOrDefault(aLocale), aLocale, success) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } PersianCalendar::PersianCalendar(const PersianCalendar& other) : Calendar(other) { @@ -111,8 +152,15 @@ int32_t PersianCalendar::handleGetLimit(UCalendarDateFields field, ELimitType li */ UBool PersianCalendar::isLeapYear(int32_t year) { + if (year >= gMinCorrection && getLeapCorrection()->contains(year)) { + return false; + } + if (year > gMinCorrection && getLeapCorrection()->contains(year-1)) { + return true; + } int64_t y = static_cast(year) * 25LL + 11LL; - return (y % 33L < 8); + bool res = (y % 33L < 8); + return res; } /** @@ -157,7 +205,8 @@ int32_t PersianCalendar::handleGetMonthLength(int32_t extendedYear, int32_t mont /** * Return the number of days in the given Persian year */ -int32_t PersianCalendar::handleGetYearLength(int32_t extendedYear) const { +int32_t PersianCalendar::handleGetYearLength(int32_t extendedYear, UErrorCode& status) const { + if (U_FAILURE(status)) return 0; return isLeapYear(extendedYear) ? 366 : 365; } @@ -165,6 +214,15 @@ int32_t PersianCalendar::handleGetYearLength(int32_t extendedYear) const { // Functions for converting from field values to milliseconds.... //------------------------------------------------------------------------- +static int64_t firstJulianOfYear(int64_t year) { + int64_t julianDay = 365LL * (year - 1LL) + ClockMath::floorDivide(8LL * year + 21, 33); + if (year > gMinCorrection && getLeapCorrection()->contains(year-1)) { + julianDay--; + } + return julianDay; +} + + // Return JD of start of given month/year int64_t PersianCalendar::handleComputeMonthStart(int32_t eyear, int32_t month, UBool /*useMonth*/, UErrorCode& status) const { if (U_FAILURE(status)) { @@ -179,7 +237,7 @@ int64_t PersianCalendar::handleComputeMonthStart(int32_t eyear, int32_t month, U } } - int64_t julianDay = PERSIAN_EPOCH - 1LL + 365LL * (eyear - 1LL) + ClockMath::floorDivide(8LL * eyear + 21, 33); + int64_t julianDay = PERSIAN_EPOCH - 1LL + firstJulianOfYear(eyear); if (month != 0) { julianDay += kPersianNumDays[month]; @@ -219,6 +277,7 @@ int32_t PersianCalendar::handleGetExtendedYear(UErrorCode& status) { void PersianCalendar::handleComputeFields(int32_t julianDay, UErrorCode& status) { int64_t daysSinceEpoch = julianDay; daysSinceEpoch -= PERSIAN_EPOCH; + int64_t year = ClockMath::floorDivideInt64( 33LL * daysSinceEpoch + 3LL, 12053LL) + 1LL; if (year > INT32_MAX || year < INT32_MIN) { @@ -226,11 +285,16 @@ void PersianCalendar::handleComputeFields(int32_t julianDay, UErrorCode& status) return; } - int64_t farvardin1 = 365LL * (year - 1) + ClockMath::floorDivide(8LL * year + 21, 33); + int64_t farvardin1 = firstJulianOfYear(year); + int32_t dayOfYear = daysSinceEpoch - farvardin1; // 0-based U_ASSERT(dayOfYear >= 0); U_ASSERT(dayOfYear < 366); - // + + if (dayOfYear == 365 && year >= gMinCorrection && getLeapCorrection()->contains(year)) { + year++; + dayOfYear = 0; + } int32_t month; if (dayOfYear < 216) { // Compute 0-based month month = dayOfYear / 31; @@ -240,11 +304,11 @@ void PersianCalendar::handleComputeFields(int32_t julianDay, UErrorCode& status) U_ASSERT(month >= 0); U_ASSERT(month < 12); - int32_t dayOfMonth = dayOfYear - kPersianNumDays[month] + 1; + ++dayOfYear; // Make it 1-based now + int32_t dayOfMonth = dayOfYear - kPersianNumDays[month]; U_ASSERT(dayOfMonth > 0); U_ASSERT(dayOfMonth <= 31); - ++dayOfYear; // Make it 1-based now internalSet(UCAL_ERA, 0); internalSet(UCAL_YEAR, year); diff --git a/contrib/libs/icu/i18n/persncal.h b/contrib/libs/icu/i18n/persncal.h index daf7508b702a..d5bff7b23274 100644 --- a/contrib/libs/icu/i18n/persncal.h +++ b/contrib/libs/icu/i18n/persncal.h @@ -209,7 +209,7 @@ class PersianCalendar : public Calendar { * Return the number of days in the given Persian year * @internal */ - virtual int32_t handleGetYearLength(int32_t extendedYear) const override; + virtual int32_t handleGetYearLength(int32_t extendedYear, UErrorCode& status) const override; //------------------------------------------------------------------------- // Functions for converting from field values to milliseconds.... diff --git a/contrib/libs/icu/i18n/rbnf.cpp b/contrib/libs/icu/i18n/rbnf.cpp index c4e8ff73a7cc..5b6b5e2c1892 100644 --- a/contrib/libs/icu/i18n/rbnf.cpp +++ b/contrib/libs/icu/i18n/rbnf.cpp @@ -1568,12 +1568,12 @@ RuleBasedNumberFormat::init(const UnicodeString& rules, LocalizationInfo* locali // divide up the descriptions into individual rule-set descriptions // and store them in a temporary array. At each step, we also - // new up a rule set, but all this does is initialize its name + // create a rule set, but all this does is initialize its name // and remove it from its description. We can't actually parse // the rest of the descriptions and finish initializing everything // because we have to know the names and locations of all the rule // sets before we can actually set everything up - if(!numRuleSets) { + if (!numRuleSets) { status = U_ILLEGAL_ARGUMENT_ERROR; return; } @@ -1616,9 +1616,9 @@ RuleBasedNumberFormat::init(const UnicodeString& rules, LocalizationInfo* locali // last public rule set, no matter what the localization data says. initDefaultRuleSet(); - // finally, we can go back through the temporary descriptions - // list and finish setting up the substructure (and we throw - // away the temporary descriptions as we go) + // Now that we know all the rule names, we can go back through + // the temporary descriptions list and finish setting up the substructure + // (and we throw away the temporary descriptions as we go) { for (int i = 0; i < numRuleSets; i++) { fRuleSets[i]->parseRules(ruleSetDescriptions[i], status); @@ -1706,10 +1706,13 @@ RuleBasedNumberFormat::stripWhitespace(UnicodeString& description) UnicodeString result; int start = 0; - while (start != -1 && start < description.length()) { - // seek to the first non-whitespace character... + UChar ch; + while (start < description.length()) { + // Seek to the first non-whitespace character... + // If the first non-whitespace character is semicolon, skip it and continue while (start < description.length() - && PatternProps::isWhiteSpace(description.charAt(start))) { + && (PatternProps::isWhiteSpace(ch = description.charAt(start)) || ch == gSemiColon)) + { ++start; } @@ -1720,20 +1723,16 @@ RuleBasedNumberFormat::stripWhitespace(UnicodeString& description) // or if we don't find a semicolon, just copy the rest of // the string into the result result.append(description, start, description.length() - start); - start = -1; + break; } else if (p < description.length()) { result.append(description, start, p + 1 - start); start = p + 1; } - - // when we get here, we've seeked off the end of the string, and + // when we get here from the else, we've seeked off the end of the string, and // we terminate the loop (we continue until *start* is -1 rather // than until *p* is -1, because otherwise we'd miss the last // rule in the description) - else { - start = -1; - } } description.setTo(result); diff --git a/contrib/libs/icu/i18n/scriptset.cpp b/contrib/libs/icu/i18n/scriptset.cpp index eec1eeb37daf..576917e81c41 100644 --- a/contrib/libs/icu/i18n/scriptset.cpp +++ b/contrib/libs/icu/i18n/scriptset.cpp @@ -285,19 +285,19 @@ uhash_equalsScriptSet(const UElement key1, const UElement key2) { return (*s1 == *s2); } -U_CAPI int8_t U_EXPORT2 +U_CAPI int32_t U_EXPORT2 uhash_compareScriptSet(UElement key0, UElement key1) { icu::ScriptSet *s0 = static_cast(key0.pointer); icu::ScriptSet *s1 = static_cast(key1.pointer); int32_t diff = s0->countMembers() - s1->countMembers(); - if (diff != 0) return static_cast(diff); + if (diff != 0) return diff; int32_t i0 = s0->nextSetBit(0); int32_t i1 = s1->nextSetBit(0); while ((diff = i0-i1) == 0 && i0 > 0) { i0 = s0->nextSetBit(i0+1); i1 = s1->nextSetBit(i1+1); } - return (int8_t)diff; + return diff; } U_CAPI int32_t U_EXPORT2 diff --git a/contrib/libs/icu/i18n/scriptset.h b/contrib/libs/icu/i18n/scriptset.h index df5cfdc74868..d21d0db8a014 100644 --- a/contrib/libs/icu/i18n/scriptset.h +++ b/contrib/libs/icu/i18n/scriptset.h @@ -74,7 +74,7 @@ class U_I18N_API ScriptSet: public UMemory { U_NAMESPACE_END -U_CAPI UBool U_EXPORT2 +U_CAPI int32_t U_EXPORT2 uhash_compareScriptSet(const UElement key1, const UElement key2); U_CAPI int32_t U_EXPORT2 diff --git a/contrib/libs/icu/i18n/simpletz.cpp b/contrib/libs/icu/i18n/simpletz.cpp index cbefc29830ff..3f3b236ea45c 100644 --- a/contrib/libs/icu/i18n/simpletz.cpp +++ b/contrib/libs/icu/i18n/simpletz.cpp @@ -518,15 +518,10 @@ SimpleTimeZone::getOffsetFromLocal(UDate date, UTimeZoneLocalOption nonExistingT } rawOffsetGMT = getRawOffset(); - int32_t year, month, dom, dow, millis; - double dday = ClockMath::floorDivide(date, U_MILLIS_PER_DAY, &millis); - if (dday > INT32_MAX || dday < INT32_MIN) { - status = U_ILLEGAL_ARGUMENT_ERROR; - return; - } - int32_t day = dday; + int32_t year, millis; + int8_t month, dom, dow; - Grego::dayToFields(day, year, month, dom, dow, status); + Grego::timeToFields(date, year, month, dom, dow, millis, status); if (U_FAILURE(status)) return; savingsDST = getOffset(GregorianCalendar::AD, year, month, dom, @@ -554,8 +549,7 @@ SimpleTimeZone::getOffsetFromLocal(UDate date, UTimeZoneLocalOption nonExistingT } } if (recalc) { - day = ClockMath::floorDivide(date, U_MILLIS_PER_DAY, &millis); - Grego::dayToFields(day, year, month, dom, dow, status); + Grego::timeToFields(date, year, month, dom, dow, millis, status); if (U_FAILURE(status)) return; savingsDST = getOffset(GregorianCalendar::AD, year, month, dom, static_cast(dow), millis, diff --git a/contrib/libs/icu/i18n/smpdtfmt.cpp b/contrib/libs/icu/i18n/smpdtfmt.cpp index f79d4ae49532..3c13d5a413fa 100644 --- a/contrib/libs/icu/i18n/smpdtfmt.cpp +++ b/contrib/libs/icu/i18n/smpdtfmt.cpp @@ -77,6 +77,10 @@ #include "dayperiodrules.h" #include "tznames_impl.h" // ZONE_NAME_U16_MAX #include "number_utypes.h" +#include "chnsecal.h" +#include "dangical.h" +#include "japancal.h" +#include #if defined( U_DEBUG_CALSVC ) || defined (U_DEBUG_CAL) #include @@ -945,7 +949,8 @@ SimpleDateFormat::initialize(const Locale& locale, // if format is non-numeric (includes 年) and fDateOverride is not already specified. // Now this does get updated if applyPattern subsequently changes the pattern type. if (fDateOverride.isBogus() && fHasHanYearChar && - fCalendar != nullptr && uprv_strcmp(fCalendar->getType(),"japanese") == 0 && + fCalendar != nullptr && + typeid(*fCalendar) == typeid(JapaneseCalendar) && uprv_strcmp(fLocale.getLanguage(),"ja") == 0) { fDateOverride.setTo(u"y=jpanyear", -1); } @@ -1050,7 +1055,7 @@ SimpleDateFormat::_format(Calendar& cal, UnicodeString& appendTo, } Calendar* workCal = &cal; Calendar* calClone = nullptr; - if (&cal != fCalendar && uprv_strcmp(cal.getType(), fCalendar->getType()) != 0) { + if (&cal != fCalendar && typeid(cal) != typeid(*fCalendar)) { // Different calendar type // We use the time and time zone from the input calendar, but // do not use the input calendar for field calculation. @@ -1523,8 +1528,8 @@ SimpleDateFormat::subFormat(UnicodeString &appendTo, // "GGGG" is wide era name, "GGGGG" is narrow era name, anything else is abbreviated name case UDAT_ERA_FIELD: { - const auto* calType = cal.getType(); - if (uprv_strcmp(calType,"chinese") == 0 || uprv_strcmp(calType,"dangi") == 0) { + if (typeid(cal) == typeid(ChineseCalendar) || + typeid(cal) == typeid(DangiCalendar)) { zeroPaddingNumber(currentNumberFormat,appendTo, value, 1, 9); // as in ICU4J } else { if (count == 5) { @@ -1575,7 +1580,7 @@ SimpleDateFormat::subFormat(UnicodeString &appendTo, // for "MMMMM"/"LLLLL", use the narrow form case UDAT_MONTH_FIELD: case UDAT_STANDALONE_MONTH_FIELD: - if (uprv_strcmp(cal.getType(),"hebrew") == 0) { + if (typeid(cal) == typeid(HebrewCalendar)) { if (HebrewCalendar::isLeapYear(cal.get(UCAL_YEAR,status)) && value == 6 && count >= 3 ) value = 13; // Show alternate form for Adar II in leap years in Hebrew calendar. if (!HebrewCalendar::isLeapYear(cal.get(UCAL_YEAR,status)) && value >= 6 && count < 3 ) @@ -2272,7 +2277,7 @@ SimpleDateFormat::parse(const UnicodeString& text, Calendar& cal, ParsePosition& Calendar* calClone = nullptr; Calendar *workCal = &cal; - if (&cal != fCalendar && uprv_strcmp(cal.getType(), fCalendar->getType()) != 0) { + if (&cal != fCalendar && typeid(cal) != typeid(*fCalendar)) { // Different calendar type // We use the time/zone from the input calendar, but // do not use the input calendar for field calculation. @@ -2903,7 +2908,7 @@ int32_t SimpleDateFormat::matchAlphaMonthStrings(const UnicodeString& text, if (bestMatch >= 0) { // Adjustment for Hebrew Calendar month Adar II - if (!strcmp(cal.getType(),"hebrew") && bestMatch==13) { + if (typeid(cal) == typeid(HebrewCalendar) && bestMatch==13) { cal.set(UCAL_MONTH,6); } else { cal.set(UCAL_MONTH, bestMatch); @@ -2963,7 +2968,7 @@ int32_t SimpleDateFormat::matchString(const UnicodeString& text, if (bestMatch >= 0) { if (field < UCAL_FIELD_COUNT) { // Adjustment for Hebrew Calendar month Adar II - if (!strcmp(cal.getType(),"hebrew") && field==UCAL_MONTH && bestMatch==13) { + if (typeid(cal) == typeid(HebrewCalendar) && field==UCAL_MONTH && bestMatch==13) { cal.set(field,6); } else { if (field == UCAL_YEAR) { @@ -3052,7 +3057,6 @@ int32_t SimpleDateFormat::subParse(const UnicodeString& text, int32_t& start, ch if (numericLeapMonthFormatter != nullptr) { numericLeapMonthFormatter->setFormats(reinterpret_cast(¤tNumberFormat), 1); } - UBool isChineseCalendar = (uprv_strcmp(cal.getType(),"chinese") == 0 || uprv_strcmp(cal.getType(),"dangi") == 0); // If there are any spaces here, skip over them. If we hit the end // of the string, then fail. @@ -3068,6 +3072,8 @@ int32_t SimpleDateFormat::subParse(const UnicodeString& text, int32_t& start, ch } pos.setIndex(start); + UBool isChineseCalendar = typeid(cal) == typeid(ChineseCalendar) || + typeid(cal) == typeid(DangiCalendar); // We handle a few special cases here where we need to parse // a number value. We handle further, more generic cases below. We need // to handle some of them here because some fields require extra processing on @@ -3289,7 +3295,7 @@ int32_t SimpleDateFormat::subParse(const UnicodeString& text, int32_t& start, ch // When parsing month numbers from the Hebrew Calendar, we might need to adjust the month depending on whether // or not it was a leap year. We may or may not yet know what year it is, so might have to delay checking until // the year is parsed. - if (!strcmp(cal.getType(),"hebrew")) { + if (typeid(cal) == typeid(HebrewCalendar)) { HebrewCalendar *hc = (HebrewCalendar*)&cal; if (cal.isSet(UCAL_YEAR)) { UErrorCode monthStatus = U_ZERO_ERROR; @@ -3852,7 +3858,7 @@ int32_t SimpleDateFormat::subParse(const UnicodeString& text, int32_t& start, ch switch (patternCharIndex) { case UDAT_MONTH_FIELD: // See notes under UDAT_MONTH_FIELD case above - if (!strcmp(cal.getType(),"hebrew")) { + if (typeid(cal) == typeid(HebrewCalendar)) { HebrewCalendar *hc = (HebrewCalendar*)&cal; if (cal.isSet(UCAL_YEAR)) { UErrorCode monthStatus = U_ZERO_ERROR; @@ -4034,7 +4040,7 @@ SimpleDateFormat::applyPattern(const UnicodeString& pattern) // Hack to update use of Gannen year numbering for ja@calendar=japanese - // use only if format is non-numeric (includes 年) and no other fDateOverride. - if (fCalendar != nullptr && uprv_strcmp(fCalendar->getType(),"japanese") == 0 && + if (fCalendar != nullptr && typeid(*fCalendar) == typeid(JapaneseCalendar) && uprv_strcmp(fLocale.getLanguage(),"ja") == 0) { if (fDateOverride==UnicodeString(u"y=jpanyear") && !fHasHanYearChar) { // Gannen numbering is set but new pattern should not use it, unset; diff --git a/contrib/libs/icu/i18n/taiwncal.cpp b/contrib/libs/icu/i18n/taiwncal.cpp index e6ffd71ba308..1f9480310022 100644 --- a/contrib/libs/icu/i18n/taiwncal.cpp +++ b/contrib/libs/icu/i18n/taiwncal.cpp @@ -36,7 +36,6 @@ static const int32_t kGregorianEpoch = 1970; TaiwanCalendar::TaiwanCalendar(const Locale& aLocale, UErrorCode& success) : GregorianCalendar(aLocale, success) { - setTimeInMillis(getNow(), success); // Call this again now that the vtable is set up properly. } TaiwanCalendar::~TaiwanCalendar() @@ -48,12 +47,6 @@ TaiwanCalendar::TaiwanCalendar(const TaiwanCalendar& source) { } -TaiwanCalendar& TaiwanCalendar::operator= ( const TaiwanCalendar& right) -{ - GregorianCalendar::operator=(right); - return *this; -} - TaiwanCalendar* TaiwanCalendar::clone() const { return new TaiwanCalendar(*this); diff --git a/contrib/libs/icu/i18n/taiwncal.h b/contrib/libs/icu/i18n/taiwncal.h index a8fa3d1829ed..d12ab1c4a2ee 100644 --- a/contrib/libs/icu/i18n/taiwncal.h +++ b/contrib/libs/icu/i18n/taiwncal.h @@ -79,13 +79,6 @@ class TaiwanCalendar : public GregorianCalendar { */ TaiwanCalendar(const TaiwanCalendar& source); - /** - * Default assignment operator - * @param right the object to be copied. - * @internal - */ - TaiwanCalendar& operator=(const TaiwanCalendar& right); - /** * Create and return a polymorphic copy of this calendar. * @return return a polymorphic copy of this calendar. diff --git a/contrib/libs/icu/i18n/timezone.cpp b/contrib/libs/icu/i18n/timezone.cpp index 118dfe2f2af6..8028c4ecf5cb 100644 --- a/contrib/libs/icu/i18n/timezone.cpp +++ b/contrib/libs/icu/i18n/timezone.cpp @@ -730,15 +730,9 @@ void TimeZone::getOffset(UDate date, UBool local, int32_t& rawOffset, // (with 7 args) twice when local == true and DST is // detected in the initial call. for (int32_t pass=0; ; ++pass) { - int32_t year, month, dom, dow, millis; - double day = ClockMath::floorDivide(date, U_MILLIS_PER_DAY, &millis); - - // out of the range - if (day < INT32_MIN || day > INT32_MAX) { - ec = U_ILLEGAL_ARGUMENT_ERROR; - return; - } - Grego::dayToFields(day, year, month, dom, dow, ec); + int32_t year, millis; + int8_t month, dom, dow; + Grego::timeToFields(date, year, month, dom, dow, millis, ec); if (U_FAILURE(ec)) return; dstOffset = getOffset(GregorianCalendar::AD, year, month, dom, @@ -1057,7 +1051,7 @@ TimeZone::countEquivalentIDs(const UnicodeString& id) { // --------------------------------------- -const UnicodeString U_EXPORT2 +UnicodeString U_EXPORT2 TimeZone::getEquivalentID(const UnicodeString& id, int32_t index) { U_DEBUG_TZ_MSG(("gEI(%d)\n", index)); UnicodeString result; diff --git a/contrib/libs/icu/i18n/tzgnames.cpp b/contrib/libs/icu/i18n/tzgnames.cpp index 57ee984ee9ba..e7b09efd01a7 100644 --- a/contrib/libs/icu/i18n/tzgnames.cpp +++ b/contrib/libs/icu/i18n/tzgnames.cpp @@ -406,7 +406,7 @@ TZGNCore::initialize(const Locale& locale, UErrorCode& status) { int32_t regionLen = static_cast(uprv_strlen(region)); if (regionLen == 0) { CharString loc = ulocimp_addLikelySubtags(fLocale.getName(), status); - ulocimp_getSubtags(loc.data(), nullptr, nullptr, &fTargetRegion, nullptr, nullptr, status); + ulocimp_getSubtags(loc.toStringPiece(), nullptr, nullptr, &fTargetRegion, nullptr, nullptr, status); if (U_FAILURE(status)) { cleanup(); return; diff --git a/contrib/libs/icu/i18n/tznames_impl.cpp b/contrib/libs/icu/i18n/tznames_impl.cpp index 9b7ade7f0bb1..769c9a6526c5 100644 --- a/contrib/libs/icu/i18n/tznames_impl.cpp +++ b/contrib/libs/icu/i18n/tznames_impl.cpp @@ -2149,7 +2149,7 @@ TZDBTimeZoneNames::TZDBTimeZoneNames(const Locale& locale) if (regionLen == 0) { UErrorCode status = U_ZERO_ERROR; CharString loc = ulocimp_addLikelySubtags(fLocale.getName(), status); - ulocimp_getSubtags(loc.data(), nullptr, nullptr, &fRegion, nullptr, nullptr, status); + ulocimp_getSubtags(loc.toStringPiece(), nullptr, nullptr, &fRegion, nullptr, nullptr, status); if (U_SUCCESS(status)) { useWorld = false; } diff --git a/contrib/libs/icu/i18n/tzrule.cpp b/contrib/libs/icu/i18n/tzrule.cpp index 7507068c8807..8d6a37a844cb 100644 --- a/contrib/libs/icu/i18n/tzrule.cpp +++ b/contrib/libs/icu/i18n/tzrule.cpp @@ -355,9 +355,8 @@ AnnualTimeZoneRule::getNextStart(UDate base, int32_t prevDSTSavings, UBool inclusive, UDate& result) const { - int32_t year, month, dom, dow, doy, mid; UErrorCode status = U_ZERO_ERROR; - Grego::timeToFields(base, year, month, dom, dow, doy, mid, status); + int32_t year = Grego::timeToYear(base, status); U_ASSERT(U_SUCCESS(status)); if (year < fStartYear) { return getFirstStart(prevRawOffset, prevDSTSavings, result); @@ -381,9 +380,8 @@ AnnualTimeZoneRule::getPreviousStart(UDate base, int32_t prevDSTSavings, UBool inclusive, UDate& result) const { - int32_t year, month, dom, dow, doy, mid; UErrorCode status = U_ZERO_ERROR; - Grego::timeToFields(base, year, month, dom, dow, doy, mid, status); + int32_t year = Grego::timeToYear(base, status); U_ASSERT(U_SUCCESS(status)); if (year > fEndYear) { return getFinalStart(prevRawOffset, prevDSTSavings, result); diff --git a/contrib/libs/icu/i18n/ucln_in.h b/contrib/libs/icu/i18n/ucln_in.h index 765cdd559fb4..74868891c837 100644 --- a/contrib/libs/icu/i18n/ucln_in.h +++ b/contrib/libs/icu/i18n/ucln_in.h @@ -39,6 +39,7 @@ typedef enum ECleanupI18NType { UCLN_I18N_HEBREW_CALENDAR, UCLN_I18N_ASTRO_CALENDAR, UCLN_I18N_DANGI_CALENDAR, + UCLN_I18N_PERSIAN_CALENDAR, UCLN_I18N_CALENDAR, UCLN_I18N_TIMEZONEFORMAT, UCLN_I18N_TZDBTIMEZONENAMES, @@ -62,6 +63,7 @@ typedef enum ECleanupI18NType { UCLN_I18N_REGION, UCLN_I18N_LIST_FORMATTER, UCLN_I18N_NUMSYS, + UCLN_I18N_MF2_UNISETS, UCLN_I18N_COUNT /* This must be last */ } ECleanupI18NType; diff --git a/contrib/libs/icu/i18n/ucol_sit.cpp b/contrib/libs/icu/i18n/ucol_sit.cpp index 87387f879d83..f8fa02fad719 100644 --- a/contrib/libs/icu/i18n/ucol_sit.cpp +++ b/contrib/libs/icu/i18n/ucol_sit.cpp @@ -450,7 +450,7 @@ ucol_prepareShortStringOpen( const char *definition, ucol_sit_readSpecs(&s, definition, parseError, status); ucol_sit_calculateWholeLocale(&s, *status); - CharString buffer = ulocimp_canonicalize(s.locale.data(), *status); + CharString buffer = ulocimp_canonicalize(s.locale.toStringPiece(), *status); UResourceBundle *b = ures_open(U_ICUDATA_COLL, buffer.data(), status); /* we try to find stuff from keyword */ @@ -514,7 +514,7 @@ ucol_openFromShortString( const char *definition, #ifdef UCOL_TRACE_SIT fprintf(stderr, "DEF %s, DATA %s, ERR %s\n", definition, s.locale.data(), u_errorName(*status)); #endif - CharString buffer = ulocimp_canonicalize(s.locale.data(), *status); + CharString buffer = ulocimp_canonicalize(s.locale.toStringPiece(), *status); UCollator *result = ucol_open(buffer.data(), status); int32_t i = 0; diff --git a/contrib/libs/icu/i18n/units_converter.cpp b/contrib/libs/icu/i18n/units_converter.cpp index 3ccb0065bfca..1ab60bd4c060 100644 --- a/contrib/libs/icu/i18n/units_converter.cpp +++ b/contrib/libs/icu/i18n/units_converter.cpp @@ -49,6 +49,8 @@ void U_I18N_API Factor::divideBy(const Factor &rhs) { offset = std::max(rhs.offset, offset); } +void U_I18N_API Factor::divideBy(const uint64_t constant) { factorDen *= constant; } + void U_I18N_API Factor::power(int32_t power) { // multiply all the constant by the power. for (int i = 0; i < CONSTANTS_COUNT; i++) { @@ -239,6 +241,12 @@ Factor loadCompoundFactor(const MeasureUnitImpl &source, const ConversionRates & result.multiplyBy(singleFactor); } + // If the source has a constant denominator, then we need to divide the + // factor by the constant denominator. + if (source.constantDenominator != 0) { + result.divideBy(source.constantDenominator); + } + return result; } diff --git a/contrib/libs/icu/i18n/units_converter.h b/contrib/libs/icu/i18n/units_converter.h index 01fa557062fe..6f4b55f81d9b 100644 --- a/contrib/libs/icu/i18n/units_converter.h +++ b/contrib/libs/icu/i18n/units_converter.h @@ -82,6 +82,7 @@ struct U_I18N_API Factor { void multiplyBy(const Factor &rhs); void divideBy(const Factor &rhs); + void divideBy(const uint64_t constant); // Apply the power to the factor. void power(int32_t power); diff --git a/contrib/libs/icu/i18n/vtzone.cpp b/contrib/libs/icu/i18n/vtzone.cpp index 6067c5490e8d..8c0295bdcbe8 100644 --- a/contrib/libs/icu/i18n/vtzone.cpp +++ b/contrib/libs/icu/i18n/vtzone.cpp @@ -182,8 +182,9 @@ static UnicodeString& appendMillis(UDate date, UnicodeString& str) { */ static UnicodeString& getDateTimeString(UDate time, UnicodeString& str, UErrorCode& status) { if (U_FAILURE(status)) {return str;} - int32_t year, month, dom, dow, doy, mid; - Grego::timeToFields(time, year, month, dom, dow, doy, mid, status); + int32_t year, mid; + int8_t month, dom, dow; + Grego::timeToFields(time, year, month, dom, dow, mid, status); if (U_FAILURE(status)) {return str;} str.remove(); @@ -675,9 +676,10 @@ static TimeZoneRule* createRuleByRRULE(const UnicodeString& zonename, int rawOff } // Calculate start/end year and missing fields - int32_t startYear, startMonth, startDOM, startDOW, startDOY, startMID; + int32_t startYear, startMID; + int8_t startMonth, startDOM; Grego::timeToFields(start + fromOffset, startYear, startMonth, startDOM, - startDOW, startDOY, startMID, status); + startMID, status); if (U_FAILURE(status)) { return nullptr; } @@ -692,8 +694,7 @@ static TimeZoneRule* createRuleByRRULE(const UnicodeString& zonename, int rawOff int32_t endYear; if (until != MIN_MILLIS) { - int32_t endMonth, endDOM, endDOW, endDOY, endMID; - Grego::timeToFields(until, endYear, endMonth, endDOM, endDOW, endDOY, endMID, status); + endYear = Grego::timeToYear(until, status); if (U_FAILURE(status)) return nullptr; } else { endYear = AnnualTimeZoneRule::MAX_YEAR; @@ -1674,8 +1675,7 @@ VTimeZone::parse(UErrorCode& status) { status); } else { // Update the end year - int32_t y, m, d, dow, doy, mid; - Grego::timeToFields(start, y, m, d, dow, doy, mid, status); + int32_t y = Grego::timeToYear(start, status); if (U_FAILURE(status)) return; newRule.adoptInsteadAndCheckErrorCode( new AnnualTimeZoneRule( @@ -1902,7 +1902,8 @@ VTimeZone::writeZone(VTZWriter& w, BasicTimeZone& basictz, int32_t stdCount = 0; AnnualTimeZoneRule *finalStdRule = nullptr; - int32_t year, month, dom, dow, doy, mid; + int32_t year, mid; + int8_t month, dom, dow; UBool hasTransitions = false; TimeZoneTransition tzt; UBool tztAvail; @@ -1922,7 +1923,7 @@ VTimeZone::writeZone(VTZWriter& w, BasicTimeZone& basictz, int32_t fromOffset = tzt.getFrom()->getRawOffset() + tzt.getFrom()->getDSTSavings(); int32_t fromDSTSavings = tzt.getFrom()->getDSTSavings(); int32_t toOffset = tzt.getTo()->getRawOffset() + tzt.getTo()->getDSTSavings(); - Grego::timeToFields(tzt.getTime() + fromOffset, year, month, dom, dow, doy, mid, status); + Grego::timeToFields(tzt.getTime() + fromOffset, year, month, dom, dow, mid, status); if (U_FAILURE(status)) return; int32_t weekInMonth = Grego::dayOfWeekInMonth(year, month, dom); UBool sameRule = false; diff --git a/contrib/libs/icu/i18n/windtfmt.cpp b/contrib/libs/icu/i18n/windtfmt.cpp index 0241ec3b4424..f1d5c25f3ead 100644 --- a/contrib/libs/icu/i18n/windtfmt.cpp +++ b/contrib/libs/icu/i18n/windtfmt.cpp @@ -46,6 +46,7 @@ # define NOIME # define NOMCX #include +#include U_NAMESPACE_BEGIN @@ -251,7 +252,7 @@ UnicodeString &Win32DateFormat::format(Calendar &cal, UnicodeString &appendTo, F formatDate(&st_local, date); formatTime(&st_local, time); - if (strcmp(fCalendar->getType(), cal.getType()) != 0) { + if (typeid(cal) != typeid(*fCalendar)) { pattern = getTimeDateFormat(&cal, &fLocale, status); } @@ -272,7 +273,7 @@ void Win32DateFormat::parse(const UnicodeString& /* text */, Calendar& /* cal */ void Win32DateFormat::adoptCalendar(Calendar *newCalendar) { - if (fCalendar == nullptr || strcmp(fCalendar->getType(), newCalendar->getType()) != 0) { + if (fCalendar == nullptr || typeid(*fCalendar) != typeid(*newCalendar)) { UErrorCode status = U_ZERO_ERROR; if (fDateStyle != DateFormat::kNone && fTimeStyle != DateFormat::kNone) { diff --git a/contrib/libs/icu/icudt76_dat.rodata b/contrib/libs/icu/icudt77_dat.rodata similarity index 88% rename from contrib/libs/icu/icudt76_dat.rodata rename to contrib/libs/icu/icudt77_dat.rodata index adabcdc5f5c9..dc8b8ea6d078 100644 Binary files a/contrib/libs/icu/icudt76_dat.rodata and b/contrib/libs/icu/icudt77_dat.rodata differ diff --git a/contrib/libs/icu/include/unicode/brkiter.h b/contrib/libs/icu/include/unicode/brkiter.h index 30c59c4a94ac..d953925bd72a 100644 --- a/contrib/libs/icu/include/unicode/brkiter.h +++ b/contrib/libs/icu/include/unicode/brkiter.h @@ -58,6 +58,8 @@ U_NAMESPACE_END U_NAMESPACE_BEGIN +class CharString; + /** * The BreakIterator class implements methods for finding the location * of boundaries in text. BreakIterator is an abstract base class. @@ -646,9 +648,9 @@ class U_COMMON_API BreakIterator : public UObject { private: /** @internal (private) */ - char actualLocale[ULOC_FULLNAME_CAPACITY]; - char validLocale[ULOC_FULLNAME_CAPACITY]; - char requestLocale[ULOC_FULLNAME_CAPACITY]; + CharString* actualLocale = nullptr; + CharString* validLocale = nullptr; + CharString* requestLocale = nullptr; }; #ifndef U_HIDE_DEPRECATED_API diff --git a/contrib/libs/icu/include/unicode/calendar.h b/contrib/libs/icu/include/unicode/calendar.h index a04f5b65bd5b..4499e281f9c5 100644 --- a/contrib/libs/icu/include/unicode/calendar.h +++ b/contrib/libs/icu/include/unicode/calendar.h @@ -55,6 +55,7 @@ class ICUServiceFactory; typedef int32_t UFieldResolutionTable[12][8]; class BasicTimeZone; +class CharString; /** * `Calendar` is an abstract base class for converting between * a `UDate` object and a set of integer fields such as @@ -1692,10 +1693,9 @@ class U_I18N_API Calendar : public UObject { * calendar system. Subclasses should override this method if they can * provide a more correct or more efficient implementation than the * default implementation in Calendar. - * @stable ICU 2.0 + * @internal */ - virtual int32_t handleGetYearLength(int32_t eyear) const; - + virtual int32_t handleGetYearLength(int32_t eyear, UErrorCode& status) const; /** * Return the extended year defined by the current fields. This will @@ -1881,42 +1881,7 @@ class U_I18N_API Calendar : public UObject { */ int32_t getActualHelper(UCalendarDateFields field, int32_t startValue, int32_t endValue, UErrorCode &status) const; - protected: - /** - * The flag which indicates if the current time is set in the calendar. - * @stable ICU 2.0 - */ - UBool fIsTimeSet; - - /** - * True if the fields are in sync with the currently set time of this Calendar. - * If false, then the next attempt to get the value of a field will - * force a recomputation of all fields from the current value of the time - * field. - *

- * This should really be named areFieldsInSync, but the old name is retained - * for backward compatibility. - * @stable ICU 2.0 - */ - UBool fAreFieldsSet; - - /** - * True if all of the fields have been set. This is initially false, and set to - * true by computeFields(). - * @stable ICU 2.0 - */ - UBool fAreAllFieldsSet; - - /** - * True if all fields have been virtually set, but have not yet been - * computed. This occurs only in setTimeInMillis(). A calendar set - * to this state will compute all fields from the time if it becomes - * necessary, but otherwise will delay such computation. - * @stable ICU 3.0 - */ - UBool fAreFieldsVirtuallySet; - /** * Get the current time without recomputing. * @@ -1940,14 +1905,7 @@ class U_I18N_API Calendar : public UObject { */ int32_t fFields[UCAL_FIELD_COUNT]; -#ifndef U_FORCE_HIDE_DEPRECATED_API - /** - * The flags which tell if a specified time field for the calendar is set. - * @deprecated ICU 2.8 use (fStamp[n]!=kUnset) - */ - UBool fIsSet[UCAL_FIELD_COUNT]; -#endif // U_FORCE_HIDE_DEPRECATED_API - +protected: /** Special values of stamp[] * @stable ICU 2.0 */ @@ -1957,14 +1915,15 @@ class U_I18N_API Calendar : public UObject { kMinimumUserStamp }; +private: /** * Pseudo-time-stamps which specify when each field was set. There * are two special values, UNSET and INTERNALLY_SET. Values from - * MINIMUM_USER_SET to Integer.MAX_VALUE are legal user set values. - * @stable ICU 2.0 + * MINIMUM_USER_SET to STAMP_MAX are legal user set values. */ - int32_t fStamp[UCAL_FIELD_COUNT]; + int8_t fStamp[UCAL_FIELD_COUNT]; +protected: /** * Subclasses may override this method to compute several fields * specific to each calendar system. These are: @@ -2178,7 +2137,7 @@ class U_I18N_API Calendar : public UObject { /** * The next available value for fStamp[] */ - int32_t fNextStamp;// = MINIMUM_USER_STAMP; + int8_t fNextStamp = kMinimumUserStamp; /** * Recalculates the time stamp array (fStamp). @@ -2189,30 +2148,60 @@ class U_I18N_API Calendar : public UObject { /** * The current time set for the calendar. */ - UDate fTime; + UDate fTime = 0; /** - * @see #setLenient + * Time zone affects the time calculation done by Calendar. Calendar subclasses use + * the time zone data to produce the local time. Always set; never nullptr. */ - UBool fLenient; + TimeZone* fZone = nullptr; /** - * Time zone affects the time calculation done by Calendar. Calendar subclasses use - * the time zone data to produce the local time. Always set; never nullptr. + * The flag which indicates if the current time is set in the calendar. + */ + bool fIsTimeSet:1; + + /** + * True if the fields are in sync with the currently set time of this Calendar. + * If false, then the next attempt to get the value of a field will + * force a recomputation of all fields from the current value of the time + * field. + *

+ * This should really be named areFieldsInSync, but the old name is retained + * for backward compatibility. + */ + bool fAreFieldsSet:1; + + /** + * True if all of the fields have been set. This is initially false, and set to + * true by computeFields(). + */ + bool fAreAllFieldsSet:1; + + /** + * True if all fields have been virtually set, but have not yet been + * computed. This occurs only in setTimeInMillis(). A calendar set + * to this state will compute all fields from the time if it becomes + * necessary, but otherwise will delay such computation. */ - TimeZone* fZone; + bool fAreFieldsVirtuallySet:1; + + /** + * @see #setLenient + */ + bool fLenient:1; /** * Option for repeated wall time * @see #setRepeatedWallTimeOption */ - UCalendarWallTimeOption fRepeatedWallTime; + UCalendarWallTimeOption fRepeatedWallTime:3; // Somehow MSVC need 3 bits for UCalendarWallTimeOption /** * Option for skipped wall time * @see #setSkippedWallTimeOption */ - UCalendarWallTimeOption fSkippedWallTime; + UCalendarWallTimeOption fSkippedWallTime:3; // Somehow MSVC need 3 bits for UCalendarWallTimeOption /** * Both firstDayOfWeek and minimalDaysInFirstWeek are locale-dependent. They are @@ -2222,11 +2211,14 @@ class U_I18N_API Calendar : public UObject { * out the week count for a specific date for a given locale. These must be set when * a Calendar is constructed. */ - UCalendarDaysOfWeek fFirstDayOfWeek; - uint8_t fMinimalDaysInFirstWeek; - UCalendarDaysOfWeek fWeekendOnset; + UCalendarDaysOfWeek fFirstDayOfWeek:4; // Somehow MSVC need 4 bits for + // UCalendarDaysOfWeek + UCalendarDaysOfWeek fWeekendOnset:4; // Somehow MSVC need 4 bits for + // UCalendarDaysOfWeek + UCalendarDaysOfWeek fWeekendCease:4; // Somehow MSVC need 4 bits for + // UCalendarDaysOfWeek + uint8_t fMinimalDaysInFirstWeek; int32_t fWeekendOnsetMillis; - UCalendarDaysOfWeek fWeekendCease; int32_t fWeekendCeaseMillis; /** @@ -2264,32 +2256,24 @@ class U_I18N_API Calendar : public UObject { * returned by getGregorianMonth(). * @see #computeGregorianFields */ - int32_t fGregorianMonth; + int8_t fGregorianMonth; /** - * The Gregorian day of the year, as computed by - * computeGregorianFields() and returned by getGregorianDayOfYear(). + * The Gregorian day of the month, as computed by + * computeGregorianFields() and returned by getGregorianDayOfMonth(). * @see #computeGregorianFields */ - int32_t fGregorianDayOfYear; + int8_t fGregorianDayOfMonth; /** - * The Gregorian day of the month, as computed by - * computeGregorianFields() and returned by getGregorianDayOfMonth(). + * The Gregorian day of the year, as computed by + * computeGregorianFields() and returned by getGregorianDayOfYear(). * @see #computeGregorianFields */ - int32_t fGregorianDayOfMonth; + int16_t fGregorianDayOfYear; /* calculations */ - /** - * Compute the Gregorian calendar year, month, and day of month from - * the given Julian day. These values are not stored in fields, but in - * member variables gregorianXxx. Also compute the DAY_OF_WEEK and - * DOW_LOCAL fields. - */ - void computeGregorianAndDOWFields(int32_t julianDay, UErrorCode &ec); - protected: /** @@ -2359,8 +2343,8 @@ class U_I18N_API Calendar : public UObject { #endif /* U_HIDE_INTERNAL_API */ private: - char validLocale[ULOC_FULLNAME_CAPACITY]; - char actualLocale[ULOC_FULLNAME_CAPACITY]; + CharString* validLocale = nullptr; + CharString* actualLocale = nullptr; public: #if !UCONFIG_NO_SERVICE @@ -2563,7 +2547,6 @@ Calendar::internalSet(UCalendarDateFields field, int32_t value) { fFields[field] = value; fStamp[field] = kInternallySet; - fIsSet[field] = true; // Remove later } /** diff --git a/contrib/libs/icu/include/unicode/char16ptr.h b/contrib/libs/icu/include/unicode/char16ptr.h index daf35cd43ba2..049de9efee81 100644 --- a/contrib/libs/icu/include/unicode/char16ptr.h +++ b/contrib/libs/icu/include/unicode/char16ptr.h @@ -9,10 +9,13 @@ #include "unicode/utypes.h" -#if U_SHOW_CPLUSPLUS_API +#if U_SHOW_CPLUSPLUS_API || U_SHOW_CPLUSPLUS_HEADER_API #include #include +#include + +#endif /** * \file @@ -21,8 +24,6 @@ * Also conversion functions from char16_t * to UChar * and OldUChar *. */ -U_NAMESPACE_BEGIN - /** * \def U_ALIASING_BARRIER * Barrier for pointer anti-aliasing optimizations even across function boundaries. @@ -36,6 +37,11 @@ U_NAMESPACE_BEGIN # define U_ALIASING_BARRIER(ptr) #endif +// ICU DLL-exported +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + /** * char16_t * wrapper with implicit conversion from distinct but bit-compatible pointer types. * @stable ICU 59 @@ -251,6 +257,60 @@ const char16_t *ConstChar16Ptr::get() const { return u_.cp; } #endif /// \endcond +U_NAMESPACE_END + +#endif // U_SHOW_CPLUSPLUS_API + +// Usable in header-only definitions +#if U_SHOW_CPLUSPLUS_API || U_SHOW_CPLUSPLUS_HEADER_API + +namespace U_ICU_NAMESPACE_OR_INTERNAL { + +#ifndef U_FORCE_HIDE_INTERNAL_API +/** @internal */ +template>> +inline const char16_t *uprv_char16PtrFromUChar(const T *p) { + if constexpr (std::is_same_v) { + return p; + } else { +#if U_SHOW_CPLUSPLUS_API + return ConstChar16Ptr(p).get(); +#else +#ifdef U_ALIASING_BARRIER + U_ALIASING_BARRIER(p); +#endif + return reinterpret_cast(p); +#endif + } +} +#if !U_CHAR16_IS_TYPEDEF && (!defined(_LIBCPP_VERSION) || _LIBCPP_VERSION < 180000) +/** @internal */ +inline const char16_t *uprv_char16PtrFromUint16(const uint16_t *p) { +#if U_SHOW_CPLUSPLUS_API + return ConstChar16Ptr(p).get(); +#else +#ifdef U_ALIASING_BARRIER + U_ALIASING_BARRIER(p); +#endif + return reinterpret_cast(p); +#endif +} +#endif +#if U_SIZEOF_WCHAR_T==2 +/** @internal */ +inline const char16_t *uprv_char16PtrFromWchar(const wchar_t *p) { +#if U_SHOW_CPLUSPLUS_API + return ConstChar16Ptr(p).get(); +#else +#ifdef U_ALIASING_BARRIER + U_ALIASING_BARRIER(p); +#endif + return reinterpret_cast(p); +#endif +} +#endif +#endif + /** * Converts from const char16_t * to const UChar *. * Includes an aliasing barrier if available. @@ -307,6 +367,15 @@ inline OldUChar *toOldUCharPtr(char16_t *p) { return reinterpret_cast(p); } +} // U_ICU_NAMESPACE_OR_INTERNAL + +#endif // U_SHOW_CPLUSPLUS_API || U_SHOW_CPLUSPLUS_HEADER_API + +// ICU DLL-exported +#if U_SHOW_CPLUSPLUS_API + +U_NAMESPACE_BEGIN + #ifndef U_FORCE_HIDE_INTERNAL_API /** * Is T convertible to a std::u16string_view or some other 16-bit string view? @@ -379,6 +448,6 @@ inline std::u16string_view toU16StringViewNullable(const T& text) { U_NAMESPACE_END -#endif /* U_SHOW_CPLUSPLUS_API */ +#endif // U_SHOW_CPLUSPLUS_API #endif // __CHAR16PTR_H__ diff --git a/contrib/libs/icu/include/unicode/dcfmtsym.h b/contrib/libs/icu/include/unicode/dcfmtsym.h index 02e12f9c39b2..3aecceda03a6 100644 --- a/contrib/libs/icu/include/unicode/dcfmtsym.h +++ b/contrib/libs/icu/include/unicode/dcfmtsym.h @@ -48,6 +48,7 @@ U_NAMESPACE_BEGIN +class CharString; /** * This class represents the set of symbols needed by DecimalFormat * to format numbers. DecimalFormat creates for itself an instance of @@ -504,8 +505,8 @@ class U_I18N_API DecimalFormatSymbols : public UObject { Locale locale; - char actualLocale[ULOC_FULLNAME_CAPACITY]; - char validLocale[ULOC_FULLNAME_CAPACITY]; + CharString* actualLocale = nullptr; + CharString* validLocale = nullptr; const char16_t* currPattern = nullptr; UnicodeString currencySpcBeforeSym[UNUM_CURRENCY_SPACING_COUNT]; diff --git a/contrib/libs/icu/include/unicode/dtfmtsym.h b/contrib/libs/icu/include/unicode/dtfmtsym.h index df8da36d8153..18e2641b588f 100644 --- a/contrib/libs/icu/include/unicode/dtfmtsym.h +++ b/contrib/libs/icu/include/unicode/dtfmtsym.h @@ -43,6 +43,7 @@ U_NAMESPACE_BEGIN /* forward declaration */ class SimpleDateFormat; class Hashtable; +class CharString; /** * DateFormatSymbols is a public class for encapsulating localizable date-time @@ -917,8 +918,8 @@ class U_I18N_API DateFormatSymbols final : public UObject { /** valid/actual locale information * these are always ICU locales, so the length should not be a problem */ - char validLocale[ULOC_FULLNAME_CAPACITY]; - char actualLocale[ULOC_FULLNAME_CAPACITY]; + CharString* validLocale = nullptr; + CharString* actualLocale = nullptr; DateFormatSymbols() = delete; // default constructor not implemented diff --git a/contrib/libs/icu/include/unicode/format.h b/contrib/libs/icu/include/unicode/format.h index a21e61ad56d8..3d435f0de7e3 100644 --- a/contrib/libs/icu/include/unicode/format.h +++ b/contrib/libs/icu/include/unicode/format.h @@ -45,6 +45,7 @@ U_NAMESPACE_BEGIN +class CharString; /** * Base class for all formats. This is an abstract base class which * specifies the protocol for classes which convert other objects or @@ -297,8 +298,8 @@ class U_I18N_API Format : public UObject { UParseError& parseError); private: - char actualLocale[ULOC_FULLNAME_CAPACITY]; - char validLocale[ULOC_FULLNAME_CAPACITY]; + CharString* actualLocale = nullptr; + CharString* validLocale = nullptr; }; U_NAMESPACE_END diff --git a/contrib/libs/icu/include/unicode/gregocal.h b/contrib/libs/icu/include/unicode/gregocal.h index 5112548522d5..cd84471c9ba1 100644 --- a/contrib/libs/icu/include/unicode/gregocal.h +++ b/contrib/libs/icu/include/unicode/gregocal.h @@ -518,7 +518,7 @@ class U_I18N_API GregorianCalendar: public Calendar { * default implementation in Calendar. * @stable ICU 2.0 */ - virtual int32_t handleGetYearLength(int32_t eyear) const override; + virtual int32_t handleGetYearLength(int32_t eyear, UErrorCode& status) const override; /** * return the length of the given month. diff --git a/contrib/libs/icu/include/unicode/locid.h b/contrib/libs/icu/include/unicode/locid.h index e1afd598cf9b..a394cd9347db 100644 --- a/contrib/libs/icu/include/unicode/locid.h +++ b/contrib/libs/icu/include/unicode/locid.h @@ -449,6 +449,11 @@ class U_COMMON_API Locale : public UObject { */ static Locale U_EXPORT2 createFromName(const char *name); +#ifndef U_HIDE_INTERNAL_API + /** @internal */ + static Locale U_EXPORT2 createFromName(StringPiece name); +#endif /* U_HIDE_INTERNAL_API */ + /** * Creates a locale from the given string after canonicalizing * the string according to CLDR by calling uloc_canonicalize(). @@ -1133,7 +1138,9 @@ class U_COMMON_API Locale : public UObject { * @param cLocaleID The new locale name. * @param canonicalize whether to call uloc_canonicalize on cLocaleID */ - Locale& init(const char* cLocaleID, UBool canonicalize); + Locale& init(const char* localeID, UBool canonicalize); + /** @internal */ + Locale& init(StringPiece localeID, UBool canonicalize); /* * Internal constructor to allow construction of a locale object with diff --git a/contrib/libs/icu/include/unicode/measunit.h b/contrib/libs/icu/include/unicode/measunit.h index b23897192eb4..f0abd4f4f92f 100644 --- a/contrib/libs/icu/include/unicode/measunit.h +++ b/contrib/libs/icu/include/unicode/measunit.h @@ -105,21 +105,19 @@ typedef enum UMeasurePrefix { */ UMEASURE_PREFIX_YOTTA = UMEASURE_PREFIX_ONE + 24, -#ifndef U_HIDE_DRAFT_API /** * SI prefix: ronna, 10^27. * - * @draft ICU 75 + * @stable ICU 75 */ UMEASURE_PREFIX_RONNA = UMEASURE_PREFIX_ONE + 27, /** * SI prefix: quetta, 10^30. * - * @draft ICU 75 + * @stable ICU 75 */ UMEASURE_PREFIX_QUETTA = UMEASURE_PREFIX_ONE + 30, -#endif /* U_HIDE_DRAFT_API */ #ifndef U_HIDE_INTERNAL_API /** @@ -268,21 +266,19 @@ typedef enum UMeasurePrefix { */ UMEASURE_PREFIX_YOCTO = UMEASURE_PREFIX_ONE + -24, -#ifndef U_HIDE_DRAFT_API /** * SI prefix: ronto, 10^-27. * - * @draft ICU 75 + * @stable ICU 75 */ UMEASURE_PREFIX_RONTO = UMEASURE_PREFIX_ONE + -27, /** * SI prefix: quecto, 10^-30. * - * @draft ICU 75 + * @stable ICU 75 */ UMEASURE_PREFIX_QUECTO = UMEASURE_PREFIX_ONE + -30, -#endif /* U_HIDE_DRAFT_API */ #ifndef U_HIDE_INTERNAL_API /** @@ -430,16 +426,19 @@ class U_I18N_API MeasureUnit: public UObject { MeasureUnit(MeasureUnit &&other) noexcept; /** - * Construct a MeasureUnit from a CLDR Core Unit Identifier, defined in UTS - * 35. (Core unit identifiers and mixed unit identifiers are supported, long - * unit identifiers are not.) Validates and canonicalizes the identifier. + * Constructs a MeasureUnit from a CLDR Core Unit Identifier, as defined in UTS 35. + * This method supports core unit identifiers and mixed unit identifiers. + * It validates and canonicalizes the given identifier. + * * + * Example usage: *

-     * MeasureUnit example = MeasureUnit::forIdentifier("furlong-per-nanosecond")
+     * MeasureUnit example = MeasureUnit::forIdentifier("meter-per-second", status);
      * 
* - * @param identifier The CLDR Unit Identifier. - * @param status Set if the identifier is invalid. + * @param identifier the CLDR Unit Identifier + * @param status Set error if the identifier is invalid. + * @return the corresponding MeasureUnit * @stable ICU 67 */ static MeasureUnit forIdentifier(StringPiece identifier, UErrorCode& status); @@ -552,6 +551,44 @@ class U_I18N_API MeasureUnit: public UObject { */ UMeasurePrefix getPrefix(UErrorCode& status) const; +#ifndef U_HIDE_DRAFT_API + + /** + * Creates a new MeasureUnit with a specified constant denominator. + * + * This method is applicable only to COMPOUND and SINGLE units. If invoked on a + * MIXED unit, an error will be set in the status. + * + * NOTE: If the constant denominator is set to 0, it means that you are removing + * the constant denominator. + * + * @param denominator The constant denominator to set. + * @param status Set if this is not a COMPOUND or SINGLE unit or if another error occurs. + * @return A new MeasureUnit with the specified constant denominator. + * @draft ICU 77 + */ + MeasureUnit withConstantDenominator(uint64_t denominator, UErrorCode &status) const; + + /** + * Retrieves the constant denominator for this COMPOUND unit. + * + * Examples: + * - For the unit "liter-per-1000-kiloliter", the constant denominator is 1000. + * - For the unit "liter-per-kilometer", the constant denominator is zero. + * + * This method is applicable only to COMPOUND and SINGLE units. If invoked on + * a MIXED unit, an error will be set in the status. + * + * NOTE: If no constant denominator exists, the method returns 0. + * + * @param status Set if this is not a COMPOUND or SINGLE unit or if another error occurs. + * @return The value of the constant denominator. + * @draft ICU 77 + */ + uint64_t getConstantDenominator(UErrorCode &status) const; + +#endif /* U_HIDE_DRAFT_API */ + /** * Creates a MeasureUnit which is this SINGLE unit augmented with the specified dimensionality * (power). For example, if dimensionality is 2, the unit will be squared. @@ -591,7 +628,9 @@ class U_I18N_API MeasureUnit: public UObject { * NOTE: Only works on SINGLE and COMPOUND units. If this is a MIXED unit, an error will * occur. For more information, see UMeasureUnitComplexity. * - * @param status Set if this is a MIXED unit or if another error occurs. + * NOTE: An Error will be returned for units that have a constant denominator. + * + * @param status Set if this is a MIXED unit, has a constant denominator or if another error occurs. * @return The reciprocal of the target unit. * @stable ICU 67 */ @@ -627,6 +666,10 @@ class U_I18N_API MeasureUnit: public UObject { * * If this is a SINGLE unit, an array of length 1 will be returned. * + * NOTE: For units with a constant denominator, the returned single units will + * not include the constant denominator. To obtain the constant denominator, + * retrieve it from the original unit. + * * @param status Set if an error occurs. * @return A pair with the list of units as a LocalArray and the number of units in the list. * @stable ICU 68 @@ -1152,6 +1195,24 @@ class U_I18N_API MeasureUnit: public UObject { */ static MeasureUnit getPermyriad(); +#ifndef U_HIDE_DRAFT_API + /** + * Returns by pointer, unit of concentr: portion-per-1e9. + * Caller owns returned value and must free it. + * Also see {@link #getPortionPer1E9()}. + * @param status ICU error code. + * @draft ICU 77 + */ + static MeasureUnit *createPortionPer1E9(UErrorCode &status); + + /** + * Returns by value, unit of concentr: portion-per-1e9. + * Also see {@link #createPortionPer1E9()}. + * @draft ICU 77 + */ + static MeasureUnit getPortionPer1E9(); +#endif /* U_HIDE_DRAFT_API */ + /** * Returns by pointer, unit of consumption: liter-per-100-kilometer. * Caller owns returned value and must free it. diff --git a/contrib/libs/icu/include/unicode/messageformat2.h b/contrib/libs/icu/include/unicode/messageformat2.h index c5459f042f40..926d14318d17 100644 --- a/contrib/libs/icu/include/unicode/messageformat2.h +++ b/contrib/libs/icu/include/unicode/messageformat2.h @@ -8,6 +8,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -20,6 +22,7 @@ #include "unicode/messageformat2_arguments.h" #include "unicode/messageformat2_data_model.h" #include "unicode/messageformat2_function_registry.h" +#include "unicode/normalizer2.h" #include "unicode/unistr.h" #ifndef U_HIDE_DEPRECATED_API @@ -30,8 +33,8 @@ namespace message2 { class Environment; class MessageContext; - class ResolvedSelector; class StaticErrors; + class InternalValue; /** *

MessageFormatter is a Technical Preview API implementing MessageFormat 2.0. @@ -325,6 +328,8 @@ namespace message2 { private: friend class Builder; + friend class Checker; + friend class MessageArguments; friend class MessageContext; MessageFormatter(const MessageFormatter::Builder& builder, UErrorCode &status); @@ -334,9 +339,6 @@ namespace message2 { // Do not define default assignment operator const MessageFormatter &operator=(const MessageFormatter &) = delete; - ResolvedSelector resolveVariables(const Environment& env, const data_model::Operand&, MessageContext&, UErrorCode &) const; - ResolvedSelector resolveVariables(const Environment& env, const data_model::Expression&, MessageContext&, UErrorCode &) const; - // Selection methods // Takes a vector of FormattedPlaceholders @@ -346,31 +348,35 @@ namespace message2 { // Takes a vector of vectors of strings (input) and a vector of PrioritizedVariants (input/output) void sortVariants(const UVector&, UVector&, UErrorCode&) const; // Takes a vector of strings (input) and a vector of strings (output) - void matchSelectorKeys(const UVector&, MessageContext&, ResolvedSelector&& rv, UVector&, UErrorCode&) const; + void matchSelectorKeys(const UVector&, MessageContext&, InternalValue* rv, UVector&, UErrorCode&) const; // Takes a vector of FormattedPlaceholders (input), // and a vector of vectors of strings (output) void resolvePreferences(MessageContext&, UVector&, UVector&, UErrorCode&) const; // Formatting methods + + // Used for normalizing variable names and keys for comparison + UnicodeString normalizeNFC(const UnicodeString&) const; [[nodiscard]] FormattedPlaceholder formatLiteral(const data_model::Literal&) const; void formatPattern(MessageContext&, const Environment&, const data_model::Pattern&, UErrorCode&, UnicodeString&) const; - // Formats a call to a formatting function + // Evaluates a function call // Dispatches on argument type - [[nodiscard]] FormattedPlaceholder evalFormatterCall(FormattedPlaceholder&& argument, - MessageContext& context, - UErrorCode& status) const; + [[nodiscard]] InternalValue* evalFunctionCall(FormattedPlaceholder&& argument, + MessageContext& context, + UErrorCode& status) const; // Dispatches on function name - [[nodiscard]] FormattedPlaceholder evalFormatterCall(const FunctionName& functionName, - FormattedPlaceholder&& argument, - FunctionOptions&& options, - MessageContext& context, - UErrorCode& status) const; - // Formats an expression that appears as a selector - ResolvedSelector formatSelectorExpression(const Environment& env, const data_model::Expression&, MessageContext&, UErrorCode&) const; + [[nodiscard]] InternalValue* evalFunctionCall(const FunctionName& functionName, + InternalValue* argument, + FunctionOptions&& options, + MessageContext& context, + UErrorCode& status) const; // Formats an expression that appears in a pattern or as the definition of a local variable - [[nodiscard]] FormattedPlaceholder formatExpression(const Environment&, const data_model::Expression&, MessageContext&, UErrorCode&) const; + [[nodiscard]] InternalValue* formatExpression(const Environment&, + const data_model::Expression&, + MessageContext&, + UErrorCode&) const; [[nodiscard]] FunctionOptions resolveOptions(const Environment& env, const OptionMap&, MessageContext&, UErrorCode&) const; - [[nodiscard]] FormattedPlaceholder formatOperand(const Environment&, const data_model::Operand&, MessageContext&, UErrorCode&) const; + [[nodiscard]] InternalValue* formatOperand(const Environment&, const data_model::Operand&, MessageContext&, UErrorCode&) const; [[nodiscard]] FormattedPlaceholder evalArgument(const data_model::VariableName&, MessageContext&, UErrorCode&) const; void formatSelectors(MessageContext& context, const Environment& env, UErrorCode &status, UnicodeString& result) const; @@ -445,6 +451,10 @@ namespace message2 { // formatting methods return best-effort output. // The default is false. bool signalErrors = false; + + // Used for implementing normalizeNFC() + const Normalizer2* nfcNormalizer = nullptr; + }; // class MessageFormatter } // namespace message2 @@ -457,6 +467,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_H diff --git a/contrib/libs/icu/include/unicode/messageformat2_arguments.h b/contrib/libs/icu/include/unicode/messageformat2_arguments.h index c43d96191f16..07c96f892bca 100644 --- a/contrib/libs/icu/include/unicode/messageformat2_arguments.h +++ b/contrib/libs/icu/include/unicode/messageformat2_arguments.h @@ -8,6 +8,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -43,7 +45,7 @@ template class U_I18N_API LocalArray; namespace message2 { - class MessageContext; + class MessageFormatter; // Arguments // ---------- @@ -112,7 +114,9 @@ namespace message2 { private: friend class MessageContext; - const Formattable* getArgument(const data_model::VariableName&, UErrorCode&) const; + const Formattable* getArgument(const MessageFormatter&, + const data_model::VariableName&, + UErrorCode&) const; // Avoids using Hashtable so that code constructing a Hashtable // doesn't have to appear in this header file @@ -131,6 +135,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_ARGUMENTS_H diff --git a/contrib/libs/icu/include/unicode/messageformat2_data_model.h b/contrib/libs/icu/include/unicode/messageformat2_data_model.h index 0c836af1bdfd..fd9b6432a5d1 100644 --- a/contrib/libs/icu/include/unicode/messageformat2_data_model.h +++ b/contrib/libs/icu/include/unicode/messageformat2_data_model.h @@ -8,6 +8,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -2211,7 +2213,7 @@ namespace message2 { friend class MFDataModel; - Matcher(Expression* ss, int32_t ns, Variant* vs, int32_t nv); + Matcher(VariableName* ss, int32_t ns, Variant* vs, int32_t nv); Matcher() {} // A Matcher may have numSelectors=0 and numVariants=0 @@ -2219,8 +2221,8 @@ namespace message2 { // So we have to keep a separate flag to track failed copies. bool bogus = false; - // The expressions that are being matched on. - LocalArray selectors; + // The variables that are being matched on. + LocalArray selectors; // The number of selectors int32_t numSelectors = 0; // The list of `when` clauses (case arms). @@ -2328,13 +2330,13 @@ namespace message2 { * @internal ICU 75 technology preview * @deprecated This API is for technology preview only. */ - const std::vector getSelectors() const { + std::vector getSelectors() const { if (std::holds_alternative(body)) { return {}; } const Matcher* match = std::get_if(&body); // match must be non-null, given the previous check - return toStdVector(match->selectors.getAlias(), match->numSelectors); + return toStdVector(match->selectors.getAlias(), match->numSelectors); } /** * Accesses the variants. Returns an empty vector if this is a pattern message. @@ -2462,17 +2464,17 @@ namespace message2 { */ Builder& addBinding(Binding&& b, UErrorCode& status); /** - * Adds a selector expression. Copies `expression`. + * Adds a selector variable. * If a pattern was previously set, clears the pattern. * - * @param selector Expression to add as a selector. Passed by move. + * @param selector Variable to add as a selector. Passed by move. * @param errorCode Input/output error code * @return A reference to the builder. * * @internal ICU 75 technology preview * @deprecated This API is for technology preview only. */ - Builder& addSelector(Expression&& selector, UErrorCode& errorCode) noexcept; + Builder& addSelector(VariableName&& selector, UErrorCode& errorCode); /** * Adds a single variant. * If a pattern was previously set using `setPattern()`, clears the pattern. @@ -2564,7 +2566,7 @@ namespace message2 { int32_t bindingsLen = 0; const Binding* getLocalVariablesInternal() const; - const Expression* getSelectorsInternal() const; + const VariableName* getSelectorsInternal() const; const Variant* getVariantsInternal() const; int32_t numSelectors() const { @@ -2592,6 +2594,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT_DATA_MODEL_H diff --git a/contrib/libs/icu/include/unicode/messageformat2_formattable.h b/contrib/libs/icu/include/unicode/messageformat2_formattable.h index 8a779adb9ab3..d7f4130f493b 100644 --- a/contrib/libs/icu/include/unicode/messageformat2_formattable.h +++ b/contrib/libs/icu/include/unicode/messageformat2_formattable.h @@ -8,6 +8,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -549,6 +551,7 @@ class U_I18N_API FunctionOptions : public UObject { */ FunctionOptions& operator=(const FunctionOptions&) = delete; private: + friend class InternalValue; friend class MessageFormatter; friend class StandardFunctions; @@ -566,12 +569,10 @@ class U_I18N_API FunctionOptions : public UObject { // that code in the header because it would have to call internal Hashtable methods. ResolvedFunctionOption* options; int32_t functionOptionsLen = 0; -}; // class FunctionOptions - - // TODO doc comments - // Encapsulates either a formatted string or formatted number; - // more output types could be added in the future. + // Returns a new FunctionOptions + FunctionOptions mergeOptions(FunctionOptions&& other, UErrorCode&); +}; // class FunctionOptions /** * A `FormattedValue` represents the result of formatting a `message2::Formattable`. @@ -1010,6 +1011,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_FORMATTABLE_H diff --git a/contrib/libs/icu/include/unicode/messageformat2_function_registry.h b/contrib/libs/icu/include/unicode/messageformat2_function_registry.h index b8429e3b83aa..37690d5e04a1 100644 --- a/contrib/libs/icu/include/unicode/messageformat2_function_registry.h +++ b/contrib/libs/icu/include/unicode/messageformat2_function_registry.h @@ -8,6 +8,8 @@ #if U_SHOW_CPLUSPLUS_API +#if !UCONFIG_NO_NORMALIZATION + #if !UCONFIG_NO_FORMATTING #if !UCONFIG_NO_MF2 @@ -422,6 +424,8 @@ U_NAMESPACE_END #endif /* #if !UCONFIG_NO_FORMATTING */ +#endif /* #if !UCONFIG_NO_NORMALIZATION */ + #endif /* U_SHOW_CPLUSPLUS_API */ #endif // MESSAGEFORMAT2_FUNCTION_REGISTRY_H diff --git a/contrib/libs/icu/include/unicode/numberformatter.h b/contrib/libs/icu/include/unicode/numberformatter.h index b02d987ce2bc..28531afeb10f 100644 --- a/contrib/libs/icu/include/unicode/numberformatter.h +++ b/contrib/libs/icu/include/unicode/numberformatter.h @@ -2609,12 +2609,11 @@ class U_I18N_API LocalizedNumberFormatter */ Format* toFormat(UErrorCode& status) const; -#ifndef U_HIDE_DRAFT_API /** * Disassociate the locale from this formatter. * * @return The fluent chain. - * @draft ICU 75 + * @stable ICU 75 */ UnlocalizedNumberFormatter withoutLocale() const &; @@ -2623,10 +2622,9 @@ class U_I18N_API LocalizedNumberFormatter * * @return The fluent chain. * @see #withoutLocale - * @draft ICU 75 + * @stable ICU 75 */ UnlocalizedNumberFormatter withoutLocale() &&; -#endif // U_HIDE_DRAFT_API /** * Default constructor: puts the formatter into a valid but undefined state. diff --git a/contrib/libs/icu/include/unicode/numberrangeformatter.h b/contrib/libs/icu/include/unicode/numberrangeformatter.h index b8bbc1ba072d..bb6e43bed8cf 100644 --- a/contrib/libs/icu/include/unicode/numberrangeformatter.h +++ b/contrib/libs/icu/include/unicode/numberrangeformatter.h @@ -503,12 +503,11 @@ class U_I18N_API LocalizedNumberRangeFormatter FormattedNumberRange formatFormattableRange( const Formattable& first, const Formattable& second, UErrorCode& status) const; -#ifndef U_HIDE_DRAFT_API /** * Disassociate the locale from this formatter. * * @return The fluent chain. - * @draft ICU 75 + * @stable ICU 75 */ UnlocalizedNumberRangeFormatter withoutLocale() const &; @@ -517,10 +516,9 @@ class U_I18N_API LocalizedNumberRangeFormatter * * @return The fluent chain. * @see #withoutLocale - * @draft ICU 75 + * @stable ICU 75 */ UnlocalizedNumberRangeFormatter withoutLocale() &&; -#endif // U_HIDE_DRAFT_API /** * Default constructor: puts the formatter into a valid but undefined state. diff --git a/contrib/libs/icu/include/unicode/rbnf.h b/contrib/libs/icu/include/unicode/rbnf.h index f42d91d776fe..5a23f723363c 100644 --- a/contrib/libs/icu/include/unicode/rbnf.h +++ b/contrib/libs/icu/include/unicode/rbnf.h @@ -88,23 +88,24 @@ enum URBNFRuleSetTag { }; /** - * The RuleBasedNumberFormat class formats numbers according to a set of rules. This number formatter is - * typically used for spelling out numeric values in words (e.g., 25,3476 as - * "twenty-five thousand three hundred seventy-six" or "vingt-cinq mille trois + * The RuleBasedNumberFormat class formats numbers according to a set of rules. + * + *

This number formatter is typically used for spelling out numeric values in words (e.g., 25,3476 + * as "twenty-five thousand three hundred seventy-six" or "vingt-cinq mille trois * cents soixante-seize" or * "fünfundzwanzigtausenddreihundertsechsundsiebzig"), but can also be used for * other complicated formatting tasks, such as formatting a number of seconds as hours, - * minutes and seconds (e.g., 3,730 as "1:02:10"). + * minutes and seconds (e.g., 3,730 as "1:02:10").

* *

The resources contain three predefined formatters for each locale: spellout, which * spells out a value in words (123 is "one hundred twenty-three"); ordinal, which * appends an ordinal suffix to the end of a numeral (123 is "123rd"); and * duration, which shows a duration in seconds as hours, minutes, and seconds (123 is - * "2:03").  The client can also define more specialized RuleBasedNumberFormats + * "2:03").  The client can also define more specialized RuleBasedNumberFormats * by supplying programmer-defined rule sets.

* - *

The behavior of a RuleBasedNumberFormat is specified by a textual description - * that is either passed to the constructor as a String or loaded from a resource + *

The behavior of a RuleBasedNumberFormat is specified by a textual description + * that is either passed to the constructor as a String or loaded from a resource * bundle. In its simplest form, the description consists of a semicolon-delimited list of rules. * Each rule has a string of output text and a value or range of values it is applicable to. * In a typical spellout rule set, the first twenty rules are the words for the numbers from @@ -116,7 +117,8 @@ enum URBNFRuleSetTag { *

For larger numbers, we can use the preceding set of rules to format the ones place, and * we only have to supply the words for the multiples of 10:

* - *
 20: twenty[->>];
+ * 
+ * 20: twenty[->>];
  * 30: thirty[->>];
  * 40: forty[->>];
  * 50: fifty[->>];
@@ -137,7 +139,8 @@ enum URBNFRuleSetTag {
  * 

For even larger numbers, we can actually look up several parts of the number in the * list:

* - *
100: << hundred[ >>];
+ *
+ * 100: << hundred[ >>];
* *

The "<<" represents a new kind of substitution. The << isolates * the hundreds digit (and any digits to its left), formats it using this same rule set, and @@ -155,13 +158,15 @@ enum URBNFRuleSetTag { * *

This rule covers values up to 999, at which point we add another rule:

* - *
1000: << thousand[ >>];
+ *
+ * 1000: << thousand[ >>];
* *

Again, the meanings of the brackets and substitution tokens shift because the rule's * base value is a higher power of 10, changing the rule's divisor. This rule can actually be * used all the way up to 999,999. This allows us to finish out the rules as follows:

* - *
 1,000,000: << million[ >>];
+ * 
+ * 1,000,000: << million[ >>];
  * 1,000,000,000: << billion[ >>];
  * 1,000,000,000,000: << trillion[ >>];
  * 1,000,000,000,000,000: OUT OF RANGE!;
@@ -177,30 +182,30 @@ enum URBNFRuleSetTag { *

To see how these rules actually work in practice, consider the following example: * Formatting 25,430 with this rule set would work like this:

* - * + *
* - * - * + * + * * * - * - * + * + * * * - * - * + * + * * * - * - * + * + * * * - * - * + * + * * * - * - * + * * *
<< thousand >>[the rule whose base value is 1,000 is applicable to 25,340]<< thousand >>[the rule whose base value is 1,000 is applicable to 25,340]
twenty->> thousand >>[25,340 over 1,000 is 25. The rule for 20 applies.]twenty->> thousand >>[25,340 over 1,000 is 25. The rule for 20 applies.]
twenty-five thousand >>[25 mod 10 is 5. The rule for 5 is "five."twenty-five thousand >>[25 mod 10 is 5. The rule for 5 is "five."
twenty-five thousand << hundred >>[25,340 mod 1,000 is 340. The rule for 100 applies.]twenty-five thousand << hundred >>[25,340 mod 1,000 is 340. The rule for 100 applies.]
twenty-five thousand three hundred >>[340 over 100 is 3. The rule for 3 is "three."]twenty-five thousand three hundred >>[340 over 100 is 3. The rule for 3 is "three."]
twenty-five thousand three hundred forty[340 mod 100 is 40. The rule for 40 applies. Since 40 divides + * twenty-five thousand three hundred forty[340 mod 100 is 40. The rule for 40 applies. Since 40 divides * evenly by 10, the hyphen and substitution in the brackets are omitted.]
@@ -237,20 +242,20 @@ enum URBNFRuleSetTag { * *
* - *

The description of a RuleBasedNumberFormat's behavior consists of one or more rule + *

The description of a RuleBasedNumberFormat's behavior consists of one or more rule * sets. Each rule set consists of a name, a colon, and a list of rules. A rule * set name must begin with a % sign. Rule sets with names that begin with a single % sign * are public: the caller can specify that they be used to format and parse numbers. * Rule sets with names that begin with %% are private: they exist only for the use * of other rule sets. If a formatter only has one rule set, the name may be omitted.

* - *

The user can also specify a special "rule set" named %%lenient-parse. - * The body of %%lenient-parse isn't a set of number-formatting rules, but a RuleBasedCollator + *

The user can also specify a special "rule set" named %%lenient-parse. + * The body of %%lenient-parse isn't a set of number-formatting rules, but a RuleBasedCollator * description which is used to define equivalences for lenient parsing. For more information - * on the syntax, see RuleBasedCollator. For more information on lenient parsing, - * see setLenientParse(). Note: symbols that have syntactic meaning + * on the syntax, see RuleBasedCollator. For more information on lenient parsing, + * see setLenientParse(). Note: symbols that have syntactic meaning * in collation rules, such as '&', have no particular meaning when appearing outside - * of the lenient-parse rule set.

+ * of the lenient-parse rule set.

* *

The body of a rule set consists of an ordered, semicolon-delimited list of rules. * Internally, every rule has a base value, a divisor, rule text, and zero, one, or two substitutions. @@ -260,42 +265,46 @@ enum URBNFRuleSetTag { *

A rule descriptor can take one of the following forms (text in italics is the * name of a token):

* - * + *
* - * - * + * + * + * + * + * * - * - * - * + * + * * - * - * - * + * + * * - * - * - * + * + * * - * - * - * + * + * + * * - * - * - * + * + * * - * - * - * + * + * + * the punctuation of either the full stop or comma * - * - * - * + * + * + * the punctuation of either the full stop or comma * - * - * - * + * + * + * * - * - * - * + * + * + * * - * - * - * + * + * @@ -352,8 +361,8 @@ enum URBNFRuleSetTag { * algorithms: If the rule set is a regular rule set, do the following: * *
    - *
  • If the rule set includes a default rule (and the number was passed in as a double), - * use the default rule.  (If the number being formatted was passed in as a long, + *
  • If the rule set includes a default rule (and the number was passed in as a double), + * use the default rule.  (If the number being formatted was passed in as a long, * the default rule is ignored.)
  • *
  • If the number is negative, use the negative-number rule.
  • *
  • If the number has a fractional part and is greater than 1, use the improper fraction @@ -400,42 +409,43 @@ enum URBNFRuleSetTag { * *

    The meanings of the substitution token characters are as follows:

    * - *
bv:bv specifies the rule's base value. bv is a decimal + * DescriptorDescription
bv:bv specifies the rule's base value. bv is a decimal * number expressed using ASCII digits. bv may contain spaces, period, and commas, * which are ignored. The rule's divisor is the highest power of 10 less than or equal to * the base value.
bv/rad:bv specifies the rule's base value. The rule's divisor is the + *
bv/rad:bv specifies the rule's base value. The rule's divisor is the * highest power of rad less than or equal to the base value.
bv>:bv specifies the rule's base value. To calculate the divisor, + *
bv>:bv specifies the rule's base value. To calculate the divisor, * let the radix be 10, and the exponent be the highest exponent of the radix that yields a * result less than or equal to the base value. Every > character after the base value * decreases the exponent by 1. If the exponent is positive or 0, the divisor is the radix * raised to the power of the exponent; otherwise, the divisor is 1.
bv/rad>:bv specifies the rule's base value. To calculate the divisor, + *
bv/rad>:bv specifies the rule's base value. To calculate the divisor, * let the radix be rad, and the exponent be the highest exponent of the radix that * yields a result less than or equal to the base value. Every > character after the radix * decreases the exponent by 1. If the exponent is positive or 0, the divisor is the radix * raised to the power of the exponent; otherwise, the divisor is 1.
-x:The rule is a negative-number rule.
-x:The rule is a negative-number rule.
x.x:The rule is an improper fraction rule. If the full stop in + *
x.x:The rule is an improper fraction rule. If the full stop in * the middle of the rule name is replaced with the decimal point * that is used in the language or DecimalFormatSymbols, then that rule will * have precedence when formatting and parsing this rule. For example, some @@ -304,39 +313,39 @@ enum URBNFRuleSetTag { * handle the decimal point that matches the language's natural spelling of * the punctuation of either the full stop or comma.
0.x:The rule is a proper fraction rule. If the full stop in + *
0.x:The rule is a proper fraction rule. If the full stop in * the middle of the rule name is replaced with the decimal point * that is used in the language or DecimalFormatSymbols, then that rule will * have precedence when formatting and parsing this rule. For example, some * languages use the comma, and can thus be written as 0,x instead. For example, * you can use "0.x: point >>;0,x: comma >>;" to * handle the decimal point that matches the language's natural spelling of - * the punctuation of either the full stop or comma.
x.0:The rule is a default rule. If the full stop in + *
x.0:The rule is a default rule. If the full stop in * the middle of the rule name is replaced with the decimal point * that is used in the language or DecimalFormatSymbols, then that rule will * have precedence when formatting and parsing this rule. For example, some * languages use the comma, and can thus be written as x,0 instead. For example, * you can use "x.0: << point;x,0: << comma;" to * handle the decimal point that matches the language's natural spelling of - * the punctuation of either the full stop or comma.
Inf:The rule for infinity.
Inf:The rule for infinity.
NaN:The rule for an IEEE 754 NaN (not a number).
NaN:The rule for an IEEE 754 NaN (not a number).
nothingIf the rule's rule descriptor is left out, the base value is one plus the + *
nothingIf the rule's rule descriptor is left out, the base value is one plus the * preceding rule's base value (or zero if this is the first rule in the list) in a normal * rule set.  In a fraction rule set, the base value is the same as the preceding rule's * base value.
+ *
* - * - * + * + * + * + * + * + * + * * * * - * - * + * * * * - * - * + * * * * - * - * + * * * - * - * - * + * + * + * * * * - * - * + * * * - * - * - * + * + * + * * * * - * - * + * * * * - * - * + * * * * - * - * + * * * - * - * - * + * + * + * * * - * - * - * - * + * + * + * + * * * - * - * - * + * + * * * - * - * - * + * + * * * - * - * - * + * + * * * - * - * + * * * * - * - * - * + * + * * - * - * - * - * + * + * + * * * - * - * - * - * + * + * + * * * *
>>in normal ruleSyntaxUsageDescription
>>in normal ruleDivide the number by the rule's divisor and format the remainder
in negative-number rulein negative-number ruleFind the absolute value of the number and format the result
in fraction or default rulein fraction or default ruleIsolate the number's fractional part and format it.
in rule in fraction rule setin rule in fraction rule setNot allowed.
>>>in normal rule
>>>in normal ruleDivide the number by the rule's divisor and format the remainder, * but bypass the normal rule-selection process and just use the * rule that precedes this one in this rule list.
in all other rulesin all other rulesNot allowed.
<<in normal rule
<<in normal ruleDivide the number by the rule's divisor, perform floor() on the quotient, * and format the resulting value.
* If there is a DecimalFormat pattern between the < characters and the @@ -448,73 +458,93 @@ enum URBNFRuleSetTag { *
in negative-number rulein negative-number ruleNot allowed.
in fraction or default rulein fraction or default ruleIsolate the number's integral part and format it.
in rule in fraction rule setin rule in fraction rule setMultiply the number by the rule's base value and format the result.
==in all rule sets
==in all rule setsFormat the number unchanged
[]in normal ruleOmit the optional text if the number is an even multiple of the rule's divisor
[]
[|]
in normal rule + *
    + *
  • When the number is not an even multiple of the rule's divisor, use the text and rules between the beginning square bracket, + * and the end square bracket or the | symbol.
  • + *
  • When the number is an even multiple of the rule's divisor, and no | symbol is used, omit the text.
  • + *
  • When the number is an even multiple of the rule's divisor, and | symbol is used, use the text and rules between the | symbol, + * and the end square bracket.
  • + *
+ *
in negative-number ruleNot allowed.in improper-fraction ruleThis syntax is the same as specifying both an x.x rule and a 0.x rule. + *
    + *
  • When the number is not between 0 and 1, use the text and rules between the beginning square bracket, + * and the end square bracket or the | symbol.
  • + *
  • When the number is between 0 and 1, and no | symbol is used, omit the text.
  • + *
  • When the number is between 0 and 1, and | symbol is used, use the text and rules between the | symbol, + * and the end square bracket.
  • + *
+ *
in improper-fraction ruleOmit the optional text if the number is between 0 and 1 (same as specifying both an - * x.x rule and a 0.x rule)in default ruleThis syntax is the same as specifying both an x.x rule and an x.0 rule. + *
    + *
  • When the number is not an integer, use the text and rules between the beginning square bracket, + * and the end square bracket or the | symbol.
  • + *
  • When the number is an integer, and no | symbol is used, omit the text.
  • + *
  • When the number is an integer, and | symbol is used, use the text and rules between the | symbol, + * and the end square bracket.
  • + *
+ *
in default ruleOmit the optional text if the number is an integer (same as specifying both an x.x - * rule and an x.0 rule)in rule in fraction rule set + *
    + *
  • When multiplying the number by the rule's base value does not yield 1, use the text and rules between the beginning square bracket, + * and the end square bracket or the | symbol.
  • + *
  • When multiplying the number by the rule's base value yields 1, and no | symbol is used, omit the text.
  • + *
  • When multiplying the number by the rule's base value yields 1, and | symbol is used, use the text and rules between the | symbol, + * and the end square bracket.
  • + *
+ *
in proper-fraction rulein proper-fraction ruleNot allowed.
in rule in fraction rule setOmit the optional text if multiplying the number by the rule's base value yields 1.in negative-number ruleNot allowed.
$(cardinal,plural syntax)$in all rule sets
$(cardinal,plural syntax)$in all rule setsThis provides the ability to choose a word based on the number divided by the radix to the power of the * exponent of the base value for the specified locale, which is normally equivalent to the << value. - * This uses the cardinal plural rules from PluralFormat. All strings used in the plural format are treated + * This uses the cardinal plural rules from {@link PluralFormat}. All strings used in the plural format are treated * as the same base value for parsing.
$(ordinal,plural syntax)$in all rule sets
$(ordinal,plural syntax)$in all rule setsThis provides the ability to choose a word based on the number divided by the radix to the power of the * exponent of the base value for the specified locale, which is normally equivalent to the << value. - * This uses the ordinal plural rules from PluralFormat. All strings used in the plural format are treated + * This uses the ordinal plural rules from {@link PluralFormat}. All strings used in the plural format are treated * as the same base value for parsing.
@@ -522,22 +552,25 @@ enum URBNFRuleSetTag { *

The substitution descriptor (i.e., the text between the token characters) may take one * of three forms:

* - * + *
* - * + * + * + * + * + * * * - * - * + * + * * * - * - * + * + * *
a rule set nameDescriptorDescription
a rule set namePerform the mathematical operation on the number, and format the result using the * named rule set.
a DecimalFormat pattern
a DecimalFormat patternPerform the mathematical operation on the number, and format the result using a * DecimalFormat with the specified pattern.  The pattern must begin with 0 or #.
nothing
nothingPerform the mathematical operation on the number, and format the result using the rule - * set containing the current rule, except: - *
    + * set containing the current rule, except:
      *
    • You can't have an empty substitution descriptor with a == substitution.
    • *
    • If you omit the substitution descriptor in a >> substitution in a fraction rule, * format the result one digit at a time using the rule set containing the current rule.
    • diff --git a/contrib/libs/icu/include/unicode/resbund.h b/contrib/libs/icu/include/unicode/resbund.h index 3965371729d8..03ff6faee239 100644 --- a/contrib/libs/icu/include/unicode/resbund.h +++ b/contrib/libs/icu/include/unicode/resbund.h @@ -450,7 +450,7 @@ class U_COMMON_API ResourceBundle : public UObject { * @return a Locale object * @stable ICU 2.8 */ - const Locale + Locale getLocale(ULocDataLocaleType type, UErrorCode &status) const; #ifndef U_HIDE_INTERNAL_API /** diff --git a/contrib/libs/icu/include/unicode/simplenumberformatter.h b/contrib/libs/icu/include/unicode/simplenumberformatter.h index d0121c2b97ec..83fa8a8b1c92 100644 --- a/contrib/libs/icu/include/unicode/simplenumberformatter.h +++ b/contrib/libs/icu/include/unicode/simplenumberformatter.h @@ -78,14 +78,12 @@ class U_I18N_API SimpleNumber : public UMemory { */ void roundTo(int32_t power, UNumberFormatRoundingMode roundingMode, UErrorCode& status); -#ifndef U_HIDE_DRAFT_API /** * Sets the number of integer digits to the given amount, truncating if necessary. * - * @draft ICU 75 + * @stable ICU 75 */ void setMaximumIntegerDigits(uint32_t maximumIntegerDigits, UErrorCode& status); -#endif // U_HIDE_DRAFT_API /** * Pads the beginning of the number with zeros up to the given minimum number of integer digits. diff --git a/contrib/libs/icu/include/unicode/timezone.h b/contrib/libs/icu/include/unicode/timezone.h index b19900b76712..9591b7d90aff 100644 --- a/contrib/libs/icu/include/unicode/timezone.h +++ b/contrib/libs/icu/include/unicode/timezone.h @@ -323,7 +323,7 @@ class U_I18N_API TimeZone : public UObject { * @see #countEquivalentIDs * @stable ICU 2.0 */ - static const UnicodeString U_EXPORT2 getEquivalentID(const UnicodeString& id, + static UnicodeString U_EXPORT2 getEquivalentID(const UnicodeString& id, int32_t index); /** diff --git a/contrib/libs/icu/include/unicode/uchar.h b/contrib/libs/icu/include/unicode/uchar.h index 0daa7dd2141c..82ec63ab524e 100644 --- a/contrib/libs/icu/include/unicode/uchar.h +++ b/contrib/libs/icu/include/unicode/uchar.h @@ -675,14 +675,14 @@ typedef enum UProperty { * @stable ICU 63 */ UCHAR_VERTICAL_ORIENTATION=0x1018, -#ifndef U_HIDE_DRAFT_API /** * Enumerated property Identifier_Status. * Used for UTS #39 General Security Profile for Identifiers * (https://www.unicode.org/reports/tr39/#General_Security_Profile). - * @draft ICU 75 + * @stable ICU 75 */ UCHAR_IDENTIFIER_STATUS=0x1019, +#ifndef U_HIDE_DRAFT_API /** * Enumerated property Indic_Conjunct_Break. * Used in the grapheme cluster break algorithm in UAX #29. @@ -796,7 +796,6 @@ typedef enum UProperty { UCHAR_SCRIPT_EXTENSIONS=0x7000, /** First constant for Unicode properties with unusual value types. @stable ICU 4.6 */ UCHAR_OTHER_PROPERTY_START=UCHAR_SCRIPT_EXTENSIONS, -#ifndef U_HIDE_DRAFT_API /** * Miscellaneous property Identifier_Type. * Used for UTS #39 General Security Profile for Identifiers @@ -808,10 +807,9 @@ typedef enum UProperty { * * @see u_hasIDType * @see u_getIDTypes - * @draft ICU 75 + * @stable ICU 75 */ UCHAR_IDENTIFIER_TYPE=0x7001, -#endif // U_HIDE_DRAFT_API #ifndef U_HIDE_DEPRECATED_API /** * One more than the last constant for Unicode properties with unusual value types. @@ -2791,13 +2789,12 @@ typedef enum UVerticalOrientation { U_VO_UPRIGHT, } UVerticalOrientation; -#ifndef U_HIDE_DRAFT_API /** * Identifier Status constants. * See https://www.unicode.org/reports/tr39/#Identifier_Status_and_Type. * * @see UCHAR_IDENTIFIER_STATUS - * @draft ICU 75 + * @stable ICU 75 */ typedef enum UIdentifierStatus { /* @@ -2806,9 +2803,9 @@ typedef enum UIdentifierStatus { * U_ID_STATUS_ */ - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_STATUS_RESTRICTED, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_STATUS_ALLOWED, } UIdentifierStatus; @@ -2817,7 +2814,7 @@ typedef enum UIdentifierStatus { * See https://www.unicode.org/reports/tr39/#Identifier_Status_and_Type. * * @see UCHAR_IDENTIFIER_TYPE - * @draft ICU 75 + * @stable ICU 75 */ typedef enum UIdentifierType { /* @@ -2826,32 +2823,31 @@ typedef enum UIdentifierType { * U_ID_TYPE_ */ - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_NOT_CHARACTER, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_DEPRECATED, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_DEFAULT_IGNORABLE, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_NOT_NFKC, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_NOT_XID, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_EXCLUSION, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_OBSOLETE, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_TECHNICAL, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_UNCOMMON_USE, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_LIMITED_USE, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_INCLUSION, - /** @draft ICU 75 */ + /** @stable ICU 75 */ U_ID_TYPE_RECOMMENDED, } UIdentifierType; -#endif // U_HIDE_DRAFT_API /** * Check a binary Unicode property for a code point. @@ -4057,7 +4053,6 @@ u_isIDStart(UChar32 c); U_CAPI UBool U_EXPORT2 u_isIDPart(UChar32 c); -#ifndef U_HIDE_DRAFT_API /** * Does the set of Identifier_Type values code point c contain the given type? * @@ -4069,7 +4064,7 @@ u_isIDPart(UChar32 c); * @param c code point * @param type Identifier_Type to check * @return true if type is in Identifier_Type(c) - * @draft ICU 75 + * @stable ICU 75 */ U_CAPI bool U_EXPORT2 u_hasIDType(UChar32 c, UIdentifierType type); @@ -4104,11 +4099,10 @@ u_hasIDType(UChar32 c, UIdentifierType type); * function chaining. (See User Guide for details.) * @return number of values in c's Identifier_Type, * written to types unless U_BUFFER_OVERFLOW_ERROR indicates insufficient capacity - * @draft ICU 75 + * @stable ICU 75 */ U_CAPI int32_t U_EXPORT2 u_getIDTypes(UChar32 c, UIdentifierType *types, int32_t capacity, UErrorCode *pErrorCode); -#endif // U_HIDE_DRAFT_API /** * Determines if the specified character should be regarded diff --git a/contrib/libs/icu/include/unicode/ucol.h b/contrib/libs/icu/include/unicode/ucol.h index ae4f29c3c6c4..9f721f678642 100644 --- a/contrib/libs/icu/include/unicode/ucol.h +++ b/contrib/libs/icu/include/unicode/ucol.h @@ -1526,7 +1526,6 @@ ucol_openBinary(const uint8_t *bin, int32_t length, #include #include "unicode/char16ptr.h" -#include "unicode/stringpiece.h" #include "unicode/unistr.h" namespace U_HEADER_ONLY_NAMESPACE { @@ -1547,6 +1546,7 @@ class Predicate { /** @internal */ explicit Predicate(const UCollator* ucol) : collator(ucol) {} +#if U_SHOW_CPLUSPLUS_API /** @internal */ template < typename T, typename U, @@ -1554,6 +1554,28 @@ class Predicate { bool operator()(const T& lhs, const U& rhs) const { return match(UnicodeString::readOnlyAlias(lhs), UnicodeString::readOnlyAlias(rhs)); } +#else + /** @internal */ + bool operator()(std::u16string_view lhs, std::u16string_view rhs) const { + return match(lhs, rhs); + } + +#if !U_CHAR16_IS_TYPEDEF && (!defined(_LIBCPP_VERSION) || _LIBCPP_VERSION < 180000) + /** @internal */ + bool operator()(std::basic_string_view lhs, std::basic_string_view rhs) const { + return match({uprv_char16PtrFromUint16(lhs.data()), lhs.length()}, + {uprv_char16PtrFromUint16(rhs.data()), rhs.length()}); + } +#endif + +#if U_SIZEOF_WCHAR_T==2 + /** @internal */ + bool operator()(std::wstring_view lhs, std::wstring_view rhs) const { + return match({uprv_char16PtrFromWchar(lhs.data()), lhs.length()}, + {uprv_char16PtrFromWchar(rhs.data()), rhs.length()}); + } +#endif +#endif /** @internal */ bool operator()(std::string_view lhs, std::string_view rhs) const { @@ -1563,27 +1585,28 @@ class Predicate { #if defined(__cpp_char8_t) /** @internal */ bool operator()(std::u8string_view lhs, std::u8string_view rhs) const { - return match(lhs, rhs); + return match({reinterpret_cast(lhs.data()), lhs.length()}, + {reinterpret_cast(rhs.data()), rhs.length()}); } #endif private: - bool match(UnicodeString lhs, UnicodeString rhs) const { + bool match(std::u16string_view lhs, std::u16string_view rhs) const { return compare( ucol_strcoll( collator, - toUCharPtr(lhs.getBuffer()), lhs.length(), - toUCharPtr(rhs.getBuffer()), rhs.length()), + toUCharPtr(lhs.data()), static_cast(lhs.length()), + toUCharPtr(rhs.data()), static_cast(rhs.length())), result); } - bool match(StringPiece lhs, StringPiece rhs) const { + bool match(std::string_view lhs, std::string_view rhs) const { UErrorCode status = U_ZERO_ERROR; return compare( ucol_strcollUTF8( collator, - lhs.data(), lhs.length(), - rhs.data(), rhs.length(), + lhs.data(), static_cast(lhs.length()), + rhs.data(), static_cast(rhs.length()), &status), result); } diff --git a/contrib/libs/icu/include/unicode/uniset.h b/contrib/libs/icu/include/unicode/uniset.h index d070fd631a22..6b1ac9ba2620 100644 --- a/contrib/libs/icu/include/unicode/uniset.h +++ b/contrib/libs/icu/include/unicode/uniset.h @@ -1173,10 +1173,12 @@ class U_COMMON_API UnicodeSet final : public UnicodeFilter { inline U_HEADER_NESTED_NAMESPACE::USetStrings strings() const { return U_HEADER_NESTED_NAMESPACE::USetStrings(toUSet()); } +#endif // U_HIDE_DRAFT_API +#ifndef U_HIDE_DRAFT_API /** * Returns a C++ iterator for iterating over all of the elements of this set. - * Convenient all-in one iteration, but creates a UnicodeString for each + * Convenient all-in one iteration, but creates a std::u16string for each * code point or string. * (Similar to how Java UnicodeSet *is an* Iterable<String>.) * @@ -1185,13 +1187,14 @@ class U_COMMON_API UnicodeSet final : public UnicodeFilter { * \code * UnicodeSet set(u"[abcçカ🚴{}{abc}{de}]", errorCode); * for (auto el : set) { + * UnicodeString us(el); * std::string u8; - * printf("set.string length %ld \"%s\"\n", (long)el.length(), el.toUTF8String(u8).c_str()); + * printf("set.element length %ld \"%s\"\n", (long)us.length(), us.toUTF8String(u8).c_str()); * } * \endcode * * @return an all-elements iterator. - * @draft ICU 76 + * @draft ICU 77 * @see end * @see codePoints * @see ranges @@ -1203,7 +1206,7 @@ class U_COMMON_API UnicodeSet final : public UnicodeFilter { /** * @return an exclusive-end sentinel for iterating over all of the elements of this set. - * @draft ICU 76 + * @draft ICU 77 * @see begin * @see codePoints * @see ranges diff --git a/contrib/libs/icu/include/unicode/uset.h b/contrib/libs/icu/include/unicode/uset.h index c8f9b5592df2..c5e7f23901b6 100644 --- a/contrib/libs/icu/include/unicode/uset.h +++ b/contrib/libs/icu/include/unicode/uset.h @@ -32,12 +32,13 @@ #include "unicode/utypes.h" #include "unicode/uchar.h" -#if U_SHOW_CPLUSPLUS_API +#if U_SHOW_CPLUSPLUS_API || U_SHOW_CPLUSPLUS_HEADER_API +#include #include #include "unicode/char16ptr.h" #include "unicode/localpointer.h" -#include "unicode/unistr.h" -#endif // U_SHOW_CPLUSPLUS_API +#include "unicode/utf16.h" +#endif #ifndef USET_DEFINED @@ -1392,8 +1393,8 @@ class USetCodePointIterator { private: friend class USetCodePoints; - USetCodePointIterator(const USet *uset, int32_t rangeIndex, int32_t rangeCount) - : uset(uset), rangeIndex(rangeIndex), rangeCount(rangeCount), + USetCodePointIterator(const USet *pUset, int32_t nRangeIndex, int32_t nRangeCount) + : uset(pUset), rangeIndex(nRangeIndex), rangeCount(nRangeCount), c(U_SENTINEL), end(U_SENTINEL) { // Fetch the first range. operator++(); @@ -1429,7 +1430,7 @@ class USetCodePoints { * Constructs a C++ "range" object over the code points of the USet. * @draft ICU 76 */ - USetCodePoints(const USet *uset) : uset(uset), rangeCount(uset_getRangeCount(uset)) {} + USetCodePoints(const USet *pUset) : uset(pUset), rangeCount(uset_getRangeCount(pUset)) {} /** @draft ICU 76 */ USetCodePoints(const USetCodePoints &other) = default; @@ -1460,7 +1461,7 @@ struct CodePointRange { /** @draft ICU 76 */ struct iterator { /** @draft ICU 76 */ - iterator(UChar32 c) : c(c) {} + iterator(UChar32 aC) : c(aC) {} /** @draft ICU 76 */ bool operator==(const iterator &other) const { return c == other.c; } @@ -1573,8 +1574,8 @@ class USetRangeIterator { private: friend class USetRanges; - USetRangeIterator(const USet *uset, int32_t rangeIndex, int32_t rangeCount) - : uset(uset), rangeIndex(rangeIndex), rangeCount(rangeCount) {} + USetRangeIterator(const USet *pUset, int32_t nRangeIndex, int32_t nRangeCount) + : uset(pUset), rangeIndex(nRangeIndex), rangeCount(nRangeCount) {} const USet *uset; int32_t rangeIndex; @@ -1610,7 +1611,7 @@ class USetRanges { * Constructs a C++ "range" object over the code point ranges of the USet. * @draft ICU 76 */ - USetRanges(const USet *uset) : uset(uset), rangeCount(uset_getRangeCount(uset)) {} + USetRanges(const USet *pUset) : uset(pUset), rangeCount(uset_getRangeCount(pUset)) {} /** @draft ICU 76 */ USetRanges(const USetRanges &other) = default; @@ -1657,7 +1658,7 @@ class USetStringIterator { int32_t length; const UChar *uchars = uset_getString(uset, index, &length); // assert uchars != nullptr; - return {ConstChar16Ptr(uchars), static_cast(length)}; + return {uprv_char16PtrFromUChar(uchars), static_cast(length)}; } return {}; } @@ -1684,8 +1685,8 @@ class USetStringIterator { private: friend class USetStrings; - USetStringIterator(const USet *uset, int32_t index, int32_t count) - : uset(uset), index(index), count(count) {} + USetStringIterator(const USet *pUset, int32_t nIndex, int32_t nCount) + : uset(pUset), index(nIndex), count(nCount) {} const USet *uset; int32_t index; @@ -1699,9 +1700,11 @@ class USetStringIterator { * using U_HEADER_NESTED_NAMESPACE::USetStrings; * LocalUSetPointer uset(uset_openPattern(u"[abcçカ🚴{}{abc}{de}]", -1, &errorCode)); * for (auto s : USetStrings(uset.getAlias())) { - * UnicodeString us(s); - * std::string u8; - * printf("uset.string length %ld \"%s\"\n", (long)s.length(), us.toUTF8String(u8).c_str()); + * int32_t len32 = s.length(); + * char utf8[200]; + * u_strToUTF8WithSub(utf8, int32_t{sizeof(utf8) - 1}, nullptr, + * s.data(), len32, 0xFFFD, nullptr, errorCode); + * printf("uset.string length %ld \"%s\"\n", long{len32}, utf8); * } * \endcode * @@ -1718,7 +1721,7 @@ class USetStrings { * Constructs a C++ "range" object over the strings of the USet. * @draft ICU 76 */ - USetStrings(const USet *uset) : uset(uset), count(uset_getStringCount(uset)) {} + USetStrings(const USet *pUset) : uset(pUset), count(uset_getStringCount(pUset)) {} /** @draft ICU 76 */ USetStrings(const USetStrings &other) = default; @@ -1737,17 +1740,19 @@ class USetStrings { const USet *uset; int32_t count; }; +#endif // U_HIDE_DRAFT_API +#ifndef U_HIDE_DRAFT_API /** * Iterator returned by USetElements. - * @draft ICU 76 + * @draft ICU 77 */ class USetElementIterator { public: - /** @draft ICU 76 */ + /** @draft ICU 77 */ USetElementIterator(const USetElementIterator &other) = default; - /** @draft ICU 76 */ + /** @draft ICU 77 */ bool operator==(const USetElementIterator &other) const { // No need to compare rangeCount & end given private constructor // and assuming we don't compare iterators across the set being modified. @@ -1756,26 +1761,28 @@ class USetElementIterator { return uset == other.uset && c == other.c && index == other.index; } - /** @draft ICU 76 */ + /** @draft ICU 77 */ bool operator!=(const USetElementIterator &other) const { return !operator==(other); } - /** @draft ICU 76 */ - UnicodeString operator*() const { + /** @draft ICU 77 */ + std::u16string operator*() const { if (c >= 0) { - return UnicodeString(c); + return c <= 0xffff ? + std::u16string({static_cast(c)}) : + std::u16string({U16_LEAD(c), U16_TRAIL(c)}); } else if (index < totalCount) { int32_t length; const UChar *uchars = uset_getString(uset, index - rangeCount, &length); // assert uchars != nullptr; - return UnicodeString(uchars, length); + return {uprv_char16PtrFromUChar(uchars), static_cast(length)}; } else { - return UnicodeString(); + return {}; } } /** * Pre-increment. - * @draft ICU 76 + * @draft ICU 77 */ USetElementIterator &operator++() { if (c < end) { @@ -1800,7 +1807,7 @@ class USetElementIterator { /** * Post-increment. - * @draft ICU 76 + * @draft ICU 77 */ USetElementIterator operator++(int) { USetElementIterator result(*this); @@ -1811,8 +1818,8 @@ class USetElementIterator { private: friend class USetElements; - USetElementIterator(const USet *uset, int32_t index, int32_t rangeCount, int32_t totalCount) - : uset(uset), index(index), rangeCount(rangeCount), totalCount(totalCount), + USetElementIterator(const USet *pUset, int32_t nIndex, int32_t nRangeCount, int32_t nTotalCount) + : uset(pUset), index(nIndex), rangeCount(nRangeCount), totalCount(nTotalCount), c(U_SENTINEL), end(U_SENTINEL) { if (index < rangeCount) { // Fetch the first range. @@ -1840,7 +1847,7 @@ class USetElementIterator { /** * A C++ "range" for iterating over all of the elements of a USet. - * Convenient all-in one iteration, but creates a UnicodeString for each + * Convenient all-in one iteration, but creates a std::u16string for each * code point or string. * * Code points are returned first, then empty and multi-character strings. @@ -1849,15 +1856,18 @@ class USetElementIterator { * using U_HEADER_NESTED_NAMESPACE::USetElements; * LocalUSetPointer uset(uset_openPattern(u"[abcçカ🚴{}{abc}{de}]", -1, &errorCode)); * for (auto el : USetElements(uset.getAlias())) { - * std::string u8; - * printf("uset.string length %ld \"%s\"\n", (long)el.length(), el.toUTF8String(u8).c_str()); + * int32_t len32 = el.length(); + * char utf8[200]; + * u_strToUTF8WithSub(utf8, int32_t{sizeof(utf8) - 1}, nullptr, + * el.data(), len32, 0xFFFD, nullptr, errorCode); + * printf("uset.element length %ld \"%s\"\n", long{len32}, utf8); * } * \endcode * * C++ UnicodeSet has member functions for iteration, including begin() and end(). * * @return an all-elements iterator. - * @draft ICU 76 + * @draft ICU 77 * @see USetCodePoints * @see USetRanges * @see USetStrings @@ -1866,21 +1876,21 @@ class USetElements { public: /** * Constructs a C++ "range" object over all of the elements of the USet. - * @draft ICU 76 + * @draft ICU 77 */ - USetElements(const USet *uset) - : uset(uset), rangeCount(uset_getRangeCount(uset)), - stringCount(uset_getStringCount(uset)) {} + USetElements(const USet *pUset) + : uset(pUset), rangeCount(uset_getRangeCount(pUset)), + stringCount(uset_getStringCount(pUset)) {} - /** @draft ICU 76 */ + /** @draft ICU 77 */ USetElements(const USetElements &other) = default; - /** @draft ICU 76 */ + /** @draft ICU 77 */ USetElementIterator begin() const { return USetElementIterator(uset, 0, rangeCount, rangeCount + stringCount); } - /** @draft ICU 76 */ + /** @draft ICU 77 */ USetElementIterator end() const { return USetElementIterator(uset, rangeCount + stringCount, rangeCount, rangeCount + stringCount); } diff --git a/contrib/libs/icu/include/unicode/usimplenumberformatter.h b/contrib/libs/icu/include/unicode/usimplenumberformatter.h index 22e81ba2c939..ccc5754b4348 100644 --- a/contrib/libs/icu/include/unicode/usimplenumberformatter.h +++ b/contrib/libs/icu/include/unicode/usimplenumberformatter.h @@ -156,15 +156,13 @@ U_CAPI void U_EXPORT2 usnum_setMinimumFractionDigits(USimpleNumber* unumber, int32_t minimumFractionDigits, UErrorCode* ec); -#ifndef U_HIDE_DRAFT_API /** * Sets the number of integer digits to the given amount, truncating if necessary. * - * @draft ICU 75 + * @stable ICU 75 */ U_CAPI void U_EXPORT2 usnum_setMaximumIntegerDigits(USimpleNumber* unumber, int32_t maximumIntegerDigits, UErrorCode* ec); -#endif // U_HIDE_DRAFT_API /** diff --git a/contrib/libs/icu/include/unicode/ustdio.h b/contrib/libs/icu/include/unicode/ustdio.h index 5aad6b9bbead..bdfcb35e65f4 100644 --- a/contrib/libs/icu/include/unicode/ustdio.h +++ b/contrib/libs/icu/include/unicode/ustdio.h @@ -713,8 +713,8 @@ u_fgetc(UFILE *f); * * @param f The UFILE from which to read. * @return The UChar32 value read, or U_EOF if no character was - * available, or U+FFFFFFFF if an ill-formed character was - * encountered. + * available, or U+FFFD (replacement character) if an ill-formed + * character was encountered. * @see u_unescape() * @stable ICU 3.0 */ diff --git a/contrib/libs/icu/include/unicode/utf8.h b/contrib/libs/icu/include/unicode/utf8.h index 5a07435fcf60..96ad46161aa1 100644 --- a/contrib/libs/icu/include/unicode/utf8.h +++ b/contrib/libs/icu/include/unicode/utf8.h @@ -124,7 +124,7 @@ * @internal */ U_CAPI UChar32 U_EXPORT2 -utf8_nextCharSafeBody(const uint8_t *s, int32_t *pi, int32_t length, UChar32 c, UBool strict); +utf8_nextCharSafeBody(const uint8_t *s, int32_t *pi, int32_t length, UChar32 c, int8_t strict); /** * Function for handling "append code point" with error-checking. @@ -148,7 +148,7 @@ utf8_appendCharSafeBody(uint8_t *s, int32_t i, int32_t length, UChar32 c, UBool * @internal */ U_CAPI UChar32 U_EXPORT2 -utf8_prevCharSafeBody(const uint8_t *s, int32_t start, int32_t *pi, UChar32 c, UBool strict); +utf8_prevCharSafeBody(const uint8_t *s, int32_t start, int32_t *pi, UChar32 c, int8_t strict); /** * Function for handling "skip backward one code point" with error-checking. diff --git a/contrib/libs/icu/include/unicode/utypes.h b/contrib/libs/icu/include/unicode/utypes.h index 0151ebd47015..ecdee5164316 100644 --- a/contrib/libs/icu/include/unicode/utypes.h +++ b/contrib/libs/icu/include/unicode/utypes.h @@ -598,12 +598,13 @@ typedef enum UErrorCode { U_MF_DUPLICATE_DECLARATION_ERROR, /**< The same variable is declared in more than one .local or .input declaration. @internal ICU 75 technology preview @deprecated This API is for technology preview only. */ U_MF_OPERAND_MISMATCH_ERROR, /**< An operand provided to a function does not have the required form for that function @internal ICU 75 technology preview @deprecated This API is for technology preview only. */ U_MF_DUPLICATE_VARIANT_ERROR, /**< A message includes a variant with the same key list as another variant. @internal ICU 76 technology preview @deprecated This API is for technology preview only. */ + U_MF_BAD_OPTION, /**< An option value provided to a function does not have the required form for that option. @internal ICU 77 technology preview @deprecated This API is for technology preview only. */ #ifndef U_HIDE_DEPRECATED_API /** * One more than the highest normal formatting API error code. * @deprecated ICU 58 The numeric value may change over time, see ICU ticket #12420. */ - U_FMT_PARSE_ERROR_LIMIT = 0x10120, + U_FMT_PARSE_ERROR_LIMIT = 0x10121, #endif // U_HIDE_DEPRECATED_API /* diff --git a/contrib/libs/icu/include/unicode/uvernum.h b/contrib/libs/icu/include/unicode/uvernum.h index a3cb882623be..847c49f4cfb8 100644 --- a/contrib/libs/icu/include/unicode/uvernum.h +++ b/contrib/libs/icu/include/unicode/uvernum.h @@ -53,7 +53,7 @@ * This value will change in the subsequent releases of ICU * @stable ICU 2.4 */ -#define U_ICU_VERSION_MAJOR_NUM 76 +#define U_ICU_VERSION_MAJOR_NUM 77 /** The current ICU minor version as an integer. * This value will change in the subsequent releases of ICU @@ -79,7 +79,7 @@ * This value will change in the subsequent releases of ICU * @stable ICU 2.6 */ -#define U_ICU_VERSION_SUFFIX _76 +#define U_ICU_VERSION_SUFFIX _77 /** * \def U_DEF2_ICU_ENTRY_POINT_RENAME @@ -132,7 +132,7 @@ * This value will change in the subsequent releases of ICU * @stable ICU 2.4 */ -#define U_ICU_VERSION "76.1" +#define U_ICU_VERSION "77.1" /** * The current ICU library major version number as a string, for library name suffixes. @@ -145,13 +145,13 @@ * * @stable ICU 2.6 */ -#define U_ICU_VERSION_SHORT "76" +#define U_ICU_VERSION_SHORT "77" #ifndef U_HIDE_INTERNAL_API /** Data version in ICU4C. * @internal ICU 4.4 Internal Use Only **/ -#define U_ICU_DATA_VERSION "76.1" +#define U_ICU_DATA_VERSION "77.1" #endif /* U_HIDE_INTERNAL_API */ /*=========================================================================== diff --git a/contrib/libs/icu/include/unicode/uversion.h b/contrib/libs/icu/include/unicode/uversion.h index 25d73a3aeb54..a29bf21efda5 100644 --- a/contrib/libs/icu/include/unicode/uversion.h +++ b/contrib/libs/icu/include/unicode/uversion.h @@ -125,7 +125,7 @@ typedef uint8_t UVersionInfo[U_MAX_VERSION_LENGTH]; U_NAMESPACE_USE # endif -#ifndef U_HIDE_DRAFT_API +#ifndef U_FORCE_HIDE_DRAFT_API /** * \def U_HEADER_NESTED_NAMESPACE * Nested namespace used inside U_ICU_NAMESPACE for header-only APIs. @@ -150,22 +150,37 @@ typedef uint8_t UVersionInfo[U_MAX_VERSION_LENGTH]; * @draft ICU 76 */ +/** + * \def U_ICU_NAMESPACE_OR_INTERNAL + * Namespace used for header-only APIs that used to be regular C++ APIs. + * Different when used inside ICU to prevent public use of internal instantiations. + * Similar to U_HEADER_ONLY_NAMESPACE, but the public definition is the same as U_ICU_NAMESPACE. + * "U_ICU_NAMESPACE" or "U_ICU_NAMESPACE::internal". + * + * @draft ICU 77 + */ + // The first test is the same as for defining U_EXPORT for Windows. #if defined(_MSC_VER) || (UPRV_HAS_DECLSPEC_ATTRIBUTE(__dllexport__) && \ UPRV_HAS_DECLSPEC_ATTRIBUTE(__dllimport__)) # define U_HEADER_NESTED_NAMESPACE header +# define U_ICU_NAMESPACE_OR_INTERNAL U_ICU_NAMESPACE #elif defined(U_COMBINED_IMPLEMENTATION) || defined(U_COMMON_IMPLEMENTATION) || \ defined(U_I18N_IMPLEMENTATION) || defined(U_IO_IMPLEMENTATION) || \ defined(U_LAYOUTEX_IMPLEMENTATION) || defined(U_TOOLUTIL_IMPLEMENTATION) # define U_HEADER_NESTED_NAMESPACE internal +# define U_ICU_NAMESPACE_OR_INTERNAL U_ICU_NAMESPACE::internal + namespace U_ICU_NAMESPACE_OR_INTERNAL {} + using namespace U_ICU_NAMESPACE_OR_INTERNAL; #else # define U_HEADER_NESTED_NAMESPACE header +# define U_ICU_NAMESPACE_OR_INTERNAL U_ICU_NAMESPACE #endif #define U_HEADER_ONLY_NAMESPACE U_ICU_NAMESPACE::U_HEADER_NESTED_NAMESPACE namespace U_HEADER_ONLY_NAMESPACE {} -#endif // U_HIDE_DRAFT_API +#endif // U_FORCE_HIDE_DRAFT_API #endif /* __cplusplus */ diff --git a/contrib/libs/icu/ya.make b/contrib/libs/icu/ya.make index f331ecf16e0b..ce58bc3d9bed 100644 --- a/contrib/libs/icu/ya.make +++ b/contrib/libs/icu/ya.make @@ -14,9 +14,9 @@ LICENSE( LICENSE_TEXTS(.yandex_meta/licenses.list.txt) -VERSION(76.1) +VERSION(77.1) -ORIGINAL_SOURCE(https://github.com/unicode-org/icu/releases/download/release-76-1/icu4c-76_1-src.tgz) +ORIGINAL_SOURCE(https://github.com/unicode-org/icu/releases/download/release-77-1/icu4c-77_1-src.tgz) ADDINCL( GLOBAL contrib/libs/icu/include @@ -501,7 +501,7 @@ SRCS( i18n/zonemeta.cpp i18n/zrule.cpp i18n/ztrans.cpp - icudt76_dat.rodata + icudt77_dat.rodata io/locbund.cpp io/sprintf.cpp io/sscanf.cpp diff --git a/contrib/libs/tcmalloc/patches/900-undeprecate-rate-interval.patch b/contrib/libs/tcmalloc/patches/900-undeprecate-rate-interval.patch deleted file mode 100644 index 0db77a9d2f94..000000000000 --- a/contrib/libs/tcmalloc/patches/900-undeprecate-rate-interval.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff --git a/tcmalloc/malloc_extension.h b/tcmalloc/malloc_extension.h -index dab6ea7..961072e 100644 ---- a/tcmalloc/malloc_extension.h -+++ b/tcmalloc/malloc_extension.h -@@ -476,11 +476,9 @@ class MallocExtension final { - - // The old names to get and set profile sampling intervals used "rate" to - // refer to intervals. Use of the below is deprecated to avoid confusion. -- ABSL_DEPRECATE_AND_INLINE() - static int64_t GetProfileSamplingRate() { - return GetProfileSamplingInterval(); - } -- ABSL_DEPRECATE_AND_INLINE() - static void SetProfileSamplingRate(int64_t rate) { - SetProfileSamplingInterval(rate); - } -@@ -488,7 +486,6 @@ class MallocExtension final { - static int64_t GetGuardedSamplingRate() { - return GetGuardedSamplingInterval(); - } -- ABSL_DEPRECATE_AND_INLINE() - static void SetGuardedSamplingRate(int64_t rate) { - SetGuardedSamplingInterval(rate); - } diff --git a/contrib/libs/tcmalloc/tcmalloc/malloc_extension.h b/contrib/libs/tcmalloc/tcmalloc/malloc_extension.h index db293da998e1..0e7a92e04220 100644 --- a/contrib/libs/tcmalloc/tcmalloc/malloc_extension.h +++ b/contrib/libs/tcmalloc/tcmalloc/malloc_extension.h @@ -477,9 +477,11 @@ class MallocExtension final { // The old names to get and set profile sampling intervals used "rate" to // refer to intervals. Use of the below is deprecated to avoid confusion. + ABSL_DEPRECATE_AND_INLINE() static int64_t GetProfileSamplingRate() { return GetProfileSamplingInterval(); } + ABSL_DEPRECATE_AND_INLINE() static void SetProfileSamplingRate(int64_t rate) { SetProfileSamplingInterval(rate); } @@ -487,6 +489,7 @@ class MallocExtension final { static int64_t GetGuardedSamplingRate() { return GetGuardedSamplingInterval(); } + ABSL_DEPRECATE_AND_INLINE() static void SetGuardedSamplingRate(int64_t rate) { SetGuardedSamplingInterval(rate); } diff --git a/contrib/python/Flask-Cors/py3/.dist-info/METADATA b/contrib/python/Flask-Cors/py3/.dist-info/METADATA index 4f796aaabeda..786a01c15b96 100644 --- a/contrib/python/Flask-Cors/py3/.dist-info/METADATA +++ b/contrib/python/Flask-Cors/py3/.dist-info/METADATA @@ -1,6 +1,6 @@ Metadata-Version: 2.4 Name: flask-cors -Version: 6.0.0 +Version: 6.0.1 Summary: A Flask extension simplifying CORS support Author-email: Cory Dolphin Project-URL: Homepage, https://corydolphin.github.io/flask-cors/ @@ -17,6 +17,127 @@ Classifier: Programming Language :: Python :: 3.12 Classifier: Programming Language :: Python :: 3.13 Classifier: Topic :: Software Development :: Libraries :: Python Modules Requires-Python: <4.0,>=3.9 -Description-Content-Type: text/markdown +Description-Content-Type: text/x-rst Requires-Dist: flask>=0.9 Requires-Dist: Werkzeug>=0.7 + +Flask-CORS +========== + +|Build Status| |Latest Version| |Supported Python versions| +|License| + +A Flask extension for handling Cross Origin Resource Sharing (CORS), making cross-origin AJAX possible. + +This package has a simple philosophy: when you want to enable CORS, you wish to enable it for all use cases on a domain. +This means no mucking around with different allowed headers, methods, etc. + +By default, submission of cookies across domains is disabled due to the security implications. +Please see the documentation for how to enable credential'ed requests, and please make sure you add some sort of `CSRF `__ protection before doing so! + +Installation +------------ + +Install the extension with using pip, or easy\_install. + +.. code:: bash + + $ pip install -U flask-cors + +Usage +----- + +This package exposes a Flask extension which by default enables CORS support on all routes, for all origins and methods. +It allows parameterization of all CORS headers on a per-resource level. +The package also contains a decorator, for those who prefer this approach. + +Simple Usage +~~~~~~~~~~~~ + +In the simplest case, initialize the Flask-Cors extension with default arguments in order to allow CORS for all domains on all routes. +See the full list of options in the `documentation `__. + +.. code:: python + + + from flask import Flask + from flask_cors import CORS + + app = Flask(__name__) + CORS(app) + + @app.route("/") + def helloWorld(): + return "Hello, cross-origin-world!" + +Resource specific CORS +^^^^^^^^^^^^^^^^^^^^^^ + +Alternatively, you can specify CORS options on a resource and origin level of granularity by passing a dictionary as the `resources` option, mapping paths to a set of options. +See the full list of options in the `documentation `__. + +.. code:: python + + app = Flask(__name__) + cors = CORS(app, resources={r"/api/*": {"origins": "*"}}) + + @app.route("/api/v1/users") + def list_users(): + return "user example" + +Route specific CORS via decorator +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +This extension also exposes a simple decorator to decorate flask routes with. +Simply add ``@cross_origin()`` below a call to Flask's ``@app.route(..)`` to allow CORS on a given route. +See the full list of options in the `decorator documentation `__. + +.. code:: python + + @app.route("/") + @cross_origin() + def helloWorld(): + return "Hello, cross-origin-world!" + +Documentation +------------- + +For a full list of options, please see the full `documentation `__ + +Troubleshooting +--------------- + +If things aren't working as you expect, enable logging to help understand what is going on under the hood, and why. + +.. code:: python + + logging.getLogger('flask_cors').level = logging.DEBUG + + + +Set Up Your Development Environment +--- +The development environment uses `uv` for Python version management as well as dependency management. +There are helpful Makefile targets to do everything you need. Use `make test` to get started! + + +Contributing +------------ + +Questions, comments or improvements? +Please create an issue on `Github `__, tweet at `@corydolphin `__ or send me an email. +I do my best to include every contribution proposed in any way that I can. + +Credits +------- + +This Flask extension is based upon the `Decorator for the HTTP Access Control `__ written by Armin Ronacher. + +.. |Build Status| image:: https://github.com/corydolphin/flask-cors/actions/workflows/unittests.yaml/badge.svg + :target: https://travis-ci.org/corydolphin/flask-cors +.. |Latest Version| image:: https://img.shields.io/pypi/v/Flask-Cors.svg + :target: https://pypi.python.org/pypi/Flask-Cors/ +.. |Supported Python versions| image:: https://img.shields.io/pypi/pyversions/Flask-Cors.svg + :target: https://img.shields.io/pypi/pyversions/Flask-Cors.svg +.. |License| image:: http://img.shields.io/:license-mit-blue.svg + :target: https://pypi.python.org/pypi/Flask-Cors/ diff --git a/contrib/python/Flask-Cors/py3/flask_cors/core.py b/contrib/python/Flask-Cors/py3/flask_cors/core.py index 5773b0beb8b5..8df343c935a8 100644 --- a/contrib/python/Flask-Cors/py3/flask_cors/core.py +++ b/contrib/python/Flask-Cors/py3/flask_cors/core.py @@ -73,11 +73,11 @@ def parse_resources(resources): def sort_key(pair): pattern, _ = pair if isinstance(pattern, RegexObject): - return (1, 0, pattern.pattern.count("/"), -len(pattern.pattern)) + return (1, 0, -pattern.pattern.count("/"), -len(pattern.pattern)) elif probably_regex(pattern): - return (1, 1, pattern.count("/"), -len(pattern)) + return (1, 1, -pattern.count("/"), -len(pattern)) else: - return (0, 0, pattern.count("/"), -len(pattern)) + return (0, 0, -pattern.count("/"), -len(pattern)) return sorted(resources, key=sort_key) diff --git a/contrib/python/Flask-Cors/py3/flask_cors/version.py b/contrib/python/Flask-Cors/py3/flask_cors/version.py index 0f607a5d2d69..79a961b4f6fa 100644 --- a/contrib/python/Flask-Cors/py3/flask_cors/version.py +++ b/contrib/python/Flask-Cors/py3/flask_cors/version.py @@ -1 +1 @@ -__version__ = "6.0.0" +__version__ = "6.0.1" diff --git a/contrib/python/Flask-Cors/py3/ya.make b/contrib/python/Flask-Cors/py3/ya.make index 631966d8c5ce..785dfc60c73f 100644 --- a/contrib/python/Flask-Cors/py3/ya.make +++ b/contrib/python/Flask-Cors/py3/ya.make @@ -2,7 +2,7 @@ PY3_LIBRARY() -VERSION(6.0.0) +VERSION(6.0.1) LICENSE(MIT) diff --git a/contrib/python/allure-pytest/.dist-info/METADATA b/contrib/python/allure-pytest/.dist-info/METADATA index 834bf01e5c46..96d707c9148f 100644 --- a/contrib/python/allure-pytest/.dist-info/METADATA +++ b/contrib/python/allure-pytest/.dist-info/METADATA @@ -1,6 +1,6 @@ Metadata-Version: 2.4 Name: allure-pytest -Version: 2.14.2 +Version: 2.14.3 Summary: Allure pytest integration Home-page: https://allurereport.org/ Author: Qameta Software Inc., Stanislav Seliverstov @@ -25,7 +25,7 @@ Classifier: Programming Language :: Python :: 3.12 Classifier: Programming Language :: Python :: 3.13 Description-Content-Type: text/markdown Requires-Dist: pytest>=4.5.0 -Requires-Dist: allure-python-commons==2.14.2 +Requires-Dist: allure-python-commons==2.14.3 Dynamic: author Dynamic: author-email Dynamic: classifier diff --git a/contrib/python/allure-pytest/allure_pytest/helper.py b/contrib/python/allure-pytest/allure_pytest/helper.py index e6944ef40cac..a9df4b7ebca2 100644 --- a/contrib/python/allure-pytest/allure_pytest/helper.py +++ b/contrib/python/allure-pytest/allure_pytest/helper.py @@ -10,7 +10,9 @@ class AllureTitleHelper: def decorate_as_title(self, test_title): def decorator(func): # pytest.fixture wraps function, so we need to get it directly - if getattr(func, '__pytest_wrapped__', None): + if hasattr(func, "_get_wrapped_function"): # pytest >= 8.4 + function = func._get_wrapped_function() + elif hasattr(func, "__pytest_wrapped__"): # pytest < 8.4 function = func.__pytest_wrapped__.obj else: function = func diff --git a/contrib/python/allure-pytest/allure_pytest/utils.py b/contrib/python/allure-pytest/allure_pytest/utils.py index 1e07cb492c3b..19145510fa62 100644 --- a/contrib/python/allure-pytest/allure_pytest/utils.py +++ b/contrib/python/allure-pytest/allure_pytest/utils.py @@ -1,6 +1,6 @@ import pytest from itertools import chain, islice -from allure_commons.utils import represent, SafeFormatter, md5 +from allure_commons.utils import SafeFormatter, md5 from allure_commons.utils import format_exception, format_traceback from allure_commons.model2 import Status from allure_commons.model2 import StatusDetails @@ -20,6 +20,15 @@ LabelType.SUB_SUITE ] +MARK_NAMES_TO_IGNORE = { + "usefixtures", + "filterwarnings", + "skip", + "skipif", + "xfail", + "parametrize", +} + def get_marker_value(item, keyword): marker = item.get_closest_marker(keyword) @@ -81,27 +90,14 @@ def format_allure_link(config, url, link_type): def pytest_markers(item): - for keyword in item.keywords.keys(): - if any([keyword.startswith('allure_'), keyword == 'parametrize']): - continue - marker = item.get_closest_marker(keyword) - if marker is None: - continue - - yield mark_to_str(marker) + for mark in item.iter_markers(): + if should_convert_mark_to_tag(mark): + yield mark.name -def mark_to_str(marker): - args = [represent(arg) for arg in marker.args] - kwargs = [f'{key}={represent(value)}' for key, value in marker.kwargs.items()] - if marker.name in ('filterwarnings', 'skip', 'skipif', 'xfail', 'usefixtures', 'tryfirst', 'trylast'): - markstr = f'@pytest.mark.{marker.name}' - else: - markstr = str(marker.name) - if args or kwargs: - parameters = ', '.join(args + kwargs) - markstr = f'{markstr}({parameters})' - return markstr +def should_convert_mark_to_tag(mark): + return mark.name not in MARK_NAMES_TO_IGNORE and \ + not mark.args and not mark.kwargs def allure_package(item): diff --git a/contrib/python/allure-pytest/ya.make b/contrib/python/allure-pytest/ya.make index 4b5ffa06a85f..1680e08c9377 100644 --- a/contrib/python/allure-pytest/ya.make +++ b/contrib/python/allure-pytest/ya.make @@ -2,7 +2,7 @@ PY3_LIBRARY() -VERSION(2.14.2) +VERSION(2.14.3) LICENSE(Apache-2.0) diff --git a/contrib/python/kubernetes/.dist-info/METADATA b/contrib/python/kubernetes/.dist-info/METADATA index b65cf147ace9..03a9b0e4f73d 100644 --- a/contrib/python/kubernetes/.dist-info/METADATA +++ b/contrib/python/kubernetes/.dist-info/METADATA @@ -1,6 +1,6 @@ -Metadata-Version: 2.2 +Metadata-Version: 2.4 Name: kubernetes -Version: 32.0.1 +Version: 33.1.0 Summary: Kubernetes python client Home-page: https://github.com/kubernetes-client/python Author: Kubernetes @@ -42,6 +42,7 @@ Dynamic: description Dynamic: home-page Dynamic: keywords Dynamic: license +Dynamic: license-file Dynamic: provides-extra Dynamic: requires-dist Dynamic: requires-python diff --git a/contrib/python/kubernetes/README.md b/contrib/python/kubernetes/README.md index 18b916eb77f0..99e2b38e08ce 100644 --- a/contrib/python/kubernetes/README.md +++ b/contrib/python/kubernetes/README.md @@ -102,6 +102,7 @@ supported versions of Kubernetes clusters. - [client 30.y.z](https://pypi.org/project/kubernetes/30.1.0/): Kubernetes 1.29 or below (+-), Kubernetes 1.30 (✓), Kubernetes 1.31 or above (+-) - [client 31.y.z](https://pypi.org/project/kubernetes/31.0.0/): Kubernetes 1.30 or below (+-), Kubernetes 1.31 (✓), Kubernetes 1.32 or above (+-) - [client 32.y.z](https://pypi.org/project/kubernetes/32.0.1/): Kubernetes 1.31 or below (+-), Kubernetes 1.32 (✓), Kubernetes 1.33 or above (+-) +- [client 33.y.z](https://pypi.org/project/kubernetes/33.1.0/): Kubernetes 1.32 or below (+-), Kubernetes 1.33 (✓), Kubernetes 1.34 or above (+-) > See [here](#homogenizing-the-kubernetes-python-client-versions) for an explanation of why there is no v13-v16 release. @@ -166,11 +167,13 @@ between client-python versions. | 29.0 Alpha/Beta | Kubernetes main repo, 1.29 branch | ✗ | | 29.0 | Kubernetes main repo, 1.29 branch | ✗ | | 30.0 Alpha/Beta | Kubernetes main repo, 1.30 branch | ✗ | -| 30.0 | Kubernetes main repo, 1.30 branch | ✓ | +| 30.0 | Kubernetes main repo, 1.30 branch | ✗ | | 31.0 Alpha/Beta | Kubernetes main repo, 1.31 branch | ✗ | | 31.0 | Kubernetes main repo, 1.31 branch | ✓ | | 32.0 Alpha/Beta | Kubernetes main repo, 1.32 branch | ✗ | | 32.1 | Kubernetes main repo, 1.32 branch | ✓ | +| 33.1 Alpha/Beta | Kubernetes main repo, 1.33 branch | ✗ | +| 33.1 | Kubernetes main repo, 1.33 branch | ✓ | > See [here](#homogenizing-the-kubernetes-python-client-versions) for an explanation of why there is no v13-v16 release. @@ -236,4 +239,20 @@ recreate it between api calls that use _stream_ and other api calls. See more at [exec example](examples/pod_exec.py). +## Enabling Debug Logging + +To enable debug logging in the Kubernetes Python client, follow these steps: + +### 1. Import the `logging` module + +```python +import logging + +# Set the logging level to DEBUG +logging.basicConfig(level=logging.DEBUG) + +# To see the HTTP requests and responses sent to the Kubernetes API (for debugging network-related issues), configure the urllib3 logger: +logging.getLogger("urllib3").setLevel(logging.DEBUG) +``` + **[⬆ back to top](#Installation)** diff --git a/contrib/python/kubernetes/kubernetes/__init__.py b/contrib/python/kubernetes/kubernetes/__init__.py index 2d97aed23ec8..2101f0c63f36 100644 --- a/contrib/python/kubernetes/kubernetes/__init__.py +++ b/contrib/python/kubernetes/kubernetes/__init__.py @@ -14,7 +14,7 @@ __project__ = 'kubernetes' # The version is auto-updated. Please do not edit. -__version__ = "32.0.1" +__version__ = "33.1.0" from . import client from . import config diff --git a/contrib/python/kubernetes/kubernetes/client/__init__.py b/contrib/python/kubernetes/kubernetes/client/__init__.py index f43baaee850a..b2e039dff7c8 100644 --- a/contrib/python/kubernetes/kubernetes/client/__init__.py +++ b/contrib/python/kubernetes/kubernetes/client/__init__.py @@ -7,14 +7,14 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ from __future__ import absolute_import -__version__ = "32.0.1" +__version__ = "33.1.0" # import apis into sdk package from kubernetes.client.api.well_known_api import WellKnownApi @@ -31,7 +31,6 @@ from kubernetes.client.api.apps_v1_api import AppsV1Api from kubernetes.client.api.authentication_api import AuthenticationApi from kubernetes.client.api.authentication_v1_api import AuthenticationV1Api -from kubernetes.client.api.authentication_v1beta1_api import AuthenticationV1beta1Api from kubernetes.client.api.authorization_api import AuthorizationApi from kubernetes.client.api.authorization_v1_api import AuthorizationV1Api from kubernetes.client.api.autoscaling_api import AutoscalingApi @@ -42,9 +41,11 @@ from kubernetes.client.api.certificates_api import CertificatesApi from kubernetes.client.api.certificates_v1_api import CertificatesV1Api from kubernetes.client.api.certificates_v1alpha1_api import CertificatesV1alpha1Api +from kubernetes.client.api.certificates_v1beta1_api import CertificatesV1beta1Api from kubernetes.client.api.coordination_api import CoordinationApi from kubernetes.client.api.coordination_v1_api import CoordinationV1Api from kubernetes.client.api.coordination_v1alpha2_api import CoordinationV1alpha2Api +from kubernetes.client.api.coordination_v1beta1_api import CoordinationV1beta1Api from kubernetes.client.api.core_api import CoreApi from kubernetes.client.api.core_v1_api import CoreV1Api from kubernetes.client.api.custom_objects_api import CustomObjectsApi @@ -70,6 +71,7 @@ from kubernetes.client.api.resource_api import ResourceApi from kubernetes.client.api.resource_v1alpha3_api import ResourceV1alpha3Api from kubernetes.client.api.resource_v1beta1_api import ResourceV1beta1Api +from kubernetes.client.api.resource_v1beta2_api import ResourceV1beta2Api from kubernetes.client.api.scheduling_api import SchedulingApi from kubernetes.client.api.scheduling_v1_api import SchedulingV1Api from kubernetes.client.api.storage_api import StorageApi @@ -244,6 +246,7 @@ from kubernetes.client.models.v1_flow_schema_list import V1FlowSchemaList from kubernetes.client.models.v1_flow_schema_spec import V1FlowSchemaSpec from kubernetes.client.models.v1_flow_schema_status import V1FlowSchemaStatus +from kubernetes.client.models.v1_for_node import V1ForNode from kubernetes.client.models.v1_for_zone import V1ForZone from kubernetes.client.models.v1_gce_persistent_disk_volume_source import V1GCEPersistentDiskVolumeSource from kubernetes.client.models.v1_grpc_action import V1GRPCAction @@ -263,6 +266,9 @@ from kubernetes.client.models.v1_host_alias import V1HostAlias from kubernetes.client.models.v1_host_ip import V1HostIP from kubernetes.client.models.v1_host_path_volume_source import V1HostPathVolumeSource +from kubernetes.client.models.v1_ip_address import V1IPAddress +from kubernetes.client.models.v1_ip_address_list import V1IPAddressList +from kubernetes.client.models.v1_ip_address_spec import V1IPAddressSpec from kubernetes.client.models.v1_ip_block import V1IPBlock from kubernetes.client.models.v1_iscsi_persistent_volume_source import V1ISCSIPersistentVolumeSource from kubernetes.client.models.v1_iscsi_volume_source import V1ISCSIVolumeSource @@ -348,6 +354,7 @@ from kubernetes.client.models.v1_node_selector_term import V1NodeSelectorTerm from kubernetes.client.models.v1_node_spec import V1NodeSpec from kubernetes.client.models.v1_node_status import V1NodeStatus +from kubernetes.client.models.v1_node_swap_status import V1NodeSwapStatus from kubernetes.client.models.v1_node_system_info import V1NodeSystemInfo from kubernetes.client.models.v1_non_resource_attributes import V1NonResourceAttributes from kubernetes.client.models.v1_non_resource_policy_rule import V1NonResourcePolicyRule @@ -359,6 +366,7 @@ from kubernetes.client.models.v1_owner_reference import V1OwnerReference from kubernetes.client.models.v1_param_kind import V1ParamKind from kubernetes.client.models.v1_param_ref import V1ParamRef +from kubernetes.client.models.v1_parent_reference import V1ParentReference from kubernetes.client.models.v1_persistent_volume import V1PersistentVolume from kubernetes.client.models.v1_persistent_volume_claim import V1PersistentVolumeClaim from kubernetes.client.models.v1_persistent_volume_claim_condition import V1PersistentVolumeClaimCondition @@ -484,6 +492,10 @@ from kubernetes.client.models.v1_service_account_subject import V1ServiceAccountSubject from kubernetes.client.models.v1_service_account_token_projection import V1ServiceAccountTokenProjection from kubernetes.client.models.v1_service_backend_port import V1ServiceBackendPort +from kubernetes.client.models.v1_service_cidr import V1ServiceCIDR +from kubernetes.client.models.v1_service_cidr_list import V1ServiceCIDRList +from kubernetes.client.models.v1_service_cidr_spec import V1ServiceCIDRSpec +from kubernetes.client.models.v1_service_cidr_status import V1ServiceCIDRStatus from kubernetes.client.models.v1_service_list import V1ServiceList from kubernetes.client.models.v1_service_port import V1ServicePort from kubernetes.client.models.v1_service_spec import V1ServiceSpec @@ -599,6 +611,8 @@ from kubernetes.client.models.v1alpha3_allocation_result import V1alpha3AllocationResult from kubernetes.client.models.v1alpha3_basic_device import V1alpha3BasicDevice from kubernetes.client.models.v1alpha3_cel_device_selector import V1alpha3CELDeviceSelector +from kubernetes.client.models.v1alpha3_counter import V1alpha3Counter +from kubernetes.client.models.v1alpha3_counter_set import V1alpha3CounterSet from kubernetes.client.models.v1alpha3_device import V1alpha3Device from kubernetes.client.models.v1alpha3_device_allocation_configuration import V1alpha3DeviceAllocationConfiguration from kubernetes.client.models.v1alpha3_device_allocation_result import V1alpha3DeviceAllocationResult @@ -610,9 +624,17 @@ from kubernetes.client.models.v1alpha3_device_class_list import V1alpha3DeviceClassList from kubernetes.client.models.v1alpha3_device_class_spec import V1alpha3DeviceClassSpec from kubernetes.client.models.v1alpha3_device_constraint import V1alpha3DeviceConstraint +from kubernetes.client.models.v1alpha3_device_counter_consumption import V1alpha3DeviceCounterConsumption from kubernetes.client.models.v1alpha3_device_request import V1alpha3DeviceRequest from kubernetes.client.models.v1alpha3_device_request_allocation_result import V1alpha3DeviceRequestAllocationResult from kubernetes.client.models.v1alpha3_device_selector import V1alpha3DeviceSelector +from kubernetes.client.models.v1alpha3_device_sub_request import V1alpha3DeviceSubRequest +from kubernetes.client.models.v1alpha3_device_taint import V1alpha3DeviceTaint +from kubernetes.client.models.v1alpha3_device_taint_rule import V1alpha3DeviceTaintRule +from kubernetes.client.models.v1alpha3_device_taint_rule_list import V1alpha3DeviceTaintRuleList +from kubernetes.client.models.v1alpha3_device_taint_rule_spec import V1alpha3DeviceTaintRuleSpec +from kubernetes.client.models.v1alpha3_device_taint_selector import V1alpha3DeviceTaintSelector +from kubernetes.client.models.v1alpha3_device_toleration import V1alpha3DeviceToleration from kubernetes.client.models.v1alpha3_network_device_data import V1alpha3NetworkDeviceData from kubernetes.client.models.v1alpha3_opaque_device_configuration import V1alpha3OpaqueDeviceConfiguration from kubernetes.client.models.v1alpha3_resource_claim import V1alpha3ResourceClaim @@ -632,6 +654,11 @@ from kubernetes.client.models.v1beta1_audit_annotation import V1beta1AuditAnnotation from kubernetes.client.models.v1beta1_basic_device import V1beta1BasicDevice from kubernetes.client.models.v1beta1_cel_device_selector import V1beta1CELDeviceSelector +from kubernetes.client.models.v1beta1_cluster_trust_bundle import V1beta1ClusterTrustBundle +from kubernetes.client.models.v1beta1_cluster_trust_bundle_list import V1beta1ClusterTrustBundleList +from kubernetes.client.models.v1beta1_cluster_trust_bundle_spec import V1beta1ClusterTrustBundleSpec +from kubernetes.client.models.v1beta1_counter import V1beta1Counter +from kubernetes.client.models.v1beta1_counter_set import V1beta1CounterSet from kubernetes.client.models.v1beta1_device import V1beta1Device from kubernetes.client.models.v1beta1_device_allocation_configuration import V1beta1DeviceAllocationConfiguration from kubernetes.client.models.v1beta1_device_allocation_result import V1beta1DeviceAllocationResult @@ -644,13 +671,20 @@ from kubernetes.client.models.v1beta1_device_class_list import V1beta1DeviceClassList from kubernetes.client.models.v1beta1_device_class_spec import V1beta1DeviceClassSpec from kubernetes.client.models.v1beta1_device_constraint import V1beta1DeviceConstraint +from kubernetes.client.models.v1beta1_device_counter_consumption import V1beta1DeviceCounterConsumption from kubernetes.client.models.v1beta1_device_request import V1beta1DeviceRequest from kubernetes.client.models.v1beta1_device_request_allocation_result import V1beta1DeviceRequestAllocationResult from kubernetes.client.models.v1beta1_device_selector import V1beta1DeviceSelector +from kubernetes.client.models.v1beta1_device_sub_request import V1beta1DeviceSubRequest +from kubernetes.client.models.v1beta1_device_taint import V1beta1DeviceTaint +from kubernetes.client.models.v1beta1_device_toleration import V1beta1DeviceToleration from kubernetes.client.models.v1beta1_expression_warning import V1beta1ExpressionWarning from kubernetes.client.models.v1beta1_ip_address import V1beta1IPAddress from kubernetes.client.models.v1beta1_ip_address_list import V1beta1IPAddressList from kubernetes.client.models.v1beta1_ip_address_spec import V1beta1IPAddressSpec +from kubernetes.client.models.v1beta1_lease_candidate import V1beta1LeaseCandidate +from kubernetes.client.models.v1beta1_lease_candidate_list import V1beta1LeaseCandidateList +from kubernetes.client.models.v1beta1_lease_candidate_spec import V1beta1LeaseCandidateSpec from kubernetes.client.models.v1beta1_match_condition import V1beta1MatchCondition from kubernetes.client.models.v1beta1_match_resources import V1beta1MatchResources from kubernetes.client.models.v1beta1_named_rule_with_operations import V1beta1NamedRuleWithOperations @@ -671,8 +705,6 @@ from kubernetes.client.models.v1beta1_resource_slice import V1beta1ResourceSlice from kubernetes.client.models.v1beta1_resource_slice_list import V1beta1ResourceSliceList from kubernetes.client.models.v1beta1_resource_slice_spec import V1beta1ResourceSliceSpec -from kubernetes.client.models.v1beta1_self_subject_review import V1beta1SelfSubjectReview -from kubernetes.client.models.v1beta1_self_subject_review_status import V1beta1SelfSubjectReviewStatus from kubernetes.client.models.v1beta1_service_cidr import V1beta1ServiceCIDR from kubernetes.client.models.v1beta1_service_cidr_list import V1beta1ServiceCIDRList from kubernetes.client.models.v1beta1_service_cidr_spec import V1beta1ServiceCIDRSpec @@ -689,6 +721,45 @@ from kubernetes.client.models.v1beta1_variable import V1beta1Variable from kubernetes.client.models.v1beta1_volume_attributes_class import V1beta1VolumeAttributesClass from kubernetes.client.models.v1beta1_volume_attributes_class_list import V1beta1VolumeAttributesClassList +from kubernetes.client.models.v1beta2_allocated_device_status import V1beta2AllocatedDeviceStatus +from kubernetes.client.models.v1beta2_allocation_result import V1beta2AllocationResult +from kubernetes.client.models.v1beta2_cel_device_selector import V1beta2CELDeviceSelector +from kubernetes.client.models.v1beta2_counter import V1beta2Counter +from kubernetes.client.models.v1beta2_counter_set import V1beta2CounterSet +from kubernetes.client.models.v1beta2_device import V1beta2Device +from kubernetes.client.models.v1beta2_device_allocation_configuration import V1beta2DeviceAllocationConfiguration +from kubernetes.client.models.v1beta2_device_allocation_result import V1beta2DeviceAllocationResult +from kubernetes.client.models.v1beta2_device_attribute import V1beta2DeviceAttribute +from kubernetes.client.models.v1beta2_device_capacity import V1beta2DeviceCapacity +from kubernetes.client.models.v1beta2_device_claim import V1beta2DeviceClaim +from kubernetes.client.models.v1beta2_device_claim_configuration import V1beta2DeviceClaimConfiguration +from kubernetes.client.models.v1beta2_device_class import V1beta2DeviceClass +from kubernetes.client.models.v1beta2_device_class_configuration import V1beta2DeviceClassConfiguration +from kubernetes.client.models.v1beta2_device_class_list import V1beta2DeviceClassList +from kubernetes.client.models.v1beta2_device_class_spec import V1beta2DeviceClassSpec +from kubernetes.client.models.v1beta2_device_constraint import V1beta2DeviceConstraint +from kubernetes.client.models.v1beta2_device_counter_consumption import V1beta2DeviceCounterConsumption +from kubernetes.client.models.v1beta2_device_request import V1beta2DeviceRequest +from kubernetes.client.models.v1beta2_device_request_allocation_result import V1beta2DeviceRequestAllocationResult +from kubernetes.client.models.v1beta2_device_selector import V1beta2DeviceSelector +from kubernetes.client.models.v1beta2_device_sub_request import V1beta2DeviceSubRequest +from kubernetes.client.models.v1beta2_device_taint import V1beta2DeviceTaint +from kubernetes.client.models.v1beta2_device_toleration import V1beta2DeviceToleration +from kubernetes.client.models.v1beta2_exact_device_request import V1beta2ExactDeviceRequest +from kubernetes.client.models.v1beta2_network_device_data import V1beta2NetworkDeviceData +from kubernetes.client.models.v1beta2_opaque_device_configuration import V1beta2OpaqueDeviceConfiguration +from kubernetes.client.models.v1beta2_resource_claim import V1beta2ResourceClaim +from kubernetes.client.models.v1beta2_resource_claim_consumer_reference import V1beta2ResourceClaimConsumerReference +from kubernetes.client.models.v1beta2_resource_claim_list import V1beta2ResourceClaimList +from kubernetes.client.models.v1beta2_resource_claim_spec import V1beta2ResourceClaimSpec +from kubernetes.client.models.v1beta2_resource_claim_status import V1beta2ResourceClaimStatus +from kubernetes.client.models.v1beta2_resource_claim_template import V1beta2ResourceClaimTemplate +from kubernetes.client.models.v1beta2_resource_claim_template_list import V1beta2ResourceClaimTemplateList +from kubernetes.client.models.v1beta2_resource_claim_template_spec import V1beta2ResourceClaimTemplateSpec +from kubernetes.client.models.v1beta2_resource_pool import V1beta2ResourcePool +from kubernetes.client.models.v1beta2_resource_slice import V1beta2ResourceSlice +from kubernetes.client.models.v1beta2_resource_slice_list import V1beta2ResourceSliceList +from kubernetes.client.models.v1beta2_resource_slice_spec import V1beta2ResourceSliceSpec from kubernetes.client.models.v2_container_resource_metric_source import V2ContainerResourceMetricSource from kubernetes.client.models.v2_container_resource_metric_status import V2ContainerResourceMetricStatus from kubernetes.client.models.v2_cross_version_object_reference import V2CrossVersionObjectReference diff --git a/contrib/python/kubernetes/kubernetes/client/api/__init__.py b/contrib/python/kubernetes/kubernetes/client/api/__init__.py index 769f9a2f67e6..ac167ebffb93 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/__init__.py +++ b/contrib/python/kubernetes/kubernetes/client/api/__init__.py @@ -17,7 +17,6 @@ from kubernetes.client.api.apps_v1_api import AppsV1Api from kubernetes.client.api.authentication_api import AuthenticationApi from kubernetes.client.api.authentication_v1_api import AuthenticationV1Api -from kubernetes.client.api.authentication_v1beta1_api import AuthenticationV1beta1Api from kubernetes.client.api.authorization_api import AuthorizationApi from kubernetes.client.api.authorization_v1_api import AuthorizationV1Api from kubernetes.client.api.autoscaling_api import AutoscalingApi @@ -28,9 +27,11 @@ from kubernetes.client.api.certificates_api import CertificatesApi from kubernetes.client.api.certificates_v1_api import CertificatesV1Api from kubernetes.client.api.certificates_v1alpha1_api import CertificatesV1alpha1Api +from kubernetes.client.api.certificates_v1beta1_api import CertificatesV1beta1Api from kubernetes.client.api.coordination_api import CoordinationApi from kubernetes.client.api.coordination_v1_api import CoordinationV1Api from kubernetes.client.api.coordination_v1alpha2_api import CoordinationV1alpha2Api +from kubernetes.client.api.coordination_v1beta1_api import CoordinationV1beta1Api from kubernetes.client.api.core_api import CoreApi from kubernetes.client.api.core_v1_api import CoreV1Api from kubernetes.client.api.custom_objects_api import CustomObjectsApi @@ -56,6 +57,7 @@ from kubernetes.client.api.resource_api import ResourceApi from kubernetes.client.api.resource_v1alpha3_api import ResourceV1alpha3Api from kubernetes.client.api.resource_v1beta1_api import ResourceV1beta1Api +from kubernetes.client.api.resource_v1beta2_api import ResourceV1beta2Api from kubernetes.client.api.scheduling_api import SchedulingApi from kubernetes.client.api.scheduling_v1_api import SchedulingV1Api from kubernetes.client.api.storage_api import StorageApi diff --git a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_api.py b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_api.py index 98e4c493bfd1..edfb06e15ef6 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1_api.py index 2c86d51ca422..be25b990e639 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1alpha1_api.py index 7ae59436c97b..fbbddd11d827 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1alpha1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1alpha1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1beta1_api.py b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1beta1_api.py index 30b795490e02..15e2c3bd3d8d 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1beta1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/admissionregistration_v1beta1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apiextensions_api.py b/contrib/python/kubernetes/kubernetes/client/api/apiextensions_api.py index 203566e6056c..a7229730a626 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apiextensions_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apiextensions_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apiextensions_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/apiextensions_v1_api.py index 30bf08aec793..b21a961bdf21 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apiextensions_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apiextensions_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apiregistration_api.py b/contrib/python/kubernetes/kubernetes/client/api/apiregistration_api.py index 836f3f25369b..518cf225e26b 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apiregistration_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apiregistration_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apiregistration_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/apiregistration_v1_api.py index 2305fd35f584..0d705471ca18 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apiregistration_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apiregistration_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apis_api.py b/contrib/python/kubernetes/kubernetes/client/api/apis_api.py index d6584f050d92..359fe3144811 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apis_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apis_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apps_api.py b/contrib/python/kubernetes/kubernetes/client/api/apps_api.py index f4d1cc0364af..118c8a1860d7 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apps_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apps_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/apps_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/apps_v1_api.py index d5fefb9fea22..0c39a4fa956b 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/apps_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/apps_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/authentication_api.py b/contrib/python/kubernetes/kubernetes/client/api/authentication_api.py index 0ccc193e64c7..bd7c8c761a0f 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/authentication_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/authentication_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/authentication_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/authentication_v1_api.py index 9e7a5ba067ea..b049a9088791 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/authentication_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/authentication_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/authentication_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/authentication_v1alpha1_api.py deleted file mode 100644 index 19f3cb2873ed..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/api/authentication_v1alpha1_api.py +++ /dev/null @@ -1,276 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from kubernetes.client.api_client import ApiClient -from kubernetes.client.exceptions import ( # noqa: F401 - ApiTypeError, - ApiValueError -) - - -class AuthenticationV1alpha1Api(object): - """NOTE: This class is auto generated by OpenAPI Generator - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_self_subject_review(self, body, **kwargs): # noqa: E501 - """create_self_subject_review # noqa: E501 - - create a SelfSubjectReview # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_self_subject_review(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1alpha1SelfSubjectReview body: (required) - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1SelfSubjectReview - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.create_self_subject_review_with_http_info(body, **kwargs) # noqa: E501 - - def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E501 - """create_self_subject_review # noqa: E501 - - create a SelfSubjectReview # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_self_subject_review_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1alpha1SelfSubjectReview body: (required) - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1SelfSubjectReview, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'body', - 'dry_run', - 'field_manager', - 'field_validation', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method create_self_subject_review" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_self_subject_review`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/authentication.k8s.io/v1alpha1/selfsubjectreviews', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1SelfSubjectReview', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1APIResourceList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 - - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/authentication.k8s.io/v1alpha1/', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/contrib/python/kubernetes/kubernetes/client/api/authentication_v1beta1_api.py b/contrib/python/kubernetes/kubernetes/client/api/authentication_v1beta1_api.py deleted file mode 100644 index 64a7e05d92a0..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/api/authentication_v1beta1_api.py +++ /dev/null @@ -1,276 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.32 - Generated by: https://openapi-generator.tech -""" - - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from kubernetes.client.api_client import ApiClient -from kubernetes.client.exceptions import ( # noqa: F401 - ApiTypeError, - ApiValueError -) - - -class AuthenticationV1beta1Api(object): - """NOTE: This class is auto generated by OpenAPI Generator - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_self_subject_review(self, body, **kwargs): # noqa: E501 - """create_self_subject_review # noqa: E501 - - create a SelfSubjectReview # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_self_subject_review(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1beta1SelfSubjectReview body: (required) - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta1SelfSubjectReview - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.create_self_subject_review_with_http_info(body, **kwargs) # noqa: E501 - - def create_self_subject_review_with_http_info(self, body, **kwargs): # noqa: E501 - """create_self_subject_review # noqa: E501 - - create a SelfSubjectReview # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_self_subject_review_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1beta1SelfSubjectReview body: (required) - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta1SelfSubjectReview, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'body', - 'dry_run', - 'field_manager', - 'field_validation', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method create_self_subject_review" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_self_subject_review`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/authentication.k8s.io/v1beta1/selfsubjectreviews', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta1SelfSubjectReview', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1APIResourceList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 - - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/authentication.k8s.io/v1beta1/', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/contrib/python/kubernetes/kubernetes/client/api/authorization_api.py b/contrib/python/kubernetes/kubernetes/client/api/authorization_api.py index 10a4ccf5a689..eee6338988c7 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/authorization_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/authorization_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/authorization_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/authorization_v1_api.py index a49ae2be6ba4..1a87ee91ef91 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/authorization_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/authorization_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/autoscaling_api.py b/contrib/python/kubernetes/kubernetes/client/api/autoscaling_api.py index f2831549add1..d329ad2d4569 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/autoscaling_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/autoscaling_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v1_api.py index e5b86d9bf198..514903d486e3 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v2_api.py b/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v2_api.py index b0f063577553..d336add93f4f 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v2_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/autoscaling_v2_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/batch_api.py b/contrib/python/kubernetes/kubernetes/client/api/batch_api.py index 035597d34ef1..5f6f7c62ec4d 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/batch_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/batch_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/batch_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/batch_v1_api.py index e77856a32d2a..7fdc5319e3ce 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/batch_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/batch_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/certificates_api.py b/contrib/python/kubernetes/kubernetes/client/api/certificates_api.py index 2799df053971..b72b98a18381 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/certificates_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/certificates_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/certificates_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/certificates_v1_api.py index e100a727c217..842e053ea0d3 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/certificates_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/certificates_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/certificates_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/certificates_v1alpha1_api.py index 6e35b16d8b91..62ef4c69a339 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/certificates_v1alpha1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/certificates_v1alpha1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/certificates_v1beta1_api.py b/contrib/python/kubernetes/kubernetes/client/api/certificates_v1beta1_api.py new file mode 100644 index 000000000000..630983a54325 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/api/certificates_v1beta1_api.py @@ -0,0 +1,1179 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +from __future__ import absolute_import + +import re # noqa: F401 + +# python 2 and python 3 compatibility library +import six + +from kubernetes.client.api_client import ApiClient +from kubernetes.client.exceptions import ( # noqa: F401 + ApiTypeError, + ApiValueError +) + + +class CertificatesV1beta1Api(object): + """NOTE: This class is auto generated by OpenAPI Generator + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + def __init__(self, api_client=None): + if api_client is None: + api_client = ApiClient() + self.api_client = api_client + + def create_cluster_trust_bundle(self, body, **kwargs): # noqa: E501 + """create_cluster_trust_bundle # noqa: E501 + + create a ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.create_cluster_trust_bundle(body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param V1beta1ClusterTrustBundle body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1beta1ClusterTrustBundle + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.create_cluster_trust_bundle_with_http_info(body, **kwargs) # noqa: E501 + + def create_cluster_trust_bundle_with_http_info(self, body, **kwargs): # noqa: E501 + """create_cluster_trust_bundle # noqa: E501 + + create a ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.create_cluster_trust_bundle_with_http_info(body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param V1beta1ClusterTrustBundle body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method create_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_cluster_trust_bundle`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1beta1ClusterTrustBundle', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_cluster_trust_bundle(self, name, **kwargs): # noqa: E501 + """delete_cluster_trust_bundle # noqa: E501 + + delete a ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_cluster_trust_bundle(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Status + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_cluster_trust_bundle_with_http_info(name, **kwargs) # noqa: E501 + + def delete_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_cluster_trust_bundle # noqa: E501 + + delete a ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_cluster_trust_bundle_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_cluster_trust_bundle`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_collection_cluster_trust_bundle(self, **kwargs): # noqa: E501 + """delete_collection_cluster_trust_bundle # noqa: E501 + + delete collection of ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_collection_cluster_trust_bundle(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Status + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_collection_cluster_trust_bundle_with_http_info(**kwargs) # noqa: E501 + + def delete_collection_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_cluster_trust_bundle # noqa: E501 + + delete collection of ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_collection_cluster_trust_bundle_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'pretty', + '_continue', + 'dry_run', + 'field_selector', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', + 'orphan_dependents', + 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_collection_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def get_api_resources(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 + + get available resources # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_api_resources(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1APIResourceList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 + + def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 + + get available resources # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_api_resources_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method get_api_resources" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1APIResourceList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_cluster_trust_bundle(self, **kwargs): # noqa: E501 + """list_cluster_trust_bundle # noqa: E501 + + list or watch objects of kind ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_cluster_trust_bundle(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1beta1ClusterTrustBundleList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_cluster_trust_bundle_with_http_info(**kwargs) # noqa: E501 + + def list_cluster_trust_bundle_with_http_info(self, **kwargs): # noqa: E501 + """list_cluster_trust_bundle # noqa: E501 + + list or watch objects of kind ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_cluster_trust_bundle_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1beta1ClusterTrustBundleList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1beta1ClusterTrustBundleList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def patch_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501 + """patch_cluster_trust_bundle # noqa: E501 + + partially update the specified ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_cluster_trust_bundle(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1beta1ClusterTrustBundle + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.patch_cluster_trust_bundle_with_http_info(name, body, **kwargs) # noqa: E501 + + def patch_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_cluster_trust_bundle # noqa: E501 + + partially update the specified ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_cluster_trust_bundle_with_http_info(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method patch_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_cluster_trust_bundle`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_cluster_trust_bundle`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'PATCH', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1beta1ClusterTrustBundle', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def read_cluster_trust_bundle(self, name, **kwargs): # noqa: E501 + """read_cluster_trust_bundle # noqa: E501 + + read the specified ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.read_cluster_trust_bundle(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1beta1ClusterTrustBundle + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.read_cluster_trust_bundle_with_http_info(name, **kwargs) # noqa: E501 + + def read_cluster_trust_bundle_with_http_info(self, name, **kwargs): # noqa: E501 + """read_cluster_trust_bundle # noqa: E501 + + read the specified ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.read_cluster_trust_bundle_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method read_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_cluster_trust_bundle`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1beta1ClusterTrustBundle', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def replace_cluster_trust_bundle(self, name, body, **kwargs): # noqa: E501 + """replace_cluster_trust_bundle # noqa: E501 + + replace the specified ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.replace_cluster_trust_bundle(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param V1beta1ClusterTrustBundle body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1beta1ClusterTrustBundle + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.replace_cluster_trust_bundle_with_http_info(name, body, **kwargs) # noqa: E501 + + def replace_cluster_trust_bundle_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_cluster_trust_bundle # noqa: E501 + + replace the specified ClusterTrustBundle # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.replace_cluster_trust_bundle_with_http_info(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ClusterTrustBundle (required) + :param V1beta1ClusterTrustBundle body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1beta1ClusterTrustBundle, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method replace_cluster_trust_bundle" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_cluster_trust_bundle`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_cluster_trust_bundle`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/certificates.k8s.io/v1beta1/clustertrustbundles/{name}', 'PUT', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1beta1ClusterTrustBundle', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) diff --git a/contrib/python/kubernetes/kubernetes/client/api/coordination_api.py b/contrib/python/kubernetes/kubernetes/client/api/coordination_api.py index a09515d3bead..7274ada5faef 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/coordination_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/coordination_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/coordination_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/coordination_v1_api.py index 375760fcfc6e..9a4de0340d9b 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/coordination_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/coordination_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha2_api.py b/contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha2_api.py index 7a7aebc7a9fa..440cf7804658 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha2_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha2_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/coordination_v1beta1_api.py similarity index 94% rename from contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha1_api.py rename to contrib/python/kubernetes/kubernetes/client/api/coordination_v1beta1_api.py index 951bd2115fdc..0ac7db875ad6 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/coordination_v1alpha1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/coordination_v1beta1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.31 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -24,7 +24,7 @@ ) -class CoordinationV1alpha1Api(object): +class CoordinationV1beta1Api(object): """NOTE: This class is auto generated by OpenAPI Generator Ref: https://openapi-generator.tech @@ -47,7 +47,7 @@ def create_namespaced_lease_candidate(self, namespace, body, **kwargs): # noqa: :param async_req bool: execute request asynchronously :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha1LeaseCandidate body: (required) + :param V1beta1LeaseCandidate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -59,7 +59,7 @@ def create_namespaced_lease_candidate(self, namespace, body, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha1LeaseCandidate + :return: V1beta1LeaseCandidate If the method is called asynchronously, returns the request thread. """ @@ -77,7 +77,7 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw :param async_req bool: execute request asynchronously :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha1LeaseCandidate body: (required) + :param V1beta1LeaseCandidate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -91,7 +91,7 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -158,20 +158,20 @@ def create_namespaced_lease_candidate_with_http_info(self, namespace, body, **kw body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates', 'POST', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates', 'POST', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha1LeaseCandidate', # noqa: E501 + response_type='V1beta1LeaseCandidate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -195,6 +195,7 @@ def delete_collection_namespaced_lease_candidate(self, namespace, **kwargs): # :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. @@ -234,6 +235,7 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace, :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. @@ -266,6 +268,7 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace, 'dry_run', 'field_selector', 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', 'label_selector', 'limit', 'orphan_dependents', @@ -315,6 +318,8 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace, query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 @@ -342,13 +347,13 @@ def delete_collection_namespaced_lease_candidate_with_http_info(self, namespace, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates', 'DELETE', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates', 'DELETE', path_params, query_params, header_params, @@ -378,6 +383,7 @@ def delete_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. :param V1DeleteOptions body: @@ -410,6 +416,7 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. :param V1DeleteOptions body: @@ -435,6 +442,7 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw 'pretty', 'dry_run', 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', 'orphan_dependents', 'propagation_policy', 'body' @@ -480,6 +488,8 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 @@ -495,13 +505,13 @@ def delete_namespaced_lease_candidate_with_http_info(self, name, namespace, **kw body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates/{name}', 'DELETE', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'DELETE', path_params, query_params, header_params, @@ -600,13 +610,13 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/', 'GET', + '/apis/coordination.k8s.io/v1beta1/', 'GET', path_params, query_params, header_params, @@ -649,7 +659,7 @@ def list_lease_candidate_for_all_namespaces(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha1LeaseCandidateList + :return: V1beta1LeaseCandidateList If the method is called asynchronously, returns the request thread. """ @@ -686,7 +696,7 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -760,20 +770,20 @@ def list_lease_candidate_for_all_namespaces_with_http_info(self, **kwargs): # n body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/leasecandidates', 'GET', + '/apis/coordination.k8s.io/v1beta1/leasecandidates', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha1LeaseCandidateList', # noqa: E501 + response_type='V1beta1LeaseCandidateList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -810,7 +820,7 @@ def list_namespaced_lease_candidate(self, namespace, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha1LeaseCandidateList + :return: V1beta1LeaseCandidateList If the method is called asynchronously, returns the request thread. """ @@ -848,7 +858,7 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta1LeaseCandidateList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -929,20 +939,20 @@ def list_namespaced_lease_candidate_with_http_info(self, namespace, **kwargs): body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates', 'GET', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha1LeaseCandidateList', # noqa: E501 + response_type='V1beta1LeaseCandidateList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -975,7 +985,7 @@ def patch_namespaced_lease_candidate(self, name, namespace, body, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha1LeaseCandidate + :return: V1beta1LeaseCandidate If the method is called asynchronously, returns the request thread. """ @@ -1009,7 +1019,7 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1086,24 +1096,24 @@ def patch_namespaced_lease_candidate_with_http_info(self, name, namespace, body, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # HTTP header `Content-Type` header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates/{name}', 'PATCH', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha1LeaseCandidate', # noqa: E501 + response_type='V1beta1LeaseCandidate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1131,7 +1141,7 @@ def read_namespaced_lease_candidate(self, name, namespace, **kwargs): # noqa: E number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha1LeaseCandidate + :return: V1beta1LeaseCandidate If the method is called asynchronously, returns the request thread. """ @@ -1160,7 +1170,7 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1218,20 +1228,20 @@ def read_namespaced_lease_candidate_with_http_info(self, name, namespace, **kwar body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates/{name}', 'GET', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha1LeaseCandidate', # noqa: E501 + response_type='V1beta1LeaseCandidate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1251,7 +1261,7 @@ def replace_namespaced_lease_candidate(self, name, namespace, body, **kwargs): :param async_req bool: execute request asynchronously :param str name: name of the LeaseCandidate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha1LeaseCandidate body: (required) + :param V1beta1LeaseCandidate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -1263,7 +1273,7 @@ def replace_namespaced_lease_candidate(self, name, namespace, body, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha1LeaseCandidate + :return: V1beta1LeaseCandidate If the method is called asynchronously, returns the request thread. """ @@ -1282,7 +1292,7 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod :param async_req bool: execute request asynchronously :param str name: name of the LeaseCandidate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha1LeaseCandidate body: (required) + :param V1beta1LeaseCandidate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -1296,7 +1306,7 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta1LeaseCandidate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1370,20 +1380,20 @@ def replace_namespaced_lease_candidate_with_http_info(self, name, namespace, bod body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/coordination.k8s.io/v1alpha1/namespaces/{namespace}/leasecandidates/{name}', 'PUT', + '/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha1LeaseCandidate', # noqa: E501 + response_type='V1beta1LeaseCandidate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/api/core_api.py b/contrib/python/kubernetes/kubernetes/client/api/core_api.py index 768de5b5cc1b..3c9ded93be19 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/core_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/core_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/core_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/core_v1_api.py index 8fecb0a0f5f9..fa64203bca69 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/core_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/core_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/custom_objects_api.py b/contrib/python/kubernetes/kubernetes/client/api/custom_objects_api.py index 18b24412251b..f5af0e758c54 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/custom_objects_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/custom_objects_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/discovery_api.py b/contrib/python/kubernetes/kubernetes/client/api/discovery_api.py index 7000dab3083b..040dee2897cd 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/discovery_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/discovery_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/discovery_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/discovery_v1_api.py index 69e865f2bcbc..f775778bd012 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/discovery_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/discovery_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/events_api.py b/contrib/python/kubernetes/kubernetes/client/api/events_api.py index 5e79cf1a6d6a..66f02f41b7be 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/events_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/events_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/events_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/events_v1_api.py index f13fea22fb72..1ca196fe533d 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/events_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/events_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_api.py b/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_api.py index a8107bacf09d..26664da0ec8b 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1_api.py index e98ef374c7c1..75eb2b10b5e9 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1beta3_api.py b/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1beta3_api.py deleted file mode 100644 index c6c84177ebe3..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/api/flowcontrol_apiserver_v1beta3_api.py +++ /dev/null @@ -1,3024 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from kubernetes.client.api_client import ApiClient -from kubernetes.client.exceptions import ( # noqa: F401 - ApiTypeError, - ApiValueError -) - - -class FlowcontrolApiserverV1beta3Api(object): - """NOTE: This class is auto generated by OpenAPI Generator - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_flow_schema(self, body, **kwargs): # noqa: E501 - """create_flow_schema # noqa: E501 - - create a FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_flow_schema(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1beta3FlowSchema body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.create_flow_schema_with_http_info(body, **kwargs) # noqa: E501 - - def create_flow_schema_with_http_info(self, body, **kwargs): # noqa: E501 - """create_flow_schema # noqa: E501 - - create a FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_flow_schema_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1beta3FlowSchema body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method create_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_flow_schema`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_priority_level_configuration(self, body, **kwargs): # noqa: E501 - """create_priority_level_configuration # noqa: E501 - - create a PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_priority_level_configuration(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1beta3PriorityLevelConfiguration body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.create_priority_level_configuration_with_http_info(body, **kwargs) # noqa: E501 - - def create_priority_level_configuration_with_http_info(self, body, **kwargs): # noqa: E501 - """create_priority_level_configuration # noqa: E501 - - create a PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_priority_level_configuration_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1beta3PriorityLevelConfiguration body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method create_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_priority_level_configuration`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_collection_flow_schema(self, **kwargs): # noqa: E501 - """delete_collection_flow_schema # noqa: E501 - - delete collection of FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_flow_schema(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_collection_flow_schema_with_http_info(**kwargs) # noqa: E501 - - def delete_collection_flow_schema_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_flow_schema # noqa: E501 - - delete collection of FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_flow_schema_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - '_continue', - 'dry_run', - 'field_selector', - 'grace_period_seconds', - 'label_selector', - 'limit', - 'orphan_dependents', - 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_collection_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_collection_priority_level_configuration(self, **kwargs): # noqa: E501 - """delete_collection_priority_level_configuration # noqa: E501 - - delete collection of PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_priority_level_configuration(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_collection_priority_level_configuration_with_http_info(**kwargs) # noqa: E501 - - def delete_collection_priority_level_configuration_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_priority_level_configuration # noqa: E501 - - delete collection of PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_priority_level_configuration_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - '_continue', - 'dry_run', - 'field_selector', - 'grace_period_seconds', - 'label_selector', - 'limit', - 'orphan_dependents', - 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_collection_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_flow_schema(self, name, **kwargs): # noqa: E501 - """delete_flow_schema # noqa: E501 - - delete a FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_flow_schema(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_flow_schema_with_http_info(name, **kwargs) # noqa: E501 - - def delete_flow_schema_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_flow_schema # noqa: E501 - - delete a FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_flow_schema_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_flow_schema`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_priority_level_configuration(self, name, **kwargs): # noqa: E501 - """delete_priority_level_configuration # noqa: E501 - - delete a PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_priority_level_configuration(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_priority_level_configuration_with_http_info(name, **kwargs) # noqa: E501 - - def delete_priority_level_configuration_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_priority_level_configuration # noqa: E501 - - delete a PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_priority_level_configuration_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_priority_level_configuration`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1APIResourceList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 - - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_flow_schema(self, **kwargs): # noqa: E501 - """list_flow_schema # noqa: E501 - - list or watch objects of kind FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_flow_schema(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchemaList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_flow_schema_with_http_info(**kwargs) # noqa: E501 - - def list_flow_schema_with_http_info(self, **kwargs): # noqa: E501 - """list_flow_schema # noqa: E501 - - list or watch objects of kind FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_flow_schema_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchemaList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchemaList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_priority_level_configuration(self, **kwargs): # noqa: E501 - """list_priority_level_configuration # noqa: E501 - - list or watch objects of kind PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_priority_level_configuration(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfigurationList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_priority_level_configuration_with_http_info(**kwargs) # noqa: E501 - - def list_priority_level_configuration_with_http_info(self, **kwargs): # noqa: E501 - """list_priority_level_configuration # noqa: E501 - - list or watch objects of kind PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_priority_level_configuration_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfigurationList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfigurationList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_flow_schema(self, name, body, **kwargs): # noqa: E501 - """patch_flow_schema # noqa: E501 - - partially update the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_flow_schema(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_flow_schema_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_flow_schema_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_flow_schema # noqa: E501 - - partially update the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_flow_schema_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_flow_schema`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_flow_schema`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_flow_schema_status(self, name, body, **kwargs): # noqa: E501 - """patch_flow_schema_status # noqa: E501 - - partially update status of the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_flow_schema_status(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_flow_schema_status_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_flow_schema_status_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_flow_schema_status # noqa: E501 - - partially update status of the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_flow_schema_status_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_flow_schema_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_flow_schema_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_flow_schema_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}/status', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_priority_level_configuration(self, name, body, **kwargs): # noqa: E501 - """patch_priority_level_configuration # noqa: E501 - - partially update the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_priority_level_configuration(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_priority_level_configuration_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_priority_level_configuration_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_priority_level_configuration # noqa: E501 - - partially update the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_priority_level_configuration_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_priority_level_configuration`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_priority_level_configuration`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_priority_level_configuration_status(self, name, body, **kwargs): # noqa: E501 - """patch_priority_level_configuration_status # noqa: E501 - - partially update status of the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_priority_level_configuration_status(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_priority_level_configuration_status_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_priority_level_configuration_status_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_priority_level_configuration_status # noqa: E501 - - partially update status of the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_priority_level_configuration_status_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_priority_level_configuration_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_priority_level_configuration_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_priority_level_configuration_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}/status', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_flow_schema(self, name, **kwargs): # noqa: E501 - """read_flow_schema # noqa: E501 - - read the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_flow_schema(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_flow_schema_with_http_info(name, **kwargs) # noqa: E501 - - def read_flow_schema_with_http_info(self, name, **kwargs): # noqa: E501 - """read_flow_schema # noqa: E501 - - read the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_flow_schema_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_flow_schema`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_flow_schema_status(self, name, **kwargs): # noqa: E501 - """read_flow_schema_status # noqa: E501 - - read status of the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_flow_schema_status(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_flow_schema_status_with_http_info(name, **kwargs) # noqa: E501 - - def read_flow_schema_status_with_http_info(self, name, **kwargs): # noqa: E501 - """read_flow_schema_status # noqa: E501 - - read status of the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_flow_schema_status_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_flow_schema_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_flow_schema_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}/status', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_priority_level_configuration(self, name, **kwargs): # noqa: E501 - """read_priority_level_configuration # noqa: E501 - - read the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_priority_level_configuration(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_priority_level_configuration_with_http_info(name, **kwargs) # noqa: E501 - - def read_priority_level_configuration_with_http_info(self, name, **kwargs): # noqa: E501 - """read_priority_level_configuration # noqa: E501 - - read the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_priority_level_configuration_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_priority_level_configuration`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_priority_level_configuration_status(self, name, **kwargs): # noqa: E501 - """read_priority_level_configuration_status # noqa: E501 - - read status of the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_priority_level_configuration_status(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_priority_level_configuration_status_with_http_info(name, **kwargs) # noqa: E501 - - def read_priority_level_configuration_status_with_http_info(self, name, **kwargs): # noqa: E501 - """read_priority_level_configuration_status # noqa: E501 - - read status of the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_priority_level_configuration_status_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_priority_level_configuration_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_priority_level_configuration_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}/status', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_flow_schema(self, name, body, **kwargs): # noqa: E501 - """replace_flow_schema # noqa: E501 - - replace the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_flow_schema(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param V1beta3FlowSchema body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_flow_schema_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_flow_schema_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_flow_schema # noqa: E501 - - replace the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_flow_schema_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param V1beta3FlowSchema body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_flow_schema" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_flow_schema`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_flow_schema`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_flow_schema_status(self, name, body, **kwargs): # noqa: E501 - """replace_flow_schema_status # noqa: E501 - - replace status of the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_flow_schema_status(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param V1beta3FlowSchema body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3FlowSchema - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_flow_schema_status_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_flow_schema_status_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_flow_schema_status # noqa: E501 - - replace status of the specified FlowSchema # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_flow_schema_status_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the FlowSchema (required) - :param V1beta3FlowSchema body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3FlowSchema, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_flow_schema_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_flow_schema_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_flow_schema_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/flowschemas/{name}/status', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3FlowSchema', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_priority_level_configuration(self, name, body, **kwargs): # noqa: E501 - """replace_priority_level_configuration # noqa: E501 - - replace the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_priority_level_configuration(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param V1beta3PriorityLevelConfiguration body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_priority_level_configuration_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_priority_level_configuration_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_priority_level_configuration # noqa: E501 - - replace the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_priority_level_configuration_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param V1beta3PriorityLevelConfiguration body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_priority_level_configuration" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_priority_level_configuration`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_priority_level_configuration`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_priority_level_configuration_status(self, name, body, **kwargs): # noqa: E501 - """replace_priority_level_configuration_status # noqa: E501 - - replace status of the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_priority_level_configuration_status(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param V1beta3PriorityLevelConfiguration body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1beta3PriorityLevelConfiguration - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_priority_level_configuration_status_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_priority_level_configuration_status_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_priority_level_configuration_status # noqa: E501 - - replace status of the specified PriorityLevelConfiguration # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_priority_level_configuration_status_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PriorityLevelConfiguration (required) - :param V1beta3PriorityLevelConfiguration body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1beta3PriorityLevelConfiguration, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_priority_level_configuration_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_priority_level_configuration_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_priority_level_configuration_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/flowcontrol.apiserver.k8s.io/v1beta3/prioritylevelconfigurations/{name}/status', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1beta3PriorityLevelConfiguration', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_api.py b/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_api.py index c84768aa8f6b..091b5e934ac5 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_v1alpha1_api.py index 24b41f29bf9b..795da4f47aff 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_v1alpha1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/internal_apiserver_v1alpha1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/logs_api.py b/contrib/python/kubernetes/kubernetes/client/api/logs_api.py index 3b4ff1c96bff..ec1463e8e3c8 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/logs_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/logs_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/networking_api.py b/contrib/python/kubernetes/kubernetes/client/api/networking_api.py index 658e9638bebd..3f3ebdaa2fb7 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/networking_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/networking_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/networking_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/networking_v1_api.py index 0dec5b2e0b41..0a078d846c96 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/networking_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/networking_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -170,6 +170,140 @@ def create_ingress_class_with_http_info(self, body, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) + def create_ip_address(self, body, **kwargs): # noqa: E501 + """create_ip_address # noqa: E501 + + create an IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.create_ip_address(body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param V1IPAddress body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IPAddress + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.create_ip_address_with_http_info(body, **kwargs) # noqa: E501 + + def create_ip_address_with_http_info(self, body, **kwargs): # noqa: E501 + """create_ip_address # noqa: E501 + + create an IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.create_ip_address_with_http_info(body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param V1IPAddress body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IPAddress, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method create_ip_address" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_ip_address`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ipaddresses', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IPAddress', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + def create_namespaced_ingress(self, namespace, body, **kwargs): # noqa: E501 """create_namespaced_ingress # noqa: E501 @@ -456,31 +590,21 @@ def create_namespaced_network_policy_with_http_info(self, namespace, body, **kwa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_ingress_class(self, **kwargs): # noqa: E501 - """delete_collection_ingress_class # noqa: E501 + def create_service_cidr(self, body, **kwargs): # noqa: E501 + """create_service_cidr # noqa: E501 - delete collection of IngressClass # noqa: E501 + create a ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_ingress_class(async_req=True) + >>> thread = api.create_service_cidr(body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param V1ServiceCIDR body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -488,38 +612,28 @@ def delete_collection_ingress_class(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_ingress_class_with_http_info(**kwargs) # noqa: E501 + return self.create_service_cidr_with_http_info(body, **kwargs) # noqa: E501 - def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_ingress_class # noqa: E501 + def create_service_cidr_with_http_info(self, body, **kwargs): # noqa: E501 + """create_service_cidr # noqa: E501 - delete collection of IngressClass # noqa: E501 + create a ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_ingress_class_with_http_info(async_req=True) + >>> thread = api.create_service_cidr_with_http_info(body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param V1ServiceCIDR body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -529,7 +643,7 @@ def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E50 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -537,21 +651,11 @@ def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E50 local_var_params = locals() all_params = [ + 'body', 'pretty', - '_continue', 'dry_run', - 'field_selector', - 'grace_period_seconds', - 'ignore_store_read_error_with_cluster_breaking_potential', - 'label_selector', - 'limit', - 'orphan_dependents', - 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'body' + 'field_manager', + 'field_validation' ] all_params.extend( [ @@ -566,10 +670,14 @@ def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E50 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_ingress_class" % key + " to method create_service_cidr" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_service_cidr`") # noqa: E501 collection_formats = {} @@ -578,32 +686,12 @@ def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E50 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 - query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -621,14 +709,14 @@ def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E50 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingressclasses', 'DELETE', + '/apis/networking.k8s.io/v1/servicecidrs', 'POST', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -636,17 +724,16 @@ def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E50 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_ingress(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_ingress # noqa: E501 + def delete_collection_ingress_class(self, **kwargs): # noqa: E501 + """delete_collection_ingress_class # noqa: E501 - delete collection of Ingress # noqa: E501 + delete collection of IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_ingress(namespace, async_req=True) + >>> thread = api.delete_collection_ingress_class(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -674,19 +761,18 @@ def delete_collection_namespaced_ingress(self, namespace, **kwargs): # noqa: E5 returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_ingress_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_collection_ingress_class_with_http_info(**kwargs) # noqa: E501 - def delete_collection_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_ingress # noqa: E501 + def delete_collection_ingress_class_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_ingress_class # noqa: E501 - delete collection of Ingress # noqa: E501 + delete collection of IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_ingress_with_http_info(namespace, async_req=True) + >>> thread = api.delete_collection_ingress_class_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -719,7 +805,6 @@ def delete_collection_namespaced_ingress_with_http_info(self, namespace, **kwarg local_var_params = locals() all_params = [ - 'namespace', 'pretty', '_continue', 'dry_run', @@ -749,20 +834,14 @@ def delete_collection_namespaced_ingress_with_http_info(self, namespace, **kwarg if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_ingress" % key + " to method delete_collection_ingress_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_ingress`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -810,7 +889,7 @@ def delete_collection_namespaced_ingress_with_http_info(self, namespace, **kwarg auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses', 'DELETE', + '/apis/networking.k8s.io/v1/ingressclasses', 'DELETE', path_params, query_params, header_params, @@ -825,17 +904,16 @@ def delete_collection_namespaced_ingress_with_http_info(self, namespace, **kwarg _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_network_policy(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_network_policy # noqa: E501 + def delete_collection_ip_address(self, **kwargs): # noqa: E501 + """delete_collection_ip_address # noqa: E501 - delete collection of NetworkPolicy # noqa: E501 + delete collection of IPAddress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_network_policy(namespace, async_req=True) + >>> thread = api.delete_collection_ip_address(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -863,19 +941,18 @@ def delete_collection_namespaced_network_policy(self, namespace, **kwargs): # n returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_network_policy_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_collection_ip_address_with_http_info(**kwargs) # noqa: E501 - def delete_collection_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_network_policy # noqa: E501 + def delete_collection_ip_address_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_ip_address # noqa: E501 - delete collection of NetworkPolicy # noqa: E501 + delete collection of IPAddress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_network_policy_with_http_info(namespace, async_req=True) + >>> thread = api.delete_collection_ip_address_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -908,7 +985,6 @@ def delete_collection_namespaced_network_policy_with_http_info(self, namespace, local_var_params = locals() all_params = [ - 'namespace', 'pretty', '_continue', 'dry_run', @@ -938,20 +1014,14 @@ def delete_collection_namespaced_network_policy_with_http_info(self, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_network_policy" % key + " to method delete_collection_ip_address" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_network_policy`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -999,7 +1069,7 @@ def delete_collection_namespaced_network_policy_with_http_info(self, namespace, auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies', 'DELETE', + '/apis/networking.k8s.io/v1/ipaddresses', 'DELETE', path_params, query_params, header_params, @@ -1014,23 +1084,31 @@ def delete_collection_namespaced_network_policy_with_http_info(self, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_ingress_class(self, name, **kwargs): # noqa: E501 - """delete_ingress_class # noqa: E501 + def delete_collection_namespaced_ingress(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_ingress # noqa: E501 - delete an IngressClass # noqa: E501 + delete collection of Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_ingress_class(name, async_req=True) + >>> thread = api.delete_collection_namespaced_ingress(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1044,25 +1122,33 @@ def delete_ingress_class(self, name, **kwargs): # noqa: E501 returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_ingress_class_with_http_info(name, **kwargs) # noqa: E501 + return self.delete_collection_namespaced_ingress_with_http_info(namespace, **kwargs) # noqa: E501 - def delete_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_ingress_class # noqa: E501 + def delete_collection_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_ingress # noqa: E501 - delete an IngressClass # noqa: E501 + delete collection of Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_ingress_class_with_http_info(name, async_req=True) + >>> thread = api.delete_collection_namespaced_ingress_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1081,13 +1167,21 @@ def delete_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ - 'name', + 'namespace', 'pretty', + '_continue', 'dry_run', + 'field_selector', 'grace_period_seconds', 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', 'orphan_dependents', 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', 'body' ] all_params.extend( @@ -1103,34 +1197,50 @@ def delete_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_ingress_class" % key + " to method delete_collection_namespaced_ingress" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_ingress_class`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_ingress`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1148,7 +1258,7 @@ def delete_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'DELETE', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses', 'DELETE', path_params, query_params, header_params, @@ -1163,24 +1273,31 @@ def delete_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_namespaced_ingress(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_ingress # noqa: E501 + def delete_collection_namespaced_network_policy(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_network_policy # noqa: E501 - delete an Ingress # noqa: E501 + delete collection of NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_ingress(name, namespace, async_req=True) + >>> thread = api.delete_collection_namespaced_network_policy(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1194,26 +1311,33 @@ def delete_namespaced_ingress(self, name, namespace, **kwargs): # noqa: E501 returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_namespaced_ingress_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.delete_collection_namespaced_network_policy_with_http_info(namespace, **kwargs) # noqa: E501 - def delete_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_ingress # noqa: E501 + def delete_collection_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_network_policy # noqa: E501 - delete an Ingress # noqa: E501 + delete collection of NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_ingress_with_http_info(name, namespace, async_req=True) + >>> thread = api.delete_collection_namespaced_network_policy_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1232,14 +1356,21 @@ def delete_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): local_var_params = locals() all_params = [ - 'name', 'namespace', 'pretty', + '_continue', 'dry_run', + 'field_selector', 'grace_period_seconds', 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', 'orphan_dependents', 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', 'body' ] all_params.extend( @@ -1255,40 +1386,50 @@ def delete_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_ingress" % key + " to method delete_collection_namespaced_network_policy" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_ingress`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_network_policy`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 if 'namespace' in local_var_params: path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1306,7 +1447,7 @@ def delete_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'DELETE', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies', 'DELETE', path_params, query_params, header_params, @@ -1321,24 +1462,30 @@ def delete_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_namespaced_network_policy(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_network_policy # noqa: E501 + def delete_collection_service_cidr(self, **kwargs): # noqa: E501 + """delete_collection_service_cidr # noqa: E501 - delete a NetworkPolicy # noqa: E501 + delete collection of ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_network_policy(name, namespace, async_req=True) + >>> thread = api.delete_collection_service_cidr(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1352,26 +1499,32 @@ def delete_namespaced_network_policy(self, name, namespace, **kwargs): # noqa: returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_namespaced_network_policy_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.delete_collection_service_cidr_with_http_info(**kwargs) # noqa: E501 - def delete_namespaced_network_policy_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_network_policy # noqa: E501 + def delete_collection_service_cidr_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_service_cidr # noqa: E501 - delete a NetworkPolicy # noqa: E501 + delete collection of ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_network_policy_with_http_info(name, namespace, async_req=True) + >>> thread = api.delete_collection_service_cidr_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1390,14 +1543,20 @@ def delete_namespaced_network_policy_with_http_info(self, name, namespace, **kwa local_var_params = locals() all_params = [ - 'name', - 'namespace', 'pretty', + '_continue', 'dry_run', + 'field_selector', 'grace_period_seconds', 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', 'orphan_dependents', 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', 'body' ] all_params.extend( @@ -1413,40 +1572,44 @@ def delete_namespaced_network_policy_with_http_info(self, name, namespace, **kwa if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_network_policy" % key + " to method delete_collection_service_cidr" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_network_policy`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_network_policy`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1464,7 +1627,7 @@ def delete_namespaced_network_policy_with_http_info(self, name, namespace, **kwa auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'DELETE', + '/apis/networking.k8s.io/v1/servicecidrs', 'DELETE', path_params, query_params, header_params, @@ -1479,16 +1642,24 @@ def delete_namespaced_network_policy_with_http_info(self, name, namespace, **kwa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 + def delete_ingress_class(self, name, **kwargs): # noqa: E501 + """delete_ingress_class # noqa: E501 - get available resources # noqa: E501 + delete an IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) + >>> thread = api.delete_ingress_class(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the IngressClass (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -1496,33 +1667,2512 @@ def get_api_resources(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1APIResourceList + :return: V1Status If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 + return self.delete_ingress_class_with_http_info(name, **kwargs) # noqa: E501 - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 + def delete_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_ingress_class # noqa: E501 - get available resources # noqa: E501 + delete an IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) + >>> thread = api.delete_ingress_class_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will + :param str name: name of the IngressClass (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_ingress_class" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_ingress_class`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_ip_address(self, name, **kwargs): # noqa: E501 + """delete_ip_address # noqa: E501 + + delete an IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_ip_address(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the IPAddress (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Status + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_ip_address_with_http_info(name, **kwargs) # noqa: E501 + + def delete_ip_address_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_ip_address # noqa: E501 + + delete an IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_ip_address_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the IPAddress (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_ip_address" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_ip_address`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ipaddresses/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_namespaced_ingress(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_ingress # noqa: E501 + + delete an Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_namespaced_ingress(name, namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Status + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_namespaced_ingress_with_http_info(name, namespace, **kwargs) # noqa: E501 + + def delete_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_ingress # noqa: E501 + + delete an Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_namespaced_ingress_with_http_info(name, namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'namespace', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_namespaced_ingress" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_ingress`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_ingress`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_namespaced_network_policy(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_network_policy # noqa: E501 + + delete a NetworkPolicy # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_namespaced_network_policy(name, namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the NetworkPolicy (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Status + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_namespaced_network_policy_with_http_info(name, namespace, **kwargs) # noqa: E501 + + def delete_namespaced_network_policy_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_network_policy # noqa: E501 + + delete a NetworkPolicy # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_namespaced_network_policy_with_http_info(name, namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the NetworkPolicy (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'namespace', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_namespaced_network_policy" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_network_policy`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_network_policy`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_service_cidr(self, name, **kwargs): # noqa: E501 + """delete_service_cidr # noqa: E501 + + delete a ServiceCIDR # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_service_cidr(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ServiceCIDR (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Status + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_service_cidr_with_http_info(name, **kwargs) # noqa: E501 + + def delete_service_cidr_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_service_cidr # noqa: E501 + + delete a ServiceCIDR # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_service_cidr_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the ServiceCIDR (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_service_cidr" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_service_cidr`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/servicecidrs/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def get_api_resources(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 + + get available resources # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_api_resources(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1APIResourceList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 + + def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 + + get available resources # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_api_resources_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method get_api_resources" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1APIResourceList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_ingress_class(self, **kwargs): # noqa: E501 + """list_ingress_class # noqa: E501 + + list or watch objects of kind IngressClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_ingress_class(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IngressClassList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_ingress_class_with_http_info(**kwargs) # noqa: E501 + + def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 + """list_ingress_class # noqa: E501 + + list or watch objects of kind IngressClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_ingress_class_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IngressClassList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_ingress_class" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ingressclasses', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IngressClassList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_ingress_for_all_namespaces(self, **kwargs): # noqa: E501 + """list_ingress_for_all_namespaces # noqa: E501 + + list or watch objects of kind Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_ingress_for_all_namespaces(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IngressList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_ingress_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 + + def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 + """list_ingress_for_all_namespaces # noqa: E501 + + list or watch objects of kind Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_ingress_for_all_namespaces_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IngressList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'pretty', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_ingress_for_all_namespaces" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ingresses', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IngressList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_ip_address(self, **kwargs): # noqa: E501 + """list_ip_address # noqa: E501 + + list or watch objects of kind IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_ip_address(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IPAddressList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_ip_address_with_http_info(**kwargs) # noqa: E501 + + def list_ip_address_with_http_info(self, **kwargs): # noqa: E501 + """list_ip_address # noqa: E501 + + list or watch objects of kind IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_ip_address_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IPAddressList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_ip_address" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ipaddresses', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IPAddressList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_namespaced_ingress(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_ingress # noqa: E501 + + list or watch objects of kind Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_namespaced_ingress(namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IngressList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_namespaced_ingress_with_http_info(namespace, **kwargs) # noqa: E501 + + def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_ingress # noqa: E501 + + list or watch objects of kind Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_namespaced_ingress_with_http_info(namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IngressList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'namespace', + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_namespaced_ingress" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_ingress`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IngressList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_namespaced_network_policy(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_network_policy # noqa: E501 + + list or watch objects of kind NetworkPolicy # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_namespaced_network_policy(namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1NetworkPolicyList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_namespaced_network_policy_with_http_info(namespace, **kwargs) # noqa: E501 + + def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_network_policy # noqa: E501 + + list or watch objects of kind NetworkPolicy # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_namespaced_network_policy_with_http_info(namespace, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1NetworkPolicyList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'namespace', + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_namespaced_network_policy" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_network_policy`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1NetworkPolicyList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_network_policy_for_all_namespaces(self, **kwargs): # noqa: E501 + """list_network_policy_for_all_namespaces # noqa: E501 + + list or watch objects of kind NetworkPolicy # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_network_policy_for_all_namespaces(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1NetworkPolicyList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_network_policy_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 + + def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 + """list_network_policy_for_all_namespaces # noqa: E501 + + list or watch objects of kind NetworkPolicy # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_network_policy_for_all_namespaces_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1NetworkPolicyList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'pretty', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_network_policy_for_all_namespaces" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/networkpolicies', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1NetworkPolicyList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def list_service_cidr(self, **kwargs): # noqa: E501 + """list_service_cidr # noqa: E501 + + list or watch objects of kind ServiceCIDR # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_service_cidr(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1ServiceCIDRList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.list_service_cidr_with_http_info(**kwargs) # noqa: E501 + + def list_service_cidr_with_http_info(self, **kwargs): # noqa: E501 + """list_service_cidr # noqa: E501 + + list or watch objects of kind ServiceCIDR # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.list_service_cidr_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1ServiceCIDRList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method list_service_cidr" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/servicecidrs', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1ServiceCIDRList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def patch_ingress_class(self, name, body, **kwargs): # noqa: E501 + """patch_ingress_class # noqa: E501 + + partially update the specified IngressClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_ingress_class(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the IngressClass (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IngressClass + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.patch_ingress_class_with_http_info(name, body, **kwargs) # noqa: E501 + + def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_ingress_class # noqa: E501 + + partially update the specified IngressClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_ingress_class_with_http_info(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the IngressClass (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IngressClass, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method patch_ingress_class" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_ingress_class`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_ingress_class`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'PATCH', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IngressClass', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def patch_ip_address(self, name, body, **kwargs): # noqa: E501 + """patch_ip_address # noqa: E501 + + partially update the specified IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_ip_address(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the IPAddress (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1IPAddress + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.patch_ip_address_with_http_info(name, body, **kwargs) # noqa: E501 + + def patch_ip_address_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_ip_address # noqa: E501 + + partially update the specified IPAddress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_ip_address_with_http_info(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the IPAddress (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1IPAddress, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method patch_ip_address" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_ip_address`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_ip_address`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/ipaddresses/{name}', 'PATCH', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1IPAddress', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def patch_namespaced_ingress(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_ingress # noqa: E501 + + partially update the specified Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_namespaced_ingress(name, namespace, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1Ingress + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.patch_namespaced_ingress_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + + def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_ingress # noqa: E501 + + partially update the specified Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_namespaced_ingress_with_http_info(name, namespace, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'namespace', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method patch_namespaced_ingress" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_ingress`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_ingress`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_ingress`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'PATCH', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Ingress', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def patch_namespaced_ingress_status(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_ingress_status # noqa: E501 + + partially update status of the specified Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_namespaced_ingress_status(name, namespace, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) + :return: V1Ingress + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.patch_namespaced_ingress_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + + def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_ingress_status # noqa: E501 + + partially update status of the specified Ingress # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_namespaced_ingress_status_with_http_info(name, namespace, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1530,6 +4180,14 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ + 'name', + 'namespace', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -1544,16 +4202,42 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key + " to method patch_namespaced_ingress_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_ingress_status`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_ingress_status`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_ingress_status`") # noqa: E501 collection_formats = {} path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -1561,22 +4245,28 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 + # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/', 'GET', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}/status', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 + response_type='V1Ingress', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1584,27 +4274,24 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def list_ingress_class(self, **kwargs): # noqa: E501 - """list_ingress_class # noqa: E501 + def patch_namespaced_network_policy(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_network_policy # noqa: E501 - list or watch objects of kind IngressClass # noqa: E501 + partially update the specified NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_ingress_class(async_req=True) + >>> thread = api.patch_namespaced_network_policy(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the NetworkPolicy (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -1612,34 +4299,31 @@ def list_ingress_class(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1IngressClassList + :return: V1NetworkPolicy If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.list_ingress_class_with_http_info(**kwargs) # noqa: E501 + return self.patch_namespaced_network_policy_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 - """list_ingress_class # noqa: E501 + def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_network_policy # noqa: E501 - list or watch objects of kind IngressClass # noqa: E501 + partially update the specified NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_ingress_class_with_http_info(async_req=True) + >>> thread = api.patch_namespaced_network_policy_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the NetworkPolicy (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -1649,7 +4333,7 @@ def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1IngressClassList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1NetworkPolicy, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1657,17 +4341,14 @@ def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ + 'name', + 'namespace', + 'body', 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -1682,38 +4363,42 @@ def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method list_ingress_class" % key + " to method patch_namespaced_network_policy" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_network_policy`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_network_policy`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_network_policy`") # noqa: E501 collection_formats = {} path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -1721,22 +4406,28 @@ def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingressclasses', 'GET', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1IngressClassList', # noqa: E501 + response_type='V1NetworkPolicy', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1744,27 +4435,23 @@ def list_ingress_class_with_http_info(self, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def list_ingress_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_ingress_for_all_namespaces # noqa: E501 + def patch_service_cidr(self, name, body, **kwargs): # noqa: E501 + """patch_service_cidr # noqa: E501 - list or watch objects of kind Ingress # noqa: E501 + partially update the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_ingress_for_all_namespaces(async_req=True) + >>> thread = api.patch_service_cidr(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str name: name of the ServiceCIDR (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -1772,34 +4459,30 @@ def list_ingress_for_all_namespaces(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1IngressList + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.list_ingress_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 + return self.patch_service_cidr_with_http_info(name, body, **kwargs) # noqa: E501 - def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_ingress_for_all_namespaces # noqa: E501 + def patch_service_cidr_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_service_cidr # noqa: E501 - list or watch objects of kind Ingress # noqa: E501 + partially update the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_ingress_for_all_namespaces_with_http_info(async_req=True) + >>> thread = api.patch_service_cidr_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str name: name of the ServiceCIDR (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -1809,7 +4492,7 @@ def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1IngressList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1817,17 +4500,13 @@ def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50 local_var_params = locals() all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', + 'name', + 'body', 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -1842,38 +4521,36 @@ def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method list_ingress_for_all_namespaces" % key + " to method patch_service_cidr" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_service_cidr`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_service_cidr`") # noqa: E501 collection_formats = {} path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -1881,22 +4558,28 @@ def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50 local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingresses', 'GET', + '/apis/networking.k8s.io/v1/servicecidrs/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1IngressList', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1904,28 +4587,23 @@ def list_ingress_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E50 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def list_namespaced_ingress(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_ingress # noqa: E501 + def patch_service_cidr_status(self, name, body, **kwargs): # noqa: E501 + """patch_service_cidr_status # noqa: E501 - list or watch objects of kind Ingress # noqa: E501 + partially update status of the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_ingress(namespace, async_req=True) + >>> thread = api.patch_service_cidr_status(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the ServiceCIDR (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -1933,35 +4611,30 @@ def list_namespaced_ingress(self, namespace, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1IngressList + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.list_namespaced_ingress_with_http_info(namespace, **kwargs) # noqa: E501 + return self.patch_service_cidr_status_with_http_info(name, body, **kwargs) # noqa: E501 - def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_ingress # noqa: E501 + def patch_service_cidr_status_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_service_cidr_status # noqa: E501 - list or watch objects of kind Ingress # noqa: E501 + partially update status of the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_ingress_with_http_info(namespace, async_req=True) + >>> thread = api.patch_service_cidr_status_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the ServiceCIDR (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -1971,7 +4644,7 @@ def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1IngressList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1979,18 +4652,13 @@ def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: local_var_params = locals() all_params = [ - 'namespace', + 'name', + 'body', 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -2005,44 +4673,36 @@ def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method list_namespaced_ingress" % key + " to method patch_service_cidr_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_ingress`") # noqa: E501 + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_service_cidr_status`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_service_cidr_status`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -2050,22 +4710,28 @@ def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses', 'GET', + '/apis/networking.k8s.io/v1/servicecidrs/{name}/status', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1IngressList', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2073,28 +4739,18 @@ def list_namespaced_ingress_with_http_info(self, namespace, **kwargs): # noqa: _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def list_namespaced_network_policy(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_network_policy # noqa: E501 + def read_ingress_class(self, name, **kwargs): # noqa: E501 + """read_ingress_class # noqa: E501 - list or watch objects of kind NetworkPolicy # noqa: E501 + read the specified IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_network_policy(namespace, async_req=True) + >>> thread = api.read_ingress_class(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the IngressClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2102,35 +4758,25 @@ def list_namespaced_network_policy(self, namespace, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1NetworkPolicyList + :return: V1IngressClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.list_namespaced_network_policy_with_http_info(namespace, **kwargs) # noqa: E501 - - def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_network_policy # noqa: E501 + return self.read_ingress_class_with_http_info(name, **kwargs) # noqa: E501 - list or watch objects of kind NetworkPolicy # noqa: E501 + def read_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 + """read_ingress_class # noqa: E501 + + read the specified IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_network_policy_with_http_info(namespace, async_req=True) + >>> thread = api.read_ingress_class_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the IngressClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2140,7 +4786,7 @@ def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1NetworkPolicyList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1IngressClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2148,18 +4794,8 @@ def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # local_var_params = locals() all_params = [ - 'namespace', - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' + 'name', + 'pretty' ] all_params.extend( [ @@ -2174,44 +4810,24 @@ def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method list_namespaced_network_policy" % key + " to method read_ingress_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_network_policy`") # noqa: E501 + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_ingress_class`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -2221,20 +4837,20 @@ def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies', 'GET', + '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1NetworkPolicyList', # noqa: E501 + response_type='V1IngressClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2242,27 +4858,18 @@ def list_namespaced_network_policy_with_http_info(self, namespace, **kwargs): # _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def list_network_policy_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_network_policy_for_all_namespaces # noqa: E501 + def read_ip_address(self, name, **kwargs): # noqa: E501 + """read_ip_address # noqa: E501 - list or watch objects of kind NetworkPolicy # noqa: E501 + read the specified IPAddress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_network_policy_for_all_namespaces(async_req=True) + >>> thread = api.read_ip_address(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str name: name of the IPAddress (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2270,34 +4877,25 @@ def list_network_policy_for_all_namespaces(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1NetworkPolicyList + :return: V1IPAddress If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.list_network_policy_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 + return self.read_ip_address_with_http_info(name, **kwargs) # noqa: E501 - def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_network_policy_for_all_namespaces # noqa: E501 + def read_ip_address_with_http_info(self, name, **kwargs): # noqa: E501 + """read_ip_address # noqa: E501 - list or watch objects of kind NetworkPolicy # noqa: E501 + read the specified IPAddress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_network_policy_for_all_namespaces_with_http_info(async_req=True) + >>> thread = api.read_ip_address_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str name: name of the IPAddress (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2307,7 +4905,7 @@ def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # no number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1NetworkPolicyList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1IPAddress, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2315,17 +4913,8 @@ def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # no local_var_params = locals() all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' + 'name', + 'pretty' ] all_params.extend( [ @@ -2340,38 +4929,24 @@ def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # no if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method list_network_policy_for_all_namespaces" % key + " to method read_ip_address" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_ip_address`") # noqa: E501 collection_formats = {} path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -2381,20 +4956,20 @@ def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # no body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/networkpolicies', 'GET', + '/apis/networking.k8s.io/v1/ipaddresses/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1NetworkPolicyList', # noqa: E501 + response_type='V1IPAddress', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2402,23 +4977,19 @@ def list_network_policy_for_all_namespaces_with_http_info(self, **kwargs): # no _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def patch_ingress_class(self, name, body, **kwargs): # noqa: E501 - """patch_ingress_class # noqa: E501 + def read_namespaced_ingress(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_ingress # noqa: E501 - partially update the specified IngressClass # noqa: E501 + read the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_ingress_class(name, body, async_req=True) + >>> thread = api.read_namespaced_ingress(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) - :param object body: (required) + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2426,30 +4997,26 @@ def patch_ingress_class(self, name, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1IngressClass + :return: V1Ingress If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.patch_ingress_class_with_http_info(name, body, **kwargs) # noqa: E501 + return self.read_namespaced_ingress_with_http_info(name, namespace, **kwargs) # noqa: E501 - def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_ingress_class # noqa: E501 + def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_ingress # noqa: E501 - partially update the specified IngressClass # noqa: E501 + read the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_ingress_class_with_http_info(name, body, async_req=True) + >>> thread = api.read_namespaced_ingress_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) - :param object body: (required) + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2459,7 +5026,7 @@ def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E50 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1IngressClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2468,12 +5035,8 @@ def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E50 all_params = [ 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' + 'namespace', + 'pretty' ] all_params.extend( [ @@ -2488,36 +5051,30 @@ def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E50 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method patch_ingress_class" % key + " to method read_namespaced_ingress" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_ingress_class`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_ingress_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_ingress`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_ingress`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -2525,28 +5082,22 @@ def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E50 local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 - # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'PATCH', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1IngressClass', # noqa: E501 + response_type='V1Ingress', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2554,24 +5105,19 @@ def patch_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E50 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def patch_namespaced_ingress(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_ingress # noqa: E501 + def read_namespaced_ingress_status(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_ingress_status # noqa: E501 - partially update the specified Ingress # noqa: E501 + read status of the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_ingress(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_ingress_status(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str name: name of the Ingress (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2584,26 +5130,21 @@ def patch_namespaced_ingress(self, name, namespace, body, **kwargs): # noqa: E5 returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.patch_namespaced_ingress_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_namespaced_ingress_status_with_http_info(name, namespace, **kwargs) # noqa: E501 - def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_ingress # noqa: E501 + def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_ingress_status # noqa: E501 - partially update the specified Ingress # noqa: E501 + read status of the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_ingress_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_ingress_status_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str name: name of the Ingress (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2623,12 +5164,7 @@ def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwarg all_params = [ 'name', 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' + 'pretty' ] all_params.extend( [ @@ -2643,22 +5179,18 @@ def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwarg if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_ingress" % key + " to method read_namespaced_ingress_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_ingress_status`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_ingress`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_ingress_status`") # noqa: E501 collection_formats = {} @@ -2671,14 +5203,6 @@ def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwarg query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -2686,21 +5210,15 @@ def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwarg local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 - # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'PATCH', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}/status', 'GET', path_params, query_params, header_params, @@ -2715,24 +5233,19 @@ def patch_namespaced_ingress_with_http_info(self, name, namespace, body, **kwarg _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def patch_namespaced_ingress_status(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_ingress_status # noqa: E501 + def read_namespaced_network_policy(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_network_policy # noqa: E501 - partially update status of the specified Ingress # noqa: E501 + read the specified NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_ingress_status(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_network_policy(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) + :param str name: name of the NetworkPolicy (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2740,31 +5253,26 @@ def patch_namespaced_ingress_status(self, name, namespace, body, **kwargs): # n number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Ingress + :return: V1NetworkPolicy If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.patch_namespaced_ingress_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_namespaced_network_policy_with_http_info(name, namespace, **kwargs) # noqa: E501 - def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_ingress_status # noqa: E501 + def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_network_policy # noqa: E501 - partially update status of the specified Ingress # noqa: E501 + read the specified NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_ingress_status_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_network_policy_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) + :param str name: name of the NetworkPolicy (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2774,7 +5282,7 @@ def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1NetworkPolicy, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2784,12 +5292,7 @@ def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, all_params = [ 'name', 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' + 'pretty' ] all_params.extend( [ @@ -2804,22 +5307,18 @@ def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_ingress_status" % key + " to method read_namespaced_network_policy" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_ingress_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_network_policy`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_ingress_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_ingress_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_network_policy`") # noqa: E501 collection_formats = {} @@ -2832,14 +5331,6 @@ def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -2847,28 +5338,22 @@ def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 - # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}/status', 'PATCH', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Ingress', # noqa: E501 + response_type='V1NetworkPolicy', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2876,24 +5361,18 @@ def patch_namespaced_ingress_status_with_http_info(self, name, namespace, body, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def patch_namespaced_network_policy(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_network_policy # noqa: E501 + def read_service_cidr(self, name, **kwargs): # noqa: E501 + """read_service_cidr # noqa: E501 - partially update the specified NetworkPolicy # noqa: E501 + read the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_network_policy(name, namespace, body, async_req=True) + >>> thread = api.read_service_cidr(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) + :param str name: name of the ServiceCIDR (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2901,31 +5380,25 @@ def patch_namespaced_network_policy(self, name, namespace, body, **kwargs): # n number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1NetworkPolicy + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.patch_namespaced_network_policy_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_service_cidr_with_http_info(name, **kwargs) # noqa: E501 - def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_network_policy # noqa: E501 + def read_service_cidr_with_http_info(self, name, **kwargs): # noqa: E501 + """read_service_cidr # noqa: E501 - partially update the specified NetworkPolicy # noqa: E501 + read the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_network_policy_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_service_cidr_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) + :param str name: name of the ServiceCIDR (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2935,7 +5408,7 @@ def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1NetworkPolicy, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2944,13 +5417,7 @@ def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, all_params = [ 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' + 'pretty' ] all_params.extend( [ @@ -2965,42 +5432,24 @@ def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_network_policy" % key + " to method read_service_cidr" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_network_policy`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_network_policy`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_network_policy`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_service_cidr`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -3008,28 +5457,22 @@ def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 - # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'PATCH', + '/apis/networking.k8s.io/v1/servicecidrs/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1NetworkPolicy', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3037,17 +5480,17 @@ def patch_namespaced_network_policy_with_http_info(self, name, namespace, body, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_ingress_class(self, name, **kwargs): # noqa: E501 - """read_ingress_class # noqa: E501 + def read_service_cidr_status(self, name, **kwargs): # noqa: E501 + """read_service_cidr_status # noqa: E501 - read the specified IngressClass # noqa: E501 + read status of the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_ingress_class(name, async_req=True) + >>> thread = api.read_service_cidr_status(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) + :param str name: name of the ServiceCIDR (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -3056,24 +5499,24 @@ def read_ingress_class(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1IngressClass + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_ingress_class_with_http_info(name, **kwargs) # noqa: E501 + return self.read_service_cidr_status_with_http_info(name, **kwargs) # noqa: E501 - def read_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 - """read_ingress_class # noqa: E501 + def read_service_cidr_status_with_http_info(self, name, **kwargs): # noqa: E501 + """read_service_cidr_status # noqa: E501 - read the specified IngressClass # noqa: E501 + read status of the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_ingress_class_with_http_info(name, async_req=True) + >>> thread = api.read_service_cidr_status_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) + :param str name: name of the ServiceCIDR (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param _return_http_data_only: response data without head status code and headers @@ -3084,7 +5527,7 @@ def read_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1IngressClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3108,14 +5551,14 @@ def read_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_ingress_class" % key + " to method read_service_cidr_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_ingress_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_service_cidr_status`") # noqa: E501 collection_formats = {} @@ -3141,14 +5584,14 @@ def read_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'GET', + '/apis/networking.k8s.io/v1/servicecidrs/{name}/status', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1IngressClass', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3156,19 +5599,22 @@ def read_ingress_class_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_ingress(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_ingress # noqa: E501 + def replace_ingress_class(self, name, body, **kwargs): # noqa: E501 + """replace_ingress_class # noqa: E501 - read the specified Ingress # noqa: E501 + replace the specified IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_ingress(name, namespace, async_req=True) + >>> thread = api.replace_ingress_class(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the IngressClass (required) + :param V1IngressClass body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -3176,26 +5622,29 @@ def read_namespaced_ingress(self, name, namespace, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Ingress + :return: V1IngressClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_ingress_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.replace_ingress_class_with_http_info(name, body, **kwargs) # noqa: E501 - def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_ingress # noqa: E501 + def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_ingress_class # noqa: E501 - read the specified Ingress # noqa: E501 + replace the specified IngressClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_ingress_with_http_info(name, namespace, async_req=True) + >>> thread = api.replace_ingress_class_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the IngressClass (required) + :param V1IngressClass body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -3205,7 +5654,7 @@ def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1IngressClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3214,8 +5663,11 @@ def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # all_params = [ 'name', - 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' ] all_params.extend( [ @@ -3230,30 +5682,34 @@ def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_ingress" % key + " to method replace_ingress_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_ingress`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_ingress_class`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_ingress_class`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -3261,6 +5717,8 @@ def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 @@ -3269,14 +5727,14 @@ def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'GET', + '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Ingress', # noqa: E501 + response_type='V1IngressClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3284,19 +5742,22 @@ def read_namespaced_ingress_with_http_info(self, name, namespace, **kwargs): # _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_ingress_status(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_ingress_status # noqa: E501 + def replace_ip_address(self, name, body, **kwargs): # noqa: E501 + """replace_ip_address # noqa: E501 - read status of the specified Ingress # noqa: E501 + replace the specified IPAddress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_ingress_status(name, namespace, async_req=True) + >>> thread = api.replace_ip_address(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the IPAddress (required) + :param V1IPAddress body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -3304,26 +5765,29 @@ def read_namespaced_ingress_status(self, name, namespace, **kwargs): # noqa: E5 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Ingress + :return: V1IPAddress If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_ingress_status_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.replace_ip_address_with_http_info(name, body, **kwargs) # noqa: E501 - def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_ingress_status # noqa: E501 + def replace_ip_address_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_ip_address # noqa: E501 - read status of the specified Ingress # noqa: E501 + replace the specified IPAddress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_ingress_status_with_http_info(name, namespace, async_req=True) + >>> thread = api.replace_ip_address_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the IPAddress (required) + :param V1IPAddress body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -3333,7 +5797,7 @@ def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwarg number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1IPAddress, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3342,8 +5806,11 @@ def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwarg all_params = [ 'name', - 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' ] all_params.extend( [ @@ -3358,30 +5825,34 @@ def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwarg if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_ingress_status" % key + " to method replace_ip_address" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_ingress_status`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_ingress_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_ip_address`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_ip_address`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -3389,6 +5860,8 @@ def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwarg local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 @@ -3397,14 +5870,14 @@ def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwarg auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}/status', 'GET', + '/apis/networking.k8s.io/v1/ipaddresses/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Ingress', # noqa: E501 + response_type='V1IPAddress', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3412,19 +5885,23 @@ def read_namespaced_ingress_status_with_http_info(self, name, namespace, **kwarg _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_network_policy(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_network_policy # noqa: E501 + def replace_namespaced_ingress(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_ingress # noqa: E501 - read the specified NetworkPolicy # noqa: E501 + replace the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_network_policy(name, namespace, async_req=True) + >>> thread = api.replace_namespaced_ingress(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) + :param str name: name of the Ingress (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param V1Ingress body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -3432,26 +5909,30 @@ def read_namespaced_network_policy(self, name, namespace, **kwargs): # noqa: E5 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1NetworkPolicy + :return: V1Ingress If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_network_policy_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.replace_namespaced_ingress_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_network_policy # noqa: E501 + def replace_namespaced_ingress_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_ingress # noqa: E501 - read the specified NetworkPolicy # noqa: E501 + replace the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_network_policy_with_http_info(name, namespace, async_req=True) + >>> thread = api.replace_namespaced_ingress_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) + :param str name: name of the Ingress (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param V1Ingress body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -3461,7 +5942,7 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1NetworkPolicy, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3471,7 +5952,11 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg all_params = [ 'name', 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' ] all_params.extend( [ @@ -3486,18 +5971,22 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_network_policy" % key + " to method replace_namespaced_ingress" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_network_policy`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_ingress`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_network_policy`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_ingress`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_ingress`") # noqa: E501 collection_formats = {} @@ -3510,6 +5999,12 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -3517,6 +6012,8 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 @@ -3525,14 +6022,14 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'GET', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1NetworkPolicy', # noqa: E501 + response_type='V1Ingress', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3540,18 +6037,19 @@ def read_namespaced_network_policy_with_http_info(self, name, namespace, **kwarg _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_ingress_class(self, name, body, **kwargs): # noqa: E501 - """replace_ingress_class # noqa: E501 + def replace_namespaced_ingress_status(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_ingress_status # noqa: E501 - replace the specified IngressClass # noqa: E501 + replace status of the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_ingress_class(name, body, async_req=True) + >>> thread = api.replace_namespaced_ingress_status(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) - :param V1IngressClass body: (required) + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param V1Ingress body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -3563,25 +6061,26 @@ def replace_ingress_class(self, name, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1IngressClass + :return: V1Ingress If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_ingress_class_with_http_info(name, body, **kwargs) # noqa: E501 + return self.replace_namespaced_ingress_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_ingress_class # noqa: E501 + def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_ingress_status # noqa: E501 - replace the specified IngressClass # noqa: E501 + replace status of the specified Ingress # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_ingress_class_with_http_info(name, body, async_req=True) + >>> thread = api.replace_namespaced_ingress_status_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the IngressClass (required) - :param V1IngressClass body: (required) + :param str name: name of the Ingress (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param V1Ingress body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -3595,7 +6094,7 @@ def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1IngressClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3604,6 +6103,7 @@ def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E all_params = [ 'name', + 'namespace', 'body', 'pretty', 'dry_run', @@ -3623,24 +6123,30 @@ def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_ingress_class" % key + " to method replace_namespaced_ingress_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_ingress_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_ingress_status`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_ingress_status`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_ingress_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_ingress_status`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -3668,14 +6174,14 @@ def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/ingressclasses/{name}', 'PUT', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}/status', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1IngressClass', # noqa: E501 + response_type='V1Ingress', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3683,19 +6189,19 @@ def replace_ingress_class_with_http_info(self, name, body, **kwargs): # noqa: E _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_ingress(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_ingress # noqa: E501 + def replace_namespaced_network_policy(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_network_policy # noqa: E501 - replace the specified Ingress # noqa: E501 + replace the specified NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_ingress(name, namespace, body, async_req=True) + >>> thread = api.replace_namespaced_network_policy(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) + :param str name: name of the NetworkPolicy (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1Ingress body: (required) + :param V1NetworkPolicy body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -3707,26 +6213,26 @@ def replace_namespaced_ingress(self, name, namespace, body, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Ingress + :return: V1NetworkPolicy If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_ingress_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.replace_namespaced_network_policy_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def replace_namespaced_ingress_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_ingress # noqa: E501 + def replace_namespaced_network_policy_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_network_policy # noqa: E501 - replace the specified Ingress # noqa: E501 + replace the specified NetworkPolicy # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_ingress_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.replace_namespaced_network_policy_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) + :param str name: name of the NetworkPolicy (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1Ingress body: (required) + :param V1NetworkPolicy body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -3740,7 +6246,7 @@ def replace_namespaced_ingress_with_http_info(self, name, namespace, body, **kwa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1NetworkPolicy, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3769,22 +6275,22 @@ def replace_namespaced_ingress_with_http_info(self, name, namespace, body, **kwa if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_ingress" % key + " to method replace_namespaced_network_policy" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_network_policy`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_network_policy`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_ingress`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_network_policy`") # noqa: E501 collection_formats = {} @@ -3820,14 +6326,14 @@ def replace_namespaced_ingress_with_http_info(self, name, namespace, body, **kwa auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}', 'PUT', + '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Ingress', # noqa: E501 + response_type='V1NetworkPolicy', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3835,19 +6341,18 @@ def replace_namespaced_ingress_with_http_info(self, name, namespace, body, **kwa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_ingress_status(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_ingress_status # noqa: E501 + def replace_service_cidr(self, name, body, **kwargs): # noqa: E501 + """replace_service_cidr # noqa: E501 - replace status of the specified Ingress # noqa: E501 + replace the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_ingress_status(name, namespace, body, async_req=True) + >>> thread = api.replace_service_cidr(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1Ingress body: (required) + :param str name: name of the ServiceCIDR (required) + :param V1ServiceCIDR body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -3859,26 +6364,25 @@ def replace_namespaced_ingress_status(self, name, namespace, body, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Ingress + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_ingress_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.replace_service_cidr_with_http_info(name, body, **kwargs) # noqa: E501 - def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_ingress_status # noqa: E501 + def replace_service_cidr_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_service_cidr # noqa: E501 - replace status of the specified Ingress # noqa: E501 + replace the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_ingress_status_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.replace_service_cidr_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the Ingress (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1Ingress body: (required) + :param str name: name of the ServiceCIDR (required) + :param V1ServiceCIDR body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -3892,7 +6396,7 @@ def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Ingress, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3901,7 +6405,6 @@ def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body all_params = [ 'name', - 'namespace', 'body', 'pretty', 'dry_run', @@ -3921,30 +6424,24 @@ def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_ingress_status" % key + " to method replace_service_cidr" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_ingress_status`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_ingress_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_service_cidr`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_ingress_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_service_cidr`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -3972,14 +6469,14 @@ def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/ingresses/{name}/status', 'PUT', + '/apis/networking.k8s.io/v1/servicecidrs/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Ingress', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3987,19 +6484,18 @@ def replace_namespaced_ingress_status_with_http_info(self, name, namespace, body _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_network_policy(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_network_policy # noqa: E501 + def replace_service_cidr_status(self, name, body, **kwargs): # noqa: E501 + """replace_service_cidr_status # noqa: E501 - replace the specified NetworkPolicy # noqa: E501 + replace status of the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_network_policy(name, namespace, body, async_req=True) + >>> thread = api.replace_service_cidr_status(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1NetworkPolicy body: (required) + :param str name: name of the ServiceCIDR (required) + :param V1ServiceCIDR body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -4011,26 +6507,25 @@ def replace_namespaced_network_policy(self, name, namespace, body, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1NetworkPolicy + :return: V1ServiceCIDR If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_network_policy_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.replace_service_cidr_status_with_http_info(name, body, **kwargs) # noqa: E501 - def replace_namespaced_network_policy_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_network_policy # noqa: E501 + def replace_service_cidr_status_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_service_cidr_status # noqa: E501 - replace the specified NetworkPolicy # noqa: E501 + replace status of the specified ServiceCIDR # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_network_policy_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.replace_service_cidr_status_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the NetworkPolicy (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1NetworkPolicy body: (required) + :param str name: name of the ServiceCIDR (required) + :param V1ServiceCIDR body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -4044,7 +6539,7 @@ def replace_namespaced_network_policy_with_http_info(self, name, namespace, body number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1NetworkPolicy, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -4053,7 +6548,6 @@ def replace_namespaced_network_policy_with_http_info(self, name, namespace, body all_params = [ 'name', - 'namespace', 'body', 'pretty', 'dry_run', @@ -4073,30 +6567,24 @@ def replace_namespaced_network_policy_with_http_info(self, name, namespace, body if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_network_policy" % key + " to method replace_service_cidr_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_network_policy`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_network_policy`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_service_cidr_status`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_network_policy`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_service_cidr_status`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -4124,14 +6612,14 @@ def replace_namespaced_network_policy_with_http_info(self, name, namespace, body auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/networking.k8s.io/v1/namespaces/{namespace}/networkpolicies/{name}', 'PUT', + '/apis/networking.k8s.io/v1/servicecidrs/{name}/status', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1NetworkPolicy', # noqa: E501 + response_type='V1ServiceCIDR', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/api/networking_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/networking_v1alpha1_api.py deleted file mode 100644 index be2ffd784045..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/api/networking_v1alpha1_api.py +++ /dev/null @@ -1,2610 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -from __future__ import absolute_import - -import re # noqa: F401 - -# python 2 and python 3 compatibility library -import six - -from kubernetes.client.api_client import ApiClient -from kubernetes.client.exceptions import ( # noqa: F401 - ApiTypeError, - ApiValueError -) - - -class NetworkingV1alpha1Api(object): - """NOTE: This class is auto generated by OpenAPI Generator - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - def __init__(self, api_client=None): - if api_client is None: - api_client = ApiClient() - self.api_client = api_client - - def create_ip_address(self, body, **kwargs): # noqa: E501 - """create_ip_address # noqa: E501 - - create an IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_ip_address(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1alpha1IPAddress body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1IPAddress - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.create_ip_address_with_http_info(body, **kwargs) # noqa: E501 - - def create_ip_address_with_http_info(self, body, **kwargs): # noqa: E501 - """create_ip_address # noqa: E501 - - create an IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_ip_address_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1alpha1IPAddress body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1IPAddress, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method create_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_ip_address`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1IPAddress', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def create_service_cidr(self, body, **kwargs): # noqa: E501 - """create_service_cidr # noqa: E501 - - create a ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_service_cidr(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1alpha1ServiceCIDR body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.create_service_cidr_with_http_info(body, **kwargs) # noqa: E501 - - def create_service_cidr_with_http_info(self, body, **kwargs): # noqa: E501 - """create_service_cidr # noqa: E501 - - create a ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_service_cidr_with_http_info(body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param V1alpha1ServiceCIDR body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method create_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_service_cidr`") # noqa: E501 - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs', 'POST', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_collection_ip_address(self, **kwargs): # noqa: E501 - """delete_collection_ip_address # noqa: E501 - - delete collection of IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_ip_address(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_collection_ip_address_with_http_info(**kwargs) # noqa: E501 - - def delete_collection_ip_address_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_ip_address # noqa: E501 - - delete collection of IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_ip_address_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - '_continue', - 'dry_run', - 'field_selector', - 'grace_period_seconds', - 'label_selector', - 'limit', - 'orphan_dependents', - 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_collection_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_collection_service_cidr(self, **kwargs): # noqa: E501 - """delete_collection_service_cidr # noqa: E501 - - delete collection of ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_service_cidr(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_collection_service_cidr_with_http_info(**kwargs) # noqa: E501 - - def delete_collection_service_cidr_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_service_cidr # noqa: E501 - - delete collection of ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_service_cidr_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - '_continue', - 'dry_run', - 'field_selector', - 'grace_period_seconds', - 'label_selector', - 'limit', - 'orphan_dependents', - 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_collection_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_ip_address(self, name, **kwargs): # noqa: E501 - """delete_ip_address # noqa: E501 - - delete an IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_ip_address(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_ip_address_with_http_info(name, **kwargs) # noqa: E501 - - def delete_ip_address_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_ip_address # noqa: E501 - - delete an IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_ip_address_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_ip_address`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_service_cidr(self, name, **kwargs): # noqa: E501 - """delete_service_cidr # noqa: E501 - - delete a ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_service_cidr(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1Status - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_service_cidr_with_http_info(name, **kwargs) # noqa: E501 - - def delete_service_cidr_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_service_cidr # noqa: E501 - - delete a ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_service_cidr_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_service_cidr`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1Status', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1APIResourceList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 - - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_ip_address(self, **kwargs): # noqa: E501 - """list_ip_address # noqa: E501 - - list or watch objects of kind IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_ip_address(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1IPAddressList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_ip_address_with_http_info(**kwargs) # noqa: E501 - - def list_ip_address_with_http_info(self, **kwargs): # noqa: E501 - """list_ip_address # noqa: E501 - - list or watch objects of kind IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_ip_address_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1IPAddressList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1IPAddressList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_service_cidr(self, **kwargs): # noqa: E501 - """list_service_cidr # noqa: E501 - - list or watch objects of kind ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_service_cidr(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDRList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_service_cidr_with_http_info(**kwargs) # noqa: E501 - - def list_service_cidr_with_http_info(self, **kwargs): # noqa: E501 - """list_service_cidr # noqa: E501 - - list or watch objects of kind ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_service_cidr_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDRList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDRList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_ip_address(self, name, body, **kwargs): # noqa: E501 - """patch_ip_address # noqa: E501 - - partially update the specified IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_ip_address(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1IPAddress - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_ip_address_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_ip_address_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_ip_address # noqa: E501 - - partially update the specified IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_ip_address_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1IPAddress, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_ip_address`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_ip_address`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1IPAddress', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_service_cidr(self, name, body, **kwargs): # noqa: E501 - """patch_service_cidr # noqa: E501 - - partially update the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_service_cidr(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_service_cidr_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_service_cidr_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_service_cidr # noqa: E501 - - partially update the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_service_cidr_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_service_cidr`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_service_cidr`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_service_cidr_status(self, name, body, **kwargs): # noqa: E501 - """patch_service_cidr_status # noqa: E501 - - partially update status of the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_service_cidr_status(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_service_cidr_status_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_service_cidr_status_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_service_cidr_status # noqa: E501 - - partially update status of the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_service_cidr_status_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_service_cidr_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_service_cidr_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_service_cidr_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}/status', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_ip_address(self, name, **kwargs): # noqa: E501 - """read_ip_address # noqa: E501 - - read the specified IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_ip_address(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1IPAddress - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_ip_address_with_http_info(name, **kwargs) # noqa: E501 - - def read_ip_address_with_http_info(self, name, **kwargs): # noqa: E501 - """read_ip_address # noqa: E501 - - read the specified IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_ip_address_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1IPAddress, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_ip_address`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses/{name}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1IPAddress', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_service_cidr(self, name, **kwargs): # noqa: E501 - """read_service_cidr # noqa: E501 - - read the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_service_cidr(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_service_cidr_with_http_info(name, **kwargs) # noqa: E501 - - def read_service_cidr_with_http_info(self, name, **kwargs): # noqa: E501 - """read_service_cidr # noqa: E501 - - read the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_service_cidr_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_service_cidr`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_service_cidr_status(self, name, **kwargs): # noqa: E501 - """read_service_cidr_status # noqa: E501 - - read status of the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_service_cidr_status(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.read_service_cidr_status_with_http_info(name, **kwargs) # noqa: E501 - - def read_service_cidr_status_with_http_info(self, name, **kwargs): # noqa: E501 - """read_service_cidr_status # noqa: E501 - - read status of the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_service_cidr_status_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method read_service_cidr_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_service_cidr_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}/status', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_ip_address(self, name, body, **kwargs): # noqa: E501 - """replace_ip_address # noqa: E501 - - replace the specified IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_ip_address(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param V1alpha1IPAddress body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1IPAddress - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_ip_address_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_ip_address_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_ip_address # noqa: E501 - - replace the specified IPAddress # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_ip_address_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the IPAddress (required) - :param V1alpha1IPAddress body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1IPAddress, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_ip_address" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_ip_address`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_ip_address`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/ipaddresses/{name}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1IPAddress', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_service_cidr(self, name, body, **kwargs): # noqa: E501 - """replace_service_cidr # noqa: E501 - - replace the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_service_cidr(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param V1alpha1ServiceCIDR body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_service_cidr_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_service_cidr_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_service_cidr # noqa: E501 - - replace the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_service_cidr_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param V1alpha1ServiceCIDR body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_service_cidr" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_service_cidr`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_service_cidr`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def replace_service_cidr_status(self, name, body, **kwargs): # noqa: E501 - """replace_service_cidr_status # noqa: E501 - - replace status of the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_service_cidr_status(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param V1alpha1ServiceCIDR body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha1ServiceCIDR - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.replace_service_cidr_status_with_http_info(name, body, **kwargs) # noqa: E501 - - def replace_service_cidr_status_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_service_cidr_status # noqa: E501 - - replace status of the specified ServiceCIDR # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_service_cidr_status_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ServiceCIDR (required) - :param V1alpha1ServiceCIDR body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha1ServiceCIDR, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method replace_service_cidr_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_service_cidr_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_service_cidr_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/networking.k8s.io/v1alpha1/servicecidrs/{name}/status', 'PUT', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha1ServiceCIDR', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) diff --git a/contrib/python/kubernetes/kubernetes/client/api/networking_v1beta1_api.py b/contrib/python/kubernetes/kubernetes/client/api/networking_v1beta1_api.py index 65903bc2282f..a5642a061891 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/networking_v1beta1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/networking_v1beta1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/node_api.py b/contrib/python/kubernetes/kubernetes/client/api/node_api.py index 1452463a10e3..0fa1d9a9c992 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/node_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/node_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/node_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/node_v1_api.py index ef657f3957f8..0fae52364524 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/node_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/node_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/openid_api.py b/contrib/python/kubernetes/kubernetes/client/api/openid_api.py index b060645eb0cd..05400c78cba6 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/openid_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/openid_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/policy_api.py b/contrib/python/kubernetes/kubernetes/client/api/policy_api.py index b1e6ebf04c64..c69f7ae0dde8 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/policy_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/policy_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/policy_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/policy_v1_api.py index 9f4a17b17a8d..f4d0ee70f29c 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/policy_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/policy_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_api.py b/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_api.py index ff702b96e958..7ad6bb9ee523 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_v1_api.py index d7cb26c75804..10fc3a844e21 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/rbac_authorization_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/resource_api.py b/contrib/python/kubernetes/kubernetes/client/api/resource_api.py index a7a61f264d87..6e2668e567a5 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/resource_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/resource_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha3_api.py b/contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha3_api.py index 2c2d8fb113ca..fc488dd297d4 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha3_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha3_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -170,6 +170,140 @@ def create_device_class_with_http_info(self, body, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) + def create_device_taint_rule(self, body, **kwargs): # noqa: E501 + """create_device_taint_rule # noqa: E501 + + create a DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.create_device_taint_rule(body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param V1alpha3DeviceTaintRule body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1alpha3DeviceTaintRule + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.create_device_taint_rule_with_http_info(body, **kwargs) # noqa: E501 + + def create_device_taint_rule_with_http_info(self, body, **kwargs): # noqa: E501 + """create_device_taint_rule # noqa: E501 + + create a DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.create_device_taint_rule_with_http_info(body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param V1alpha3DeviceTaintRule body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1alpha3DeviceTaintRule, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method create_device_taint_rule" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_device_taint_rule`") # noqa: E501 + + collection_formats = {} + + path_params = {} + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/devicetaintrules', 'POST', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1alpha3DeviceTaintRule', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + def create_namespaced_resource_claim(self, namespace, body, **kwargs): # noqa: E501 """create_namespaced_resource_claim # noqa: E501 @@ -770,17 +904,16 @@ def delete_collection_device_class_with_http_info(self, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_resource_claim(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim # noqa: E501 + def delete_collection_device_taint_rule(self, **kwargs): # noqa: E501 + """delete_collection_device_taint_rule # noqa: E501 - delete collection of ResourceClaim # noqa: E501 + delete collection of DeviceTaintRule # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim(namespace, async_req=True) + >>> thread = api.delete_collection_device_taint_rule(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -808,19 +941,18 @@ def delete_collection_namespaced_resource_claim(self, namespace, **kwargs): # n returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_resource_claim_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_collection_device_taint_rule_with_http_info(**kwargs) # noqa: E501 - def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim # noqa: E501 + def delete_collection_device_taint_rule_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_device_taint_rule # noqa: E501 - delete collection of ResourceClaim # noqa: E501 + delete collection of DeviceTaintRule # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_with_http_info(namespace, async_req=True) + >>> thread = api.delete_collection_device_taint_rule_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -853,7 +985,6 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, local_var_params = locals() all_params = [ - 'namespace', 'pretty', '_continue', 'dry_run', @@ -883,20 +1014,14 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_resource_claim" % key + " to method delete_collection_device_taint_rule" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -944,7 +1069,7 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/resourceclaims', 'DELETE', + '/apis/resource.k8s.io/v1alpha3/devicetaintrules', 'DELETE', path_params, query_params, header_params, @@ -959,13 +1084,13 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_resource_claim_template(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim_template # noqa: E501 + def delete_collection_namespaced_resource_claim(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim # noqa: E501 - delete collection of ResourceClaimTemplate # noqa: E501 + delete collection of ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_template(namespace, async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously @@ -997,15 +1122,15 @@ def delete_collection_namespaced_resource_claim_template(self, namespace, **kwar returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_collection_namespaced_resource_claim_with_http_info(namespace, **kwargs) # noqa: E501 - def delete_collection_namespaced_resource_claim_template_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim_template # noqa: E501 + def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim # noqa: E501 - delete collection of ResourceClaimTemplate # noqa: E501 + delete collection of ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously @@ -1072,14 +1197,14 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_resource_claim_template" % key + " to method delete_collection_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim`") # noqa: E501 collection_formats = {} @@ -1133,7 +1258,7 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/resourceclaimtemplates', 'DELETE', + '/apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/resourceclaims', 'DELETE', path_params, query_params, header_params, @@ -1148,16 +1273,17 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_resource_slice(self, **kwargs): # noqa: E501 - """delete_collection_resource_slice # noqa: E501 + def delete_collection_namespaced_resource_claim_template(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim_template # noqa: E501 - delete collection of ResourceSlice # noqa: E501 + delete collection of ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_resource_slice(async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim_template(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -1185,18 +1311,19 @@ def delete_collection_resource_slice(self, **kwargs): # noqa: E501 returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_resource_slice_with_http_info(**kwargs) # noqa: E501 + return self.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, **kwargs) # noqa: E501 - def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_resource_slice # noqa: E501 + def delete_collection_namespaced_resource_claim_template_with_http_info(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim_template # noqa: E501 - delete collection of ResourceSlice # noqa: E501 + delete collection of ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_resource_slice_with_http_info(async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -1229,6 +1356,7 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 local_var_params = locals() all_params = [ + 'namespace', 'pretty', '_continue', 'dry_run', @@ -1258,14 +1386,20 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_resource_slice" % key + " to method delete_collection_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} path_params = {} + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -1313,7 +1447,7 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/resourceslices', 'DELETE', + '/apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/resourceclaimtemplates', 'DELETE', path_params, query_params, header_params, @@ -1328,23 +1462,30 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_device_class(self, name, **kwargs): # noqa: E501 - """delete_device_class # noqa: E501 + def delete_collection_resource_slice(self, **kwargs): # noqa: E501 + """delete_collection_resource_slice # noqa: E501 - delete a DeviceClass # noqa: E501 + delete collection of ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_device_class(name, async_req=True) + >>> thread = api.delete_collection_resource_slice(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the DeviceClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1353,30 +1494,37 @@ def delete_device_class(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha3DeviceClass + :return: V1Status If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_device_class_with_http_info(name, **kwargs) # noqa: E501 + return self.delete_collection_resource_slice_with_http_info(**kwargs) # noqa: E501 - def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_device_class # noqa: E501 + def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_resource_slice # noqa: E501 - delete a DeviceClass # noqa: E501 + delete collection of ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_device_class_with_http_info(name, async_req=True) + >>> thread = api.delete_collection_resource_slice_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the DeviceClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1387,7 +1535,7 @@ def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha3DeviceClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1395,13 +1543,20 @@ def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ - 'name', 'pretty', + '_continue', 'dry_run', + 'field_selector', 'grace_period_seconds', 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', 'orphan_dependents', 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', 'body' ] all_params.extend( @@ -1417,33 +1572,192 @@ def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_device_class" % key + " to method delete_collection_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_device_class`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/resourceslices', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1Status', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def delete_device_class(self, name, **kwargs): # noqa: E501 + """delete_device_class # noqa: E501 + + delete a DeviceClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_device_class(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceClass (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1alpha3DeviceClass + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_device_class_with_http_info(name, **kwargs) # noqa: E501 + + def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_device_class # noqa: E501 + + delete a DeviceClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_device_class_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceClass (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1alpha3DeviceClass, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_device_class" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_device_class`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 header_params = {} @@ -1477,6 +1791,155 @@ def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) + def delete_device_taint_rule(self, name, **kwargs): # noqa: E501 + """delete_device_taint_rule # noqa: E501 + + delete a DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_device_taint_rule(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceTaintRule (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1alpha3DeviceTaintRule + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.delete_device_taint_rule_with_http_info(name, **kwargs) # noqa: E501 + + def delete_device_taint_rule_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_device_taint_rule # noqa: E501 + + delete a DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.delete_device_taint_rule_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceTaintRule (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param V1DeleteOptions body: + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1alpha3DeviceTaintRule, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty', + 'dry_run', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'orphan_dependents', + 'propagation_policy', + 'body' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method delete_device_taint_rule" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_device_taint_rule`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/devicetaintrules/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1alpha3DeviceTaintRule', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + def delete_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E501 """delete_namespaced_resource_claim # noqa: E501 @@ -1917,8 +2380,113 @@ def delete_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/resourceslices/{name}', 'DELETE', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1alpha3ResourceSlice', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def get_api_resources(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 + + get available resources # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_api_resources(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1APIResourceList + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 + + def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 + + get available resources # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.get_api_resources_with_http_info(async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method get_api_resources" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + + collection_formats = {} + + path_params = {} + + query_params = [] + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 @@ -1927,14 +2495,14 @@ def delete_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/resourceslices/{name}', 'DELETE', + '/apis/resource.k8s.io/v1alpha3/', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha3ResourceSlice', # noqa: E501 + response_type='V1APIResourceList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1942,16 +2510,27 @@ def delete_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 + def list_device_class(self, **kwargs): # noqa: E501 + """list_device_class # noqa: E501 - get available resources # noqa: E501 + list or watch objects of kind DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) + >>> thread = api.list_device_class(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -1959,23 +2538,34 @@ def get_api_resources(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1APIResourceList + :return: V1alpha3DeviceClassList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 + return self.list_device_class_with_http_info(**kwargs) # noqa: E501 - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 + def list_device_class_with_http_info(self, **kwargs): # noqa: E501 + """list_device_class # noqa: E501 - get available resources # noqa: E501 + list or watch objects of kind DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) + >>> thread = api.list_device_class_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -1985,7 +2575,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1alpha3DeviceClassList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1993,6 +2583,17 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' ] all_params.extend( [ @@ -2007,7 +2608,7 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key + " to method list_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] @@ -2017,6 +2618,28 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 path_params = {} query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -2026,20 +2649,20 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/', 'GET', + '/apis/resource.k8s.io/v1alpha3/deviceclasses', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 + response_type='V1alpha3DeviceClassList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2047,13 +2670,13 @@ def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def list_device_class(self, **kwargs): # noqa: E501 - """list_device_class # noqa: E501 + def list_device_taint_rule(self, **kwargs): # noqa: E501 + """list_device_taint_rule # noqa: E501 - list or watch objects of kind DeviceClass # noqa: E501 + list or watch objects of kind DeviceTaintRule # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_device_class(async_req=True) + >>> thread = api.list_device_taint_rule(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously @@ -2075,20 +2698,20 @@ def list_device_class(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha3DeviceClassList + :return: V1alpha3DeviceTaintRuleList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.list_device_class_with_http_info(**kwargs) # noqa: E501 + return self.list_device_taint_rule_with_http_info(**kwargs) # noqa: E501 - def list_device_class_with_http_info(self, **kwargs): # noqa: E501 - """list_device_class # noqa: E501 + def list_device_taint_rule_with_http_info(self, **kwargs): # noqa: E501 + """list_device_taint_rule # noqa: E501 - list or watch objects of kind DeviceClass # noqa: E501 + list or watch objects of kind DeviceTaintRule # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_device_class_with_http_info(async_req=True) + >>> thread = api.list_device_taint_rule_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously @@ -2112,7 +2735,7 @@ def list_device_class_with_http_info(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha3DeviceClassList, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1alpha3DeviceTaintRuleList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2145,7 +2768,7 @@ def list_device_class_with_http_info(self, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method list_device_class" % key + " to method list_device_taint_rule" % key ) local_var_params[key] = val del local_var_params['kwargs'] @@ -2192,14 +2815,14 @@ def list_device_class_with_http_info(self, **kwargs): # noqa: E501 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/deviceclasses', 'GET', + '/apis/resource.k8s.io/v1alpha3/devicetaintrules', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha3DeviceClassList', # noqa: E501 + response_type='V1alpha3DeviceTaintRuleList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3004,20 +3627,172 @@ def list_resource_slice_with_http_info(self, **kwargs): # noqa: E501 body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/resourceslices', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1alpha3ResourceSliceList', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + + def patch_device_class(self, name, body, **kwargs): # noqa: E501 + """patch_device_class # noqa: E501 + + partially update the specified DeviceClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_device_class(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceClass (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1alpha3DeviceClass + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.patch_device_class_with_http_info(name, body, **kwargs) # noqa: E501 + + def patch_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_device_class # noqa: E501 + + partially update the specified DeviceClass # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.patch_device_class_with_http_info(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceClass (required) + :param object body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1alpha3DeviceClass, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method patch_device_class" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_device_class`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_device_class`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/resourceslices', 'GET', + '/apis/resource.k8s.io/v1alpha3/deviceclasses/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha3ResourceSliceList', # noqa: E501 + response_type='V1alpha3DeviceClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3025,17 +3800,17 @@ def list_resource_slice_with_http_info(self, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def patch_device_class(self, name, body, **kwargs): # noqa: E501 - """patch_device_class # noqa: E501 + def patch_device_taint_rule(self, name, body, **kwargs): # noqa: E501 + """patch_device_taint_rule # noqa: E501 - partially update the specified DeviceClass # noqa: E501 + partially update the specified DeviceTaintRule # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_device_class(name, body, async_req=True) + >>> thread = api.patch_device_taint_rule(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the DeviceClass (required) + :param str name: name of the DeviceTaintRule (required) :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -3049,24 +3824,24 @@ def patch_device_class(self, name, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha3DeviceClass + :return: V1alpha3DeviceTaintRule If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.patch_device_class_with_http_info(name, body, **kwargs) # noqa: E501 + return self.patch_device_taint_rule_with_http_info(name, body, **kwargs) # noqa: E501 - def patch_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_device_class # noqa: E501 + def patch_device_taint_rule_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_device_taint_rule # noqa: E501 - partially update the specified DeviceClass # noqa: E501 + partially update the specified DeviceTaintRule # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_device_class_with_http_info(name, body, async_req=True) + >>> thread = api.patch_device_taint_rule_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the DeviceClass (required) + :param str name: name of the DeviceTaintRule (required) :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed @@ -3082,7 +3857,7 @@ def patch_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha3DeviceClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1alpha3DeviceTaintRule, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -3111,18 +3886,18 @@ def patch_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method patch_device_class" % key + " to method patch_device_taint_rule" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_device_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_device_taint_rule`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_device_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_device_taint_rule`") # noqa: E501 collection_formats = {} @@ -3162,14 +3937,14 @@ def patch_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha3/deviceclasses/{name}', 'PATCH', + '/apis/resource.k8s.io/v1alpha3/devicetaintrules/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha3DeviceClass', # noqa: E501 + response_type='V1alpha3DeviceTaintRule', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -3931,6 +4706,125 @@ def read_device_class_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) + def read_device_taint_rule(self, name, **kwargs): # noqa: E501 + """read_device_taint_rule # noqa: E501 + + read the specified DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.read_device_taint_rule(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceTaintRule (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1alpha3DeviceTaintRule + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.read_device_taint_rule_with_http_info(name, **kwargs) # noqa: E501 + + def read_device_taint_rule_with_http_info(self, name, **kwargs): # noqa: E501 + """read_device_taint_rule # noqa: E501 + + read the specified DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.read_device_taint_rule_with_http_info(name, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceTaintRule (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1alpha3DeviceTaintRule, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'pretty' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method read_device_taint_rule" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_device_taint_rule`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/devicetaintrules/{name}', 'GET', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1alpha3DeviceTaintRule', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + def read_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E501 """read_namespaced_resource_claim # noqa: E501 @@ -4577,6 +5471,149 @@ def replace_device_class_with_http_info(self, name, body, **kwargs): # noqa: E5 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) + def replace_device_taint_rule(self, name, body, **kwargs): # noqa: E501 + """replace_device_taint_rule # noqa: E501 + + replace the specified DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.replace_device_taint_rule(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceTaintRule (required) + :param V1alpha3DeviceTaintRule body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: V1alpha3DeviceTaintRule + If the method is called asynchronously, + returns the request thread. + """ + kwargs['_return_http_data_only'] = True + return self.replace_device_taint_rule_with_http_info(name, body, **kwargs) # noqa: E501 + + def replace_device_taint_rule_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_device_taint_rule # noqa: E501 + + replace the specified DeviceTaintRule # noqa: E501 + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + >>> thread = api.replace_device_taint_rule_with_http_info(name, body, async_req=True) + >>> result = thread.get() + + :param async_req bool: execute request asynchronously + :param str name: name of the DeviceTaintRule (required) + :param V1alpha3DeviceTaintRule body: (required) + :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param _return_http_data_only: response data without head status code + and headers + :param _preload_content: if False, the urllib3.HTTPResponse object will + be returned without reading/decoding response + data. Default is True. + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :return: tuple(V1alpha3DeviceTaintRule, status_code(int), headers(HTTPHeaderDict)) + If the method is called asynchronously, + returns the request thread. + """ + + local_var_params = locals() + + all_params = [ + 'name', + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation' + ] + all_params.extend( + [ + 'async_req', + '_return_http_data_only', + '_preload_content', + '_request_timeout' + ] + ) + + for key, val in six.iteritems(local_var_params['kwargs']): + if key not in all_params: + raise ApiTypeError( + "Got an unexpected keyword argument '%s'" + " to method replace_device_taint_rule" % key + ) + local_var_params[key] = val + del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_device_taint_rule`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_device_taint_rule`") # noqa: E501 + + collection_formats = {} + + path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 + + query_params = [] + if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 + query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + + header_params = {} + + form_params = [] + local_var_files = {} + + body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] + # HTTP header `Accept` + header_params['Accept'] = self.api_client.select_header_accept( + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # Authentication setting + auth_settings = ['BearerToken'] # noqa: E501 + + return self.api_client.call_api( + '/apis/resource.k8s.io/v1alpha3/devicetaintrules/{name}', 'PUT', + path_params, + query_params, + header_params, + body=body_params, + post_params=form_params, + files=local_var_files, + response_type='V1alpha3DeviceTaintRule', # noqa: E501 + auth_settings=auth_settings, + async_req=local_var_params.get('async_req'), + _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 + _preload_content=local_var_params.get('_preload_content', True), + _request_timeout=local_var_params.get('_request_timeout'), + collection_formats=collection_formats) + def replace_namespaced_resource_claim(self, name, namespace, body, **kwargs): # noqa: E501 """replace_namespaced_resource_claim # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/api/resource_v1beta1_api.py b/contrib/python/kubernetes/kubernetes/client/api/resource_v1beta1_api.py index a6c4afb09540..7fdc99aac981 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/resource_v1beta1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/resource_v1beta1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha2_api.py b/contrib/python/kubernetes/kubernetes/client/api/resource_v1beta2_api.py similarity index 51% rename from contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha2_api.py rename to contrib/python/kubernetes/kubernetes/client/api/resource_v1beta2_api.py index 2bdb37036319..e4dc3a3188b4 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/resource_v1alpha2_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/resource_v1beta2_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -24,7 +24,7 @@ ) -class ResourceV1alpha2Api(object): +class ResourceV1beta2Api(object): """NOTE: This class is auto generated by OpenAPI Generator Ref: https://openapi-generator.tech @@ -36,18 +36,17 @@ def __init__(self, api_client=None): api_client = ApiClient() self.api_client = api_client - def create_namespaced_pod_scheduling_context(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_pod_scheduling_context # noqa: E501 + def create_device_class(self, body, **kwargs): # noqa: E501 + """create_device_class # noqa: E501 - create a PodSchedulingContext # noqa: E501 + create a DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_pod_scheduling_context(namespace, body, async_req=True) + >>> thread = api.create_device_class(body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2PodSchedulingContext body: (required) + :param V1beta2DeviceClass body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -59,25 +58,24 @@ def create_namespaced_pod_scheduling_context(self, namespace, body, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext + :return: V1beta2DeviceClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.create_namespaced_pod_scheduling_context_with_http_info(namespace, body, **kwargs) # noqa: E501 + return self.create_device_class_with_http_info(body, **kwargs) # noqa: E501 - def create_namespaced_pod_scheduling_context_with_http_info(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_pod_scheduling_context # noqa: E501 + def create_device_class_with_http_info(self, body, **kwargs): # noqa: E501 + """create_device_class # noqa: E501 - create a PodSchedulingContext # noqa: E501 + create a DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_pod_scheduling_context_with_http_info(namespace, body, async_req=True) + >>> thread = api.create_device_class_with_http_info(body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2PodSchedulingContext body: (required) + :param V1beta2DeviceClass body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -91,7 +89,7 @@ def create_namespaced_pod_scheduling_context_with_http_info(self, namespace, bod number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2DeviceClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -99,7 +97,6 @@ def create_namespaced_pod_scheduling_context_with_http_info(self, namespace, bod local_var_params = locals() all_params = [ - 'namespace', 'body', 'pretty', 'dry_run', @@ -119,24 +116,18 @@ def create_namespaced_pod_scheduling_context_with_http_info(self, namespace, bod if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method create_namespaced_pod_scheduling_context" % key + " to method create_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_pod_scheduling_context`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_pod_scheduling_context`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_device_class`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -158,20 +149,20 @@ def create_namespaced_pod_scheduling_context_with_http_info(self, namespace, bod body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts', 'POST', + '/apis/resource.k8s.io/v1beta2/deviceclasses', 'POST', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 + response_type='V1beta2DeviceClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -190,7 +181,7 @@ def create_namespaced_resource_claim(self, namespace, body, **kwargs): # noqa: :param async_req bool: execute request asynchronously :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaim body: (required) + :param V1beta2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -202,7 +193,7 @@ def create_namespaced_resource_claim(self, namespace, body, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaim + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ @@ -220,7 +211,7 @@ def create_namespaced_resource_claim_with_http_info(self, namespace, body, **kwa :param async_req bool: execute request asynchronously :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaim body: (required) + :param V1beta2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -234,7 +225,7 @@ def create_namespaced_resource_claim_with_http_info(self, namespace, body, **kwa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -301,20 +292,20 @@ def create_namespaced_resource_claim_with_http_info(self, namespace, body, **kwa body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims', 'POST', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims', 'POST', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -322,18 +313,18 @@ def create_namespaced_resource_claim_with_http_info(self, namespace, body, **kwa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def create_namespaced_resource_claim_parameters(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_resource_claim_parameters # noqa: E501 + def create_namespaced_resource_claim_template(self, namespace, body, **kwargs): # noqa: E501 + """create_namespaced_resource_claim_template # noqa: E501 - create ResourceClaimParameters # noqa: E501 + create a ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_resource_claim_parameters(namespace, body, async_req=True) + >>> thread = api.create_namespaced_resource_claim_template(namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimParameters body: (required) + :param V1beta2ResourceClaimTemplate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -345,25 +336,25 @@ def create_namespaced_resource_claim_parameters(self, namespace, body, **kwargs) number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaimParameters + :return: V1beta2ResourceClaimTemplate If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.create_namespaced_resource_claim_parameters_with_http_info(namespace, body, **kwargs) # noqa: E501 + return self.create_namespaced_resource_claim_template_with_http_info(namespace, body, **kwargs) # noqa: E501 - def create_namespaced_resource_claim_parameters_with_http_info(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_resource_claim_parameters # noqa: E501 + def create_namespaced_resource_claim_template_with_http_info(self, namespace, body, **kwargs): # noqa: E501 + """create_namespaced_resource_claim_template # noqa: E501 - create ResourceClaimParameters # noqa: E501 + create a ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_resource_claim_parameters_with_http_info(namespace, body, async_req=True) + >>> thread = api.create_namespaced_resource_claim_template_with_http_info(namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimParameters body: (required) + :param V1beta2ResourceClaimTemplate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -377,7 +368,7 @@ def create_namespaced_resource_claim_parameters_with_http_info(self, namespace, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParameters, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -405,18 +396,18 @@ def create_namespaced_resource_claim_parameters_with_http_info(self, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method create_namespaced_resource_claim_parameters" % key + " to method create_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_resource_claim_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_resource_claim_template`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_resource_claim_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} @@ -444,20 +435,20 @@ def create_namespaced_resource_claim_parameters_with_http_info(self, namespace, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters', 'POST', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates', 'POST', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaimParameters', # noqa: E501 + response_type='V1beta2ResourceClaimTemplate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -465,18 +456,17 @@ def create_namespaced_resource_claim_parameters_with_http_info(self, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def create_namespaced_resource_claim_template(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_resource_claim_template # noqa: E501 + def create_resource_slice(self, body, **kwargs): # noqa: E501 + """create_resource_slice # noqa: E501 - create a ResourceClaimTemplate # noqa: E501 + create a ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_resource_claim_template(namespace, body, async_req=True) + >>> thread = api.create_resource_slice(body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimTemplate body: (required) + :param V1beta2ResourceSlice body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -488,25 +478,24 @@ def create_namespaced_resource_claim_template(self, namespace, body, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplate + :return: V1beta2ResourceSlice If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.create_namespaced_resource_claim_template_with_http_info(namespace, body, **kwargs) # noqa: E501 + return self.create_resource_slice_with_http_info(body, **kwargs) # noqa: E501 - def create_namespaced_resource_claim_template_with_http_info(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_resource_claim_template # noqa: E501 + def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 + """create_resource_slice # noqa: E501 - create a ResourceClaimTemplate # noqa: E501 + create a ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_resource_claim_template_with_http_info(namespace, body, async_req=True) + >>> thread = api.create_resource_slice_with_http_info(body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimTemplate body: (required) + :param V1beta2ResourceSlice body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -520,7 +509,7 @@ def create_namespaced_resource_claim_template_with_http_info(self, namespace, bo number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -528,7 +517,6 @@ def create_namespaced_resource_claim_template_with_http_info(self, namespace, bo local_var_params = locals() all_params = [ - 'namespace', 'body', 'pretty', 'dry_run', @@ -548,24 +536,18 @@ def create_namespaced_resource_claim_template_with_http_info(self, namespace, bo if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method create_namespaced_resource_claim_template" % key + " to method create_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_resource_claim_template`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `create_resource_slice`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -587,20 +569,20 @@ def create_namespaced_resource_claim_template_with_http_info(self, namespace, bo body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates', 'POST', + '/apis/resource.k8s.io/v1beta2/resourceslices', 'POST', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaimTemplate', # noqa: E501 + response_type='V1beta2ResourceSlice', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -608,22 +590,31 @@ def create_namespaced_resource_claim_template_with_http_info(self, namespace, bo _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def create_namespaced_resource_class_parameters(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_resource_class_parameters # noqa: E501 + def delete_collection_device_class(self, **kwargs): # noqa: E501 + """delete_collection_device_class # noqa: E501 - create ResourceClassParameters # noqa: E501 + delete collection of DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_resource_class_parameters(namespace, body, async_req=True) + >>> thread = api.delete_collection_device_class(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClassParameters body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -631,29 +622,38 @@ def create_namespaced_resource_class_parameters(self, namespace, body, **kwargs) number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClassParameters + :return: V1Status If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.create_namespaced_resource_class_parameters_with_http_info(namespace, body, **kwargs) # noqa: E501 + return self.delete_collection_device_class_with_http_info(**kwargs) # noqa: E501 - def create_namespaced_resource_class_parameters_with_http_info(self, namespace, body, **kwargs): # noqa: E501 - """create_namespaced_resource_class_parameters # noqa: E501 + def delete_collection_device_class_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_device_class # noqa: E501 - create ResourceClassParameters # noqa: E501 + delete collection of DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_namespaced_resource_class_parameters_with_http_info(namespace, body, async_req=True) + >>> thread = api.delete_collection_device_class_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClassParameters body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -663,7 +663,7 @@ def create_namespaced_resource_class_parameters_with_http_info(self, namespace, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParameters, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -671,12 +671,21 @@ def create_namespaced_resource_class_parameters_with_http_info(self, namespace, local_var_params = locals() all_params = [ - 'namespace', - 'body', 'pretty', + '_continue', 'dry_run', - 'field_manager', - 'field_validation' + 'field_selector', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', + 'orphan_dependents', + 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'body' ] all_params.extend( [ @@ -691,34 +700,44 @@ def create_namespaced_resource_class_parameters_with_http_info(self, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method create_namespaced_resource_class_parameters" % key + " to method delete_collection_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `create_namespaced_resource_class_parameters`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_namespaced_resource_class_parameters`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -730,20 +749,20 @@ def create_namespaced_resource_class_parameters_with_http_info(self, namespace, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters', 'POST', + '/apis/resource.k8s.io/v1beta2/deviceclasses', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClassParameters', # noqa: E501 + response_type='V1Status', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -751,21 +770,32 @@ def create_namespaced_resource_class_parameters_with_http_info(self, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def create_resource_class(self, body, **kwargs): # noqa: E501 - """create_resource_class # noqa: E501 + def delete_collection_namespaced_resource_claim(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim # noqa: E501 - create a ResourceClass # noqa: E501 + delete collection of ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_resource_class(body, async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param V1alpha2ResourceClass body: (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -773,28 +803,39 @@ def create_resource_class(self, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClass + :return: V1Status If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.create_resource_class_with_http_info(body, **kwargs) # noqa: E501 + return self.delete_collection_namespaced_resource_claim_with_http_info(namespace, **kwargs) # noqa: E501 - def create_resource_class_with_http_info(self, body, **kwargs): # noqa: E501 - """create_resource_class # noqa: E501 + def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim # noqa: E501 - create a ResourceClass # noqa: E501 + delete collection of ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_resource_class_with_http_info(body, async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param V1alpha2ResourceClass body: (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -804,7 +845,7 @@ def create_resource_class_with_http_info(self, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -812,11 +853,22 @@ def create_resource_class_with_http_info(self, body, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ - 'body', + 'namespace', 'pretty', + '_continue', 'dry_run', - 'field_manager', - 'field_validation' + 'field_selector', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', + 'orphan_dependents', + 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'body' ] all_params.extend( [ @@ -831,28 +883,50 @@ def create_resource_class_with_http_info(self, body, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method create_resource_class" % key + " to method delete_collection_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_resource_class`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim`") # noqa: E501 collection_formats = {} path_params = {} + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -864,20 +938,20 @@ def create_resource_class_with_http_info(self, body, **kwargs): # noqa: E501 body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses', 'POST', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClass', # noqa: E501 + response_type='V1Status', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -885,21 +959,32 @@ def create_resource_class_with_http_info(self, body, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def create_resource_slice(self, body, **kwargs): # noqa: E501 - """create_resource_slice # noqa: E501 + def delete_collection_namespaced_resource_claim_template(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim_template # noqa: E501 - create a ResourceSlice # noqa: E501 + delete collection of ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_resource_slice(body, async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim_template(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param V1alpha2ResourceSlice body: (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -907,28 +992,39 @@ def create_resource_slice(self, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceSlice + :return: V1Status If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.create_resource_slice_with_http_info(body, **kwargs) # noqa: E501 + return self.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, **kwargs) # noqa: E501 - def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 - """create_resource_slice # noqa: E501 + def delete_collection_namespaced_resource_claim_template_with_http_info(self, namespace, **kwargs): # noqa: E501 + """delete_collection_namespaced_resource_claim_template # noqa: E501 - create a ResourceSlice # noqa: E501 + delete collection of ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.create_resource_slice_with_http_info(body, async_req=True) + >>> thread = api.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param V1alpha2ResourceSlice body: (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. + :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -938,7 +1034,7 @@ def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -946,11 +1042,22 @@ def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 local_var_params = locals() all_params = [ - 'body', + 'namespace', 'pretty', + '_continue', 'dry_run', - 'field_manager', - 'field_validation' + 'field_selector', + 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', + 'label_selector', + 'limit', + 'orphan_dependents', + 'propagation_policy', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'body' ] all_params.extend( [ @@ -965,28 +1072,50 @@ def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method create_resource_slice" % key + " to method delete_collection_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `create_resource_slice`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} path_params = {} + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 + query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 + query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 + if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 + query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -998,20 +1127,20 @@ def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices', 'POST', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceSlice', # noqa: E501 + response_type='V1Status', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1019,22 +1148,22 @@ def create_resource_slice_with_http_info(self, body, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_pod_scheduling_context(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_pod_scheduling_context # noqa: E501 + def delete_collection_resource_slice(self, **kwargs): # noqa: E501 + """delete_collection_resource_slice # noqa: E501 - delete collection of PodSchedulingContext # noqa: E501 + delete collection of ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_pod_scheduling_context(namespace, async_req=True) + >>> thread = api.delete_collection_resource_slice(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. @@ -1056,24 +1185,24 @@ def delete_collection_namespaced_pod_scheduling_context(self, namespace, **kwarg returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_pod_scheduling_context_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_collection_resource_slice_with_http_info(**kwargs) # noqa: E501 - def delete_collection_namespaced_pod_scheduling_context_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_pod_scheduling_context # noqa: E501 + def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E501 + """delete_collection_resource_slice # noqa: E501 - delete collection of PodSchedulingContext # noqa: E501 + delete collection of ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_pod_scheduling_context_with_http_info(namespace, async_req=True) + >>> thread = api.delete_collection_resource_slice_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. @@ -1100,12 +1229,12 @@ def delete_collection_namespaced_pod_scheduling_context_with_http_info(self, nam local_var_params = locals() all_params = [ - 'namespace', 'pretty', '_continue', 'dry_run', 'field_selector', 'grace_period_seconds', + 'ignore_store_read_error_with_cluster_breaking_potential', 'label_selector', 'limit', 'orphan_dependents', @@ -1129,20 +1258,14 @@ def delete_collection_namespaced_pod_scheduling_context_with_http_info(self, nam if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_pod_scheduling_context" % key + " to method delete_collection_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_pod_scheduling_context`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -1155,6 +1278,8 @@ def delete_collection_namespaced_pod_scheduling_context_with_http_info(self, nam query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 @@ -1182,13 +1307,13 @@ def delete_collection_namespaced_pod_scheduling_context_with_http_info(self, nam body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts', 'DELETE', + '/apis/resource.k8s.io/v1beta2/resourceslices', 'DELETE', path_params, query_params, header_params, @@ -1203,30 +1328,23 @@ def delete_collection_namespaced_pod_scheduling_context_with_http_info(self, nam _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_resource_claim(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim # noqa: E501 + def delete_device_class(self, name, **kwargs): # noqa: E501 + """delete_device_class # noqa: E501 - delete collection of ResourceClaim # noqa: E501 + delete a DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim(namespace, async_req=True) + >>> thread = api.delete_device_class(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the DeviceClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1235,37 +1353,30 @@ def delete_collection_namespaced_resource_claim(self, namespace, **kwargs): # n number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1beta2DeviceClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_resource_claim_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_device_class_with_http_info(name, **kwargs) # noqa: E501 - def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim # noqa: E501 + def delete_device_class_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_device_class # noqa: E501 - delete collection of ResourceClaim # noqa: E501 + delete a DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_with_http_info(namespace, async_req=True) + >>> thread = api.delete_device_class_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the DeviceClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1276,7 +1387,7 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2DeviceClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1284,20 +1395,13 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, local_var_params = locals() all_params = [ - 'namespace', + 'name', 'pretty', - '_continue', 'dry_run', - 'field_selector', 'grace_period_seconds', - 'label_selector', - 'limit', + 'ignore_store_read_error_with_cluster_breaking_potential', 'orphan_dependents', 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', 'body' ] all_params.extend( @@ -1313,48 +1417,34 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_resource_claim" % key + " to method delete_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim`") # noqa: E501 + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_device_class`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1366,20 +1456,20 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims', 'DELETE', + '/apis/resource.k8s.io/v1beta2/deviceclasses/{name}', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1beta2DeviceClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1387,30 +1477,24 @@ def delete_collection_namespaced_resource_claim_with_http_info(self, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_resource_claim_parameters(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim_parameters # noqa: E501 + def delete_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_resource_claim # noqa: E501 - delete collection of ResourceClaimParameters # noqa: E501 + delete a ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_parameters(namespace, async_req=True) + >>> thread = api.delete_namespaced_resource_claim(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1419,37 +1503,31 @@ def delete_collection_namespaced_resource_claim_parameters(self, namespace, **kw number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_resource_claim_parameters_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_namespaced_resource_claim_with_http_info(name, namespace, **kwargs) # noqa: E501 - def delete_collection_namespaced_resource_claim_parameters_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim_parameters # noqa: E501 + def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_resource_claim # noqa: E501 - delete collection of ResourceClaimParameters # noqa: E501 + delete a ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_parameters_with_http_info(namespace, async_req=True) + >>> thread = api.delete_namespaced_resource_claim_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1460,7 +1538,7 @@ def delete_collection_namespaced_resource_claim_parameters_with_http_info(self, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1468,20 +1546,14 @@ def delete_collection_namespaced_resource_claim_parameters_with_http_info(self, local_var_params = locals() all_params = [ + 'name', 'namespace', 'pretty', - '_continue', 'dry_run', - 'field_selector', 'grace_period_seconds', - 'label_selector', - 'limit', + 'ignore_store_read_error_with_cluster_breaking_potential', 'orphan_dependents', 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', 'body' ] all_params.extend( @@ -1497,48 +1569,40 @@ def delete_collection_namespaced_resource_claim_parameters_with_http_info(self, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_resource_claim_parameters" % key + " to method delete_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_claim`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_claim`") # noqa: E501 collection_formats = {} path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 if 'namespace' in local_var_params: path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1550,20 +1614,20 @@ def delete_collection_namespaced_resource_claim_parameters_with_http_info(self, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters', 'DELETE', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1571,30 +1635,24 @@ def delete_collection_namespaced_resource_claim_parameters_with_http_info(self, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_resource_claim_template(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim_template # noqa: E501 + def delete_namespaced_resource_claim_template(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_resource_claim_template # noqa: E501 - delete collection of ResourceClaimTemplate # noqa: E501 + delete a ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_template(namespace, async_req=True) + >>> thread = api.delete_namespaced_resource_claim_template(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the ResourceClaimTemplate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1603,37 +1661,31 @@ def delete_collection_namespaced_resource_claim_template(self, namespace, **kwar number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1beta2ResourceClaimTemplate If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_namespaced_resource_claim_template_with_http_info(name, namespace, **kwargs) # noqa: E501 - def delete_collection_namespaced_resource_claim_template_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_claim_template # noqa: E501 + def delete_namespaced_resource_claim_template_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """delete_namespaced_resource_claim_template # noqa: E501 - delete collection of ResourceClaimTemplate # noqa: E501 + delete a ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_claim_template_with_http_info(namespace, async_req=True) + >>> thread = api.delete_namespaced_resource_claim_template_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously + :param str name: name of the ResourceClaimTemplate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1644,7 +1696,7 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1652,20 +1704,14 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na local_var_params = locals() all_params = [ + 'name', 'namespace', 'pretty', - '_continue', 'dry_run', - 'field_selector', 'grace_period_seconds', - 'label_selector', - 'limit', + 'ignore_store_read_error_with_cluster_breaking_potential', 'orphan_dependents', 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', 'body' ] all_params.extend( @@ -1681,48 +1727,40 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_resource_claim_template" % key + " to method delete_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_claim_template`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} path_params = {} + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 if 'namespace' in local_var_params: path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1734,20 +1772,20 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates', 'DELETE', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1beta2ResourceClaimTemplate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1755,30 +1793,23 @@ def delete_collection_namespaced_resource_claim_template_with_http_info(self, na _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_namespaced_resource_class_parameters(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_class_parameters # noqa: E501 + def delete_resource_slice(self, name, **kwargs): # noqa: E501 + """delete_resource_slice # noqa: E501 - delete collection of ResourceClassParameters # noqa: E501 + delete a ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_class_parameters(namespace, async_req=True) + >>> thread = api.delete_resource_slice(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the ResourceSlice (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -1787,37 +1818,30 @@ def delete_collection_namespaced_resource_class_parameters(self, namespace, **kw number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1beta2ResourceSlice If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_namespaced_resource_class_parameters_with_http_info(namespace, **kwargs) # noqa: E501 + return self.delete_resource_slice_with_http_info(name, **kwargs) # noqa: E501 - def delete_collection_namespaced_resource_class_parameters_with_http_info(self, namespace, **kwargs): # noqa: E501 - """delete_collection_namespaced_resource_class_parameters # noqa: E501 + def delete_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 + """delete_resource_slice # noqa: E501 - delete collection of ResourceClassParameters # noqa: E501 + delete a ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_namespaced_resource_class_parameters_with_http_info(namespace, async_req=True) + >>> thread = api.delete_resource_slice_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the ResourceSlice (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param bool ignore_store_read_error_with_cluster_breaking_potential: if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers @@ -1828,7 +1852,7 @@ def delete_collection_namespaced_resource_class_parameters_with_http_info(self, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -1836,20 +1860,13 @@ def delete_collection_namespaced_resource_class_parameters_with_http_info(self, local_var_params = locals() all_params = [ - 'namespace', + 'name', 'pretty', - '_continue', 'dry_run', - 'field_selector', 'grace_period_seconds', - 'label_selector', - 'limit', + 'ignore_store_read_error_with_cluster_breaking_potential', 'orphan_dependents', 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', 'body' ] all_params.extend( @@ -1865,48 +1882,34 @@ def delete_collection_namespaced_resource_class_parameters_with_http_info(self, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_namespaced_resource_class_parameters" % key + " to method delete_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_collection_namespaced_resource_class_parameters`") # noqa: E501 + # verify the required parameter 'name' is set + if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 + local_var_params['name'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `delete_resource_slice`") # noqa: E501 collection_formats = {} path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 + if 'name' in local_var_params: + path_params['name'] = local_var_params['name'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'ignore_store_read_error_with_cluster_breaking_potential' in local_var_params and local_var_params['ignore_store_read_error_with_cluster_breaking_potential'] is not None: # noqa: E501 + query_params.append(('ignoreStoreReadErrorWithClusterBreakingPotential', local_var_params['ignore_store_read_error_with_cluster_breaking_potential'])) # noqa: E501 if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -1918,20 +1921,20 @@ def delete_collection_namespaced_resource_class_parameters_with_http_info(self, body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters', 'DELETE', + '/apis/resource.k8s.io/v1beta2/resourceslices/{name}', 'DELETE', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1beta2ResourceSlice', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -1939,30 +1942,16 @@ def delete_collection_namespaced_resource_class_parameters_with_http_info(self, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_resource_class(self, **kwargs): # noqa: E501 - """delete_collection_resource_class # noqa: E501 + def get_api_resources(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 - delete collection of ResourceClass # noqa: E501 + get available resources # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_resource_class(async_req=True) + >>> thread = api.get_api_resources(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -1970,37 +1959,23 @@ def delete_collection_resource_class(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1APIResourceList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_resource_class_with_http_info(**kwargs) # noqa: E501 + return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 - def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_resource_class # noqa: E501 + def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 + """get_api_resources # noqa: E501 - delete collection of ResourceClass # noqa: E501 + get available resources # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_resource_class_with_http_info(async_req=True) + >>> thread = api.get_api_resources_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2010,7 +1985,7 @@ def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E5 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2018,20 +1993,6 @@ def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E5 local_var_params = locals() all_params = [ - 'pretty', - '_continue', - 'dry_run', - 'field_selector', - 'grace_period_seconds', - 'label_selector', - 'limit', - 'orphan_dependents', - 'propagation_policy', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'body' ] all_params.extend( [ @@ -2046,7 +2007,7 @@ def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E5 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_resource_class" % key + " to method get_api_resources" % key ) local_var_params[key] = val del local_var_params['kwargs'] @@ -2056,32 +2017,6 @@ def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E5 path_params = {} query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 header_params = {} @@ -2089,24 +2024,22 @@ def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E5 local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses', 'DELETE', + '/apis/resource.k8s.io/v1beta2/', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1APIResourceList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2114,30 +2047,27 @@ def delete_collection_resource_class_with_http_info(self, **kwargs): # noqa: E5 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_collection_resource_slice(self, **kwargs): # noqa: E501 - """delete_collection_resource_slice # noqa: E501 + def list_device_class(self, **kwargs): # noqa: E501 + """list_device_class # noqa: E501 - delete collection of ResourceSlice # noqa: E501 + list or watch objects of kind DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_resource_slice(async_req=True) + >>> thread = api.list_device_class(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2145,37 +2075,34 @@ def delete_collection_resource_slice(self, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1Status + :return: V1beta2DeviceClassList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_collection_resource_slice_with_http_info(**kwargs) # noqa: E501 + return self.list_device_class_with_http_info(**kwargs) # noqa: E501 - def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E501 - """delete_collection_resource_slice # noqa: E501 + def list_device_class_with_http_info(self, **kwargs): # noqa: E501 + """list_device_class # noqa: E501 - delete collection of ResourceSlice # noqa: E501 + list or watch objects of kind DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_collection_resource_slice_with_http_info(async_req=True) + >>> thread = api.list_device_class_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param V1DeleteOptions body: + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2185,7 +2112,7 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1Status, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2DeviceClassList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2194,19 +2121,16 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 all_params = [ 'pretty', + 'allow_watch_bookmarks', '_continue', - 'dry_run', 'field_selector', - 'grace_period_seconds', 'label_selector', 'limit', - 'orphan_dependents', - 'propagation_policy', 'resource_version', 'resource_version_match', 'send_initial_events', 'timeout_seconds', - 'body' + 'watch' ] all_params.extend( [ @@ -2221,7 +2145,7 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_collection_resource_slice" % key + " to method list_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] @@ -2233,22 +2157,16 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 @@ -2257,6 +2175,8 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -2264,24 +2184,22 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices', 'DELETE', + '/apis/resource.k8s.io/v1beta2/deviceclasses', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1Status', # noqa: E501 + response_type='V1beta2DeviceClassList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2289,24 +2207,28 @@ def delete_collection_resource_slice_with_http_info(self, **kwargs): # noqa: E5 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_namespaced_pod_scheduling_context(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_pod_scheduling_context # noqa: E501 + def list_namespaced_resource_claim(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_resource_claim # noqa: E501 - delete a PodSchedulingContext # noqa: E501 + list or watch objects of kind ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_pod_scheduling_context(name, namespace, async_req=True) + >>> thread = api.list_namespaced_resource_claim(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2314,31 +2236,35 @@ def delete_namespaced_pod_scheduling_context(self, name, namespace, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext + :return: V1beta2ResourceClaimList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_namespaced_pod_scheduling_context_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.list_namespaced_resource_claim_with_http_info(namespace, **kwargs) # noqa: E501 - def delete_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_pod_scheduling_context # noqa: E501 + def list_namespaced_resource_claim_with_http_info(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_resource_claim # noqa: E501 - delete a PodSchedulingContext # noqa: E501 + list or watch objects of kind ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_pod_scheduling_context_with_http_info(name, namespace, async_req=True) + >>> thread = api.list_namespaced_resource_claim_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2348,7 +2274,7 @@ def delete_namespaced_pod_scheduling_context_with_http_info(self, name, namespac number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2356,14 +2282,18 @@ def delete_namespaced_pod_scheduling_context_with_http_info(self, name, namespac local_var_params = locals() all_params = [ - 'name', 'namespace', 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' ] all_params.extend( [ @@ -2378,38 +2308,44 @@ def delete_namespaced_pod_scheduling_context_with_http_info(self, name, namespac if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_pod_scheduling_context" % key + " to method list_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_pod_scheduling_context`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_pod_scheduling_context`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_claim`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 if 'namespace' in local_var_params: path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -2417,24 +2353,22 @@ def delete_namespaced_pod_scheduling_context_with_http_info(self, name, namespac local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}', 'DELETE', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 + response_type='V1beta2ResourceClaimList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2442,24 +2376,28 @@ def delete_namespaced_pod_scheduling_context_with_http_info(self, name, namespac _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_claim # noqa: E501 + def list_namespaced_resource_claim_template(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_resource_claim_template # noqa: E501 - delete a ResourceClaim # noqa: E501 + list or watch objects of kind ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_claim(name, namespace, async_req=True) + >>> thread = api.list_namespaced_resource_claim_template(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -2467,31 +2405,35 @@ def delete_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaim + :return: V1beta2ResourceClaimTemplateList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.delete_namespaced_resource_claim_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.list_namespaced_resource_claim_template_with_http_info(namespace, **kwargs) # noqa: E501 - def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_claim # noqa: E501 + def list_namespaced_resource_claim_template_with_http_info(self, namespace, **kwargs): # noqa: E501 + """list_namespaced_resource_claim_template # noqa: E501 - delete a ResourceClaim # noqa: E501 + list or watch objects of kind ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_claim_with_http_info(name, namespace, async_req=True) + >>> thread = api.list_namespaced_resource_claim_template_with_http_info(namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -2501,7 +2443,7 @@ def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplateList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -2509,14 +2451,18 @@ def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwa local_var_params = locals() all_params = [ - 'name', 'namespace', 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' ] all_params.extend( [ @@ -2531,38 +2477,44 @@ def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwa if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_resource_claim" % key + " to method list_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_claim`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_claim`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 if 'namespace' in local_var_params: path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -2570,24 +2522,22 @@ def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwa local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}', 'DELETE', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 + response_type='V1beta2ResourceClaimTemplateList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -2595,4267 +2545,27 @@ def delete_namespaced_resource_claim_with_http_info(self, name, namespace, **kwa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def delete_namespaced_resource_claim_parameters(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_claim_parameters # noqa: E501 - - delete ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_claim_parameters(name, namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimParameters - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_namespaced_resource_claim_parameters_with_http_info(name, namespace, **kwargs) # noqa: E501 - - def delete_namespaced_resource_claim_parameters_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_claim_parameters # noqa: E501 + def list_resource_claim_for_all_namespaces(self, **kwargs): # noqa: E501 + """list_resource_claim_for_all_namespaces # noqa: E501 - delete ResourceClaimParameters # noqa: E501 + list or watch objects of kind ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_claim_parameters_with_http_info(name, namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParameters, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_resource_claim_parameters" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_claim_parameters`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_claim_parameters`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimParameters', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_namespaced_resource_claim_template(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_claim_template # noqa: E501 - - delete a ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_claim_template(name, namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplate - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_namespaced_resource_claim_template_with_http_info(name, namespace, **kwargs) # noqa: E501 - - def delete_namespaced_resource_claim_template_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_claim_template # noqa: E501 - - delete a ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_claim_template_with_http_info(name, namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_resource_claim_template" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_claim_template`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_claim_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimTemplate', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_namespaced_resource_class_parameters(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_class_parameters # noqa: E501 - - delete ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_class_parameters(name, namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClassParameters - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_namespaced_resource_class_parameters_with_http_info(name, namespace, **kwargs) # noqa: E501 - - def delete_namespaced_resource_class_parameters_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """delete_namespaced_resource_class_parameters # noqa: E501 - - delete ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_namespaced_resource_class_parameters_with_http_info(name, namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParameters, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_namespaced_resource_class_parameters" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_namespaced_resource_class_parameters`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `delete_namespaced_resource_class_parameters`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClassParameters', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_resource_class(self, name, **kwargs): # noqa: E501 - """delete_resource_class # noqa: E501 - - delete a ResourceClass # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_resource_class(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClass - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_resource_class_with_http_info(name, **kwargs) # noqa: E501 - - def delete_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_resource_class # noqa: E501 - - delete a ResourceClass # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_resource_class_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClass, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_resource_class" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_resource_class`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClass', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def delete_resource_slice(self, name, **kwargs): # noqa: E501 - """delete_resource_slice # noqa: E501 - - delete a ResourceSlice # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_resource_slice(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceSlice (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceSlice - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.delete_resource_slice_with_http_info(name, **kwargs) # noqa: E501 - - def delete_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 - """delete_resource_slice # noqa: E501 - - delete a ResourceSlice # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.delete_resource_slice_with_http_info(name, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceSlice (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param int grace_period_seconds: The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately. - :param bool orphan_dependents: Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both. - :param str propagation_policy: Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground. - :param V1DeleteOptions body: - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'pretty', - 'dry_run', - 'grace_period_seconds', - 'orphan_dependents', - 'propagation_policy', - 'body' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method delete_resource_slice" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `delete_resource_slice`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'grace_period_seconds' in local_var_params and local_var_params['grace_period_seconds'] is not None: # noqa: E501 - query_params.append(('gracePeriodSeconds', local_var_params['grace_period_seconds'])) # noqa: E501 - if 'orphan_dependents' in local_var_params and local_var_params['orphan_dependents'] is not None: # noqa: E501 - query_params.append(('orphanDependents', local_var_params['orphan_dependents'])) # noqa: E501 - if 'propagation_policy' in local_var_params and local_var_params['propagation_policy'] is not None: # noqa: E501 - query_params.append(('propagationPolicy', local_var_params['propagation_policy'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices/{name}', 'DELETE', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceSlice', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def get_api_resources(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1APIResourceList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.get_api_resources_with_http_info(**kwargs) # noqa: E501 - - def get_api_resources_with_http_info(self, **kwargs): # noqa: E501 - """get_api_resources # noqa: E501 - - get available resources # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.get_api_resources_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1APIResourceList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method get_api_resources" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1APIResourceList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_namespaced_pod_scheduling_context(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_pod_scheduling_context # noqa: E501 - - list or watch objects of kind PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_pod_scheduling_context(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2PodSchedulingContextList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_namespaced_pod_scheduling_context_with_http_info(namespace, **kwargs) # noqa: E501 - - def list_namespaced_pod_scheduling_context_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_pod_scheduling_context # noqa: E501 - - list or watch objects of kind PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_pod_scheduling_context_with_http_info(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContextList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'namespace', - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_namespaced_pod_scheduling_context" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_pod_scheduling_context`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2PodSchedulingContextList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_namespaced_resource_claim(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_claim # noqa: E501 - - list or watch objects of kind ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_claim(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_namespaced_resource_claim_with_http_info(namespace, **kwargs) # noqa: E501 - - def list_namespaced_resource_claim_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_claim # noqa: E501 - - list or watch objects of kind ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_claim_with_http_info(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'namespace', - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_namespaced_resource_claim" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_claim`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_namespaced_resource_claim_parameters(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_claim_parameters # noqa: E501 - - list or watch objects of kind ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_claim_parameters(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimParametersList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_namespaced_resource_claim_parameters_with_http_info(namespace, **kwargs) # noqa: E501 - - def list_namespaced_resource_claim_parameters_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_claim_parameters # noqa: E501 - - list or watch objects of kind ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_claim_parameters_with_http_info(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParametersList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'namespace', - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_namespaced_resource_claim_parameters" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_claim_parameters`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimParametersList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_namespaced_resource_claim_template(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_claim_template # noqa: E501 - - list or watch objects of kind ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_claim_template(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplateList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_namespaced_resource_claim_template_with_http_info(namespace, **kwargs) # noqa: E501 - - def list_namespaced_resource_claim_template_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_claim_template # noqa: E501 - - list or watch objects of kind ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_claim_template_with_http_info(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplateList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'namespace', - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_namespaced_resource_claim_template" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_claim_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimTemplateList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_namespaced_resource_class_parameters(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_class_parameters # noqa: E501 - - list or watch objects of kind ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_class_parameters(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClassParametersList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_namespaced_resource_class_parameters_with_http_info(namespace, **kwargs) # noqa: E501 - - def list_namespaced_resource_class_parameters_with_http_info(self, namespace, **kwargs): # noqa: E501 - """list_namespaced_resource_class_parameters # noqa: E501 - - list or watch objects of kind ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_namespaced_resource_class_parameters_with_http_info(namespace, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParametersList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'namespace', - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_namespaced_resource_class_parameters" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `list_namespaced_resource_class_parameters`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClassParametersList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_pod_scheduling_context_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_pod_scheduling_context_for_all_namespaces # noqa: E501 - - list or watch objects of kind PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_pod_scheduling_context_for_all_namespaces(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2PodSchedulingContextList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_pod_scheduling_context_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - - def list_pod_scheduling_context_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_pod_scheduling_context_for_all_namespaces # noqa: E501 - - list or watch objects of kind PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_pod_scheduling_context_for_all_namespaces_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContextList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_pod_scheduling_context_for_all_namespaces" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/podschedulingcontexts', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2PodSchedulingContextList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_resource_claim_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_resource_claim_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_claim_for_all_namespaces(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_resource_claim_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - - def list_resource_claim_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_resource_claim_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_claim_for_all_namespaces_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_resource_claim_for_all_namespaces" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclaims', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_resource_claim_parameters_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_resource_claim_parameters_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_claim_parameters_for_all_namespaces(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimParametersList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_resource_claim_parameters_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - - def list_resource_claim_parameters_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_resource_claim_parameters_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_claim_parameters_for_all_namespaces_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParametersList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_resource_claim_parameters_for_all_namespaces" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclaimparameters', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimParametersList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_resource_claim_template_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_resource_claim_template_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_claim_template_for_all_namespaces(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplateList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_resource_claim_template_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - - def list_resource_claim_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_resource_claim_template_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_claim_template_for_all_namespaces_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplateList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_resource_claim_template_for_all_namespaces" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclaimtemplates', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimTemplateList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_resource_class(self, **kwargs): # noqa: E501 - """list_resource_class # noqa: E501 - - list or watch objects of kind ResourceClass # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_class(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClassList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_resource_class_with_http_info(**kwargs) # noqa: E501 - - def list_resource_class_with_http_info(self, **kwargs): # noqa: E501 - """list_resource_class # noqa: E501 - - list or watch objects of kind ResourceClass # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_class_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_resource_class" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClassList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_resource_class_parameters_for_all_namespaces(self, **kwargs): # noqa: E501 - """list_resource_class_parameters_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_class_parameters_for_all_namespaces(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClassParametersList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_resource_class_parameters_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - - def list_resource_class_parameters_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 - """list_resource_class_parameters_for_all_namespaces # noqa: E501 - - list or watch objects of kind ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_class_parameters_for_all_namespaces_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParametersList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'pretty', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_resource_class_parameters_for_all_namespaces" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclassparameters', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClassParametersList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def list_resource_slice(self, **kwargs): # noqa: E501 - """list_resource_slice # noqa: E501 - - list or watch objects of kind ResourceSlice # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_slice(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceSliceList - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.list_resource_slice_with_http_info(**kwargs) # noqa: E501 - - def list_resource_slice_with_http_info(self, **kwargs): # noqa: E501 - """list_resource_slice # noqa: E501 - - list or watch objects of kind ResourceSlice # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.list_resource_slice_with_http_info(async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. - :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. - :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. - :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. - :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. - :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset - :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. - :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. - :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceSliceList, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'pretty', - 'allow_watch_bookmarks', - '_continue', - 'field_selector', - 'label_selector', - 'limit', - 'resource_version', - 'resource_version_match', - 'send_initial_events', - 'timeout_seconds', - 'watch' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method list_resource_slice" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - - collection_formats = {} - - path_params = {} - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 - query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 - if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 - query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 - if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 - query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 - if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 - query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 - if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 - query_params.append(('limit', local_var_params['limit'])) # noqa: E501 - if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 - query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 - if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 - query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 - if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 - query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 - if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 - query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 - if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 - query_params.append(('watch', local_var_params['watch'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices', 'GET', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceSliceList', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_pod_scheduling_context(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_pod_scheduling_context # noqa: E501 - - partially update the specified PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_pod_scheduling_context(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_pod_scheduling_context_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_pod_scheduling_context # noqa: E501 - - partially update the specified PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_pod_scheduling_context_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_pod_scheduling_context" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_scheduling_context`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_scheduling_context`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_scheduling_context`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_pod_scheduling_context_status(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_pod_scheduling_context_status # noqa: E501 - - partially update status of the specified PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_pod_scheduling_context_status(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_pod_scheduling_context_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_pod_scheduling_context_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_pod_scheduling_context_status # noqa: E501 - - partially update status of the specified PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_pod_scheduling_context_status_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_pod_scheduling_context_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_pod_scheduling_context_status`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_pod_scheduling_context_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_pod_scheduling_context_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}/status', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_resource_claim(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim # noqa: E501 - - partially update the specified ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaim - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_resource_claim_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_resource_claim_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim # noqa: E501 - - partially update the specified ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_resource_claim" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_resource_claim_parameters(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim_parameters # noqa: E501 - - partially update the specified ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_parameters(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimParameters - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_resource_claim_parameters_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_resource_claim_parameters_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim_parameters # noqa: E501 - - partially update the specified ResourceClaimParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_parameters_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParameters, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_resource_claim_parameters" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim_parameters`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim_parameters`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim_parameters`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimParameters', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_resource_claim_status(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim_status # noqa: E501 - - partially update status of the specified ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_status(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaim - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_resource_claim_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_resource_claim_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim_status # noqa: E501 - - partially update status of the specified ResourceClaim # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_status_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_resource_claim_status" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim_status`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim_status`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}/status', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_resource_claim_template(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim_template # noqa: E501 - - partially update the specified ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_template(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplate - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_resource_claim_template_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_resource_claim_template_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_claim_template # noqa: E501 - - partially update the specified ResourceClaimTemplate # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_claim_template_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_resource_claim_template" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim_template`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim_template`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim_template`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClaimTemplate', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_namespaced_resource_class_parameters(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_class_parameters # noqa: E501 - - partially update the specified ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_class_parameters(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClassParameters - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_namespaced_resource_class_parameters_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - - def patch_namespaced_resource_class_parameters_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """patch_namespaced_resource_class_parameters # noqa: E501 - - partially update the specified ResourceClassParameters # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_namespaced_resource_class_parameters_with_http_info(name, namespace, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParameters, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_namespaced_resource_class_parameters" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_class_parameters`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_class_parameters`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_class_parameters`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClassParameters', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_resource_class(self, name, body, **kwargs): # noqa: E501 - """patch_resource_class # noqa: E501 - - partially update the specified ResourceClass # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_resource_class(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceClass - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_resource_class_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_resource_class_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_resource_class # noqa: E501 - - partially update the specified ResourceClass # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_resource_class_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClass, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_resource_class" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_resource_class`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_resource_class`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceClass', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def patch_resource_slice(self, name, body, **kwargs): # noqa: E501 - """patch_resource_slice # noqa: E501 - - partially update the specified ResourceSlice # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_resource_slice(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceSlice (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: V1alpha2ResourceSlice - If the method is called asynchronously, - returns the request thread. - """ - kwargs['_return_http_data_only'] = True - return self.patch_resource_slice_with_http_info(name, body, **kwargs) # noqa: E501 - - def patch_resource_slice_with_http_info(self, name, body, **kwargs): # noqa: E501 - """patch_resource_slice # noqa: E501 - - partially update the specified ResourceSlice # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.patch_resource_slice_with_http_info(name, body, async_req=True) - >>> result = thread.get() - - :param async_req bool: execute request asynchronously - :param str name: name of the ResourceSlice (required) - :param object body: (required) - :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. - :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. - :param _return_http_data_only: response data without head status code - and headers - :param _preload_content: if False, the urllib3.HTTPResponse object will - be returned without reading/decoding response - data. Default is True. - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :return: tuple(V1alpha2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) - If the method is called asynchronously, - returns the request thread. - """ - - local_var_params = locals() - - all_params = [ - 'name', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation', - 'force' - ] - all_params.extend( - [ - 'async_req', - '_return_http_data_only', - '_preload_content', - '_request_timeout' - ] - ) - - for key, val in six.iteritems(local_var_params['kwargs']): - if key not in all_params: - raise ApiTypeError( - "Got an unexpected keyword argument '%s'" - " to method patch_resource_slice" % key - ) - local_var_params[key] = val - del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `patch_resource_slice`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `patch_resource_slice`") # noqa: E501 - - collection_formats = {} - - path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - - query_params = [] - if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 - query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 - if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 - query_params.append(('force', local_var_params['force'])) # noqa: E501 - - header_params = {} - - form_params = [] - local_var_files = {} - - body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] - # HTTP header `Accept` - header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 - - # HTTP header `Content-Type` - header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 - ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml']) # noqa: E501 - - # Authentication setting - auth_settings = ['BearerToken'] # noqa: E501 - - return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices/{name}', 'PATCH', - path_params, - query_params, - header_params, - body=body_params, - post_params=form_params, - files=local_var_files, - response_type='V1alpha2ResourceSlice', # noqa: E501 - auth_settings=auth_settings, - async_req=local_var_params.get('async_req'), - _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 - _preload_content=local_var_params.get('_preload_content', True), - _request_timeout=local_var_params.get('_request_timeout'), - collection_formats=collection_formats) - - def read_namespaced_pod_scheduling_context(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_pod_scheduling_context # noqa: E501 - - read the specified PodSchedulingContext # noqa: E501 - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_pod_scheduling_context(name, namespace, async_req=True) + >>> thread = api.list_resource_claim_for_all_namespaces(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -6863,26 +2573,34 @@ def read_namespaced_pod_scheduling_context(self, name, namespace, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext + :return: V1beta2ResourceClaimList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_pod_scheduling_context_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.list_resource_claim_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - def read_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_pod_scheduling_context # noqa: E501 + def list_resource_claim_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 + """list_resource_claim_for_all_namespaces # noqa: E501 - read the specified PodSchedulingContext # noqa: E501 + list or watch objects of kind ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_pod_scheduling_context_with_http_info(name, namespace, async_req=True) + >>> thread = api.list_resource_claim_for_all_namespaces_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -6892,7 +2610,7 @@ def read_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -6900,9 +2618,17 @@ def read_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, local_var_params = locals() all_params = [ - 'name', - 'namespace', - 'pretty' + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'pretty', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' ] all_params.extend( [ @@ -6917,30 +2643,38 @@ def read_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_pod_scheduling_context" % key + " to method list_resource_claim_for_all_namespaces" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_scheduling_context`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_scheduling_context`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -6950,20 +2684,20 @@ def read_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/resourceclaims', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 + response_type='V1beta2ResourceClaimList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -6971,19 +2705,27 @@ def read_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_pod_scheduling_context_status(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_pod_scheduling_context_status # noqa: E501 + def list_resource_claim_template_for_all_namespaces(self, **kwargs): # noqa: E501 + """list_resource_claim_template_for_all_namespaces # noqa: E501 - read status of the specified PodSchedulingContext # noqa: E501 + list or watch objects of kind ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_pod_scheduling_context_status(name, namespace, async_req=True) + >>> thread = api.list_resource_claim_template_for_all_namespaces(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -6991,26 +2733,34 @@ def read_namespaced_pod_scheduling_context_status(self, name, namespace, **kwarg number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext + :return: V1beta2ResourceClaimTemplateList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_pod_scheduling_context_status_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.list_resource_claim_template_for_all_namespaces_with_http_info(**kwargs) # noqa: E501 - def read_namespaced_pod_scheduling_context_status_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_pod_scheduling_context_status # noqa: E501 + def list_resource_claim_template_for_all_namespaces_with_http_info(self, **kwargs): # noqa: E501 + """list_resource_claim_template_for_all_namespaces # noqa: E501 - read status of the specified PodSchedulingContext # noqa: E501 + list or watch objects of kind ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_pod_scheduling_context_status_with_http_info(name, namespace, async_req=True) + >>> thread = api.list_resource_claim_template_for_all_namespaces_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7020,7 +2770,7 @@ def read_namespaced_pod_scheduling_context_status_with_http_info(self, name, nam number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplateList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7028,9 +2778,17 @@ def read_namespaced_pod_scheduling_context_status_with_http_info(self, name, nam local_var_params = locals() all_params = [ - 'name', - 'namespace', - 'pretty' + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'pretty', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' ] all_params.extend( [ @@ -7045,30 +2803,38 @@ def read_namespaced_pod_scheduling_context_status_with_http_info(self, name, nam if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_pod_scheduling_context_status" % key + " to method list_resource_claim_template_for_all_namespaces" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_pod_scheduling_context_status`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_pod_scheduling_context_status`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -7078,20 +2844,20 @@ def read_namespaced_pod_scheduling_context_status_with_http_info(self, name, nam body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}/status', 'GET', + '/apis/resource.k8s.io/v1beta2/resourceclaimtemplates', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 + response_type='V1beta2ResourceClaimTemplateList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7099,19 +2865,27 @@ def read_namespaced_pod_scheduling_context_status_with_http_info(self, name, nam _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim # noqa: E501 + def list_resource_slice(self, **kwargs): # noqa: E501 + """list_resource_slice # noqa: E501 - read the specified ResourceClaim # noqa: E501 + list or watch objects of kind ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim(name, namespace, async_req=True) + >>> thread = api.list_resource_slice(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -7119,26 +2893,34 @@ def read_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E5 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaim + :return: V1beta2ResourceSliceList If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_resource_claim_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.list_resource_slice_with_http_info(**kwargs) # noqa: E501 - def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim # noqa: E501 + def list_resource_slice_with_http_info(self, **kwargs): # noqa: E501 + """list_resource_slice # noqa: E501 - read the specified ResourceClaim # noqa: E501 + list or watch objects of kind ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_with_http_info(name, namespace, async_req=True) + >>> thread = api.list_resource_slice_with_http_info(async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param bool allow_watch_bookmarks: allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored. + :param str _continue: The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\". This field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications. + :param str field_selector: A selector to restrict the list of returned objects by their fields. Defaults to everything. + :param str label_selector: A selector to restrict the list of returned objects by their labels. Defaults to everything. + :param int limit: limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true. The server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned. + :param str resource_version: resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param str resource_version_match: resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details. Defaults to unset + :param bool send_initial_events: `sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched. When `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan is interpreted as \"data at least as new as the provided `resourceVersion`\" and the bookmark event is send when the state is synced to a `resourceVersion` at least as fresh as the one provided by the ListOptions. If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the bookmark event is send when the state is synced at least to the moment when request started being processed. - `resourceVersionMatch` set to any other value or unset Invalid error is returned. Defaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise. + :param int timeout_seconds: Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity. + :param bool watch: Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7148,7 +2930,7 @@ def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwarg number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceSliceList, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7156,9 +2938,17 @@ def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwarg local_var_params = locals() all_params = [ - 'name', - 'namespace', - 'pretty' + 'pretty', + 'allow_watch_bookmarks', + '_continue', + 'field_selector', + 'label_selector', + 'limit', + 'resource_version', + 'resource_version_match', + 'send_initial_events', + 'timeout_seconds', + 'watch' ] all_params.extend( [ @@ -7173,30 +2963,38 @@ def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwarg if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_resource_claim" % key + " to method list_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] - # verify the required parameter 'name' is set - if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 - local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim`") # noqa: E501 collection_formats = {} path_params = {} - if 'name' in local_var_params: - path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'allow_watch_bookmarks' in local_var_params and local_var_params['allow_watch_bookmarks'] is not None: # noqa: E501 + query_params.append(('allowWatchBookmarks', local_var_params['allow_watch_bookmarks'])) # noqa: E501 + if '_continue' in local_var_params and local_var_params['_continue'] is not None: # noqa: E501 + query_params.append(('continue', local_var_params['_continue'])) # noqa: E501 + if 'field_selector' in local_var_params and local_var_params['field_selector'] is not None: # noqa: E501 + query_params.append(('fieldSelector', local_var_params['field_selector'])) # noqa: E501 + if 'label_selector' in local_var_params and local_var_params['label_selector'] is not None: # noqa: E501 + query_params.append(('labelSelector', local_var_params['label_selector'])) # noqa: E501 + if 'limit' in local_var_params and local_var_params['limit'] is not None: # noqa: E501 + query_params.append(('limit', local_var_params['limit'])) # noqa: E501 + if 'resource_version' in local_var_params and local_var_params['resource_version'] is not None: # noqa: E501 + query_params.append(('resourceVersion', local_var_params['resource_version'])) # noqa: E501 + if 'resource_version_match' in local_var_params and local_var_params['resource_version_match'] is not None: # noqa: E501 + query_params.append(('resourceVersionMatch', local_var_params['resource_version_match'])) # noqa: E501 + if 'send_initial_events' in local_var_params and local_var_params['send_initial_events'] is not None: # noqa: E501 + query_params.append(('sendInitialEvents', local_var_params['send_initial_events'])) # noqa: E501 + if 'timeout_seconds' in local_var_params and local_var_params['timeout_seconds'] is not None: # noqa: E501 + query_params.append(('timeoutSeconds', local_var_params['timeout_seconds'])) # noqa: E501 + if 'watch' in local_var_params and local_var_params['watch'] is not None: # noqa: E501 + query_params.append(('watch', local_var_params['watch'])) # noqa: E501 header_params = {} @@ -7206,20 +3004,20 @@ def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwarg body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor', 'application/json;stream=watch', 'application/vnd.kubernetes.protobuf;stream=watch', 'application/cbor-seq']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/resourceslices', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 + response_type='V1beta2ResourceSliceList', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7227,19 +3025,23 @@ def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwarg _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_resource_claim_parameters(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim_parameters # noqa: E501 + def patch_device_class(self, name, body, **kwargs): # noqa: E501 + """patch_device_class # noqa: E501 - read the specified ResourceClaimParameters # noqa: E501 + partially update the specified DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_parameters(name, namespace, async_req=True) + >>> thread = api.patch_device_class(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the DeviceClass (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -7247,26 +3049,30 @@ def read_namespaced_resource_claim_parameters(self, name, namespace, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaimParameters + :return: V1beta2DeviceClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_resource_claim_parameters_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.patch_device_class_with_http_info(name, body, **kwargs) # noqa: E501 - def read_namespaced_resource_claim_parameters_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim_parameters # noqa: E501 + def patch_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_device_class # noqa: E501 - read the specified ResourceClaimParameters # noqa: E501 + partially update the specified DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_parameters_with_http_info(name, namespace, async_req=True) + >>> thread = api.patch_device_class_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) + :param str name: name of the DeviceClass (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7276,7 +3082,7 @@ def read_namespaced_resource_claim_parameters_with_http_info(self, name, namespa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParameters, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2DeviceClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7285,8 +3091,12 @@ def read_namespaced_resource_claim_parameters_with_http_info(self, name, namespa all_params = [ 'name', - 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -7301,30 +3111,36 @@ def read_namespaced_resource_claim_parameters_with_http_info(self, name, namespa if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_resource_claim_parameters" % key + " to method patch_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim_parameters`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_device_class`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_device_class`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -7332,22 +3148,28 @@ def read_namespaced_resource_claim_parameters_with_http_info(self, name, namespa local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/deviceclasses/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaimParameters', # noqa: E501 + response_type='V1beta2DeviceClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7355,19 +3177,24 @@ def read_namespaced_resource_claim_parameters_with_http_info(self, name, namespa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_resource_claim_status(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim_status # noqa: E501 + def patch_namespaced_resource_claim(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_resource_claim # noqa: E501 - read status of the specified ResourceClaim # noqa: E501 + partially update the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_status(name, namespace, async_req=True) + >>> thread = api.patch_namespaced_resource_claim(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -7375,26 +3202,31 @@ def read_namespaced_resource_claim_status(self, name, namespace, **kwargs): # n number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaim + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_resource_claim_status_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.patch_namespaced_resource_claim_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim_status # noqa: E501 + def patch_namespaced_resource_claim_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_resource_claim # noqa: E501 - read status of the specified ResourceClaim # noqa: E501 + partially update the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_status_with_http_info(name, namespace, async_req=True) + >>> thread = api.patch_namespaced_resource_claim_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7404,7 +3236,7 @@ def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7414,7 +3246,12 @@ def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, all_params = [ 'name', 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -7429,18 +3266,22 @@ def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_resource_claim_status" % key + " to method patch_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim`") # noqa: E501 collection_formats = {} @@ -7453,6 +3294,14 @@ def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -7460,22 +3309,28 @@ def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}/status', 'GET', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7483,19 +3338,24 @@ def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_resource_claim_template(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim_template # noqa: E501 + def patch_namespaced_resource_claim_status(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_resource_claim_status # noqa: E501 - read the specified ResourceClaimTemplate # noqa: E501 + partially update status of the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_template(name, namespace, async_req=True) + >>> thread = api.patch_namespaced_resource_claim_status(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -7503,26 +3363,31 @@ def read_namespaced_resource_claim_template(self, name, namespace, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplate + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_resource_claim_template_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.patch_namespaced_resource_claim_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def read_namespaced_resource_claim_template_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_claim_template # noqa: E501 + def patch_namespaced_resource_claim_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_resource_claim_status # noqa: E501 - read the specified ResourceClaimTemplate # noqa: E501 + partially update status of the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_claim_template_with_http_info(name, namespace, async_req=True) + >>> thread = api.patch_namespaced_resource_claim_status_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7532,7 +3397,7 @@ def read_namespaced_resource_claim_template_with_http_info(self, name, namespace number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7542,7 +3407,12 @@ def read_namespaced_resource_claim_template_with_http_info(self, name, namespace all_params = [ 'name', 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -7557,18 +3427,22 @@ def read_namespaced_resource_claim_template_with_http_info(self, name, namespace if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_resource_claim_template" % key + " to method patch_namespaced_resource_claim_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim_status`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim_status`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim_status`") # noqa: E501 collection_formats = {} @@ -7581,6 +3455,14 @@ def read_namespaced_resource_claim_template_with_http_info(self, name, namespace query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -7588,22 +3470,28 @@ def read_namespaced_resource_claim_template_with_http_info(self, name, namespace local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}/status', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaimTemplate', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7611,19 +3499,24 @@ def read_namespaced_resource_claim_template_with_http_info(self, name, namespace _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_namespaced_resource_class_parameters(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_class_parameters # noqa: E501 + def patch_namespaced_resource_claim_template(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_resource_claim_template # noqa: E501 - read the specified ResourceClassParameters # noqa: E501 + partially update the specified ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_class_parameters(name, namespace, async_req=True) + >>> thread = api.patch_namespaced_resource_claim_template(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) + :param str name: name of the ResourceClaimTemplate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -7631,26 +3524,31 @@ def read_namespaced_resource_class_parameters(self, name, namespace, **kwargs): number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClassParameters + :return: V1beta2ResourceClaimTemplate If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_namespaced_resource_class_parameters_with_http_info(name, namespace, **kwargs) # noqa: E501 + return self.patch_namespaced_resource_claim_template_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def read_namespaced_resource_class_parameters_with_http_info(self, name, namespace, **kwargs): # noqa: E501 - """read_namespaced_resource_class_parameters # noqa: E501 + def patch_namespaced_resource_claim_template_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """patch_namespaced_resource_claim_template # noqa: E501 - read the specified ResourceClassParameters # noqa: E501 + partially update the specified ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_namespaced_resource_class_parameters_with_http_info(name, namespace, async_req=True) + >>> thread = api.patch_namespaced_resource_claim_template_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) + :param str name: name of the ResourceClaimTemplate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7660,7 +3558,7 @@ def read_namespaced_resource_class_parameters_with_http_info(self, name, namespa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParameters, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7670,7 +3568,12 @@ def read_namespaced_resource_class_parameters_with_http_info(self, name, namespa all_params = [ 'name', 'namespace', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -7685,18 +3588,22 @@ def read_namespaced_resource_class_parameters_with_http_info(self, name, namespa if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_namespaced_resource_class_parameters" % key + " to method patch_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_class_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_namespaced_resource_claim_template`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_class_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `patch_namespaced_resource_claim_template`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} @@ -7709,6 +3616,14 @@ def read_namespaced_resource_class_parameters_with_http_info(self, name, namespa query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -7716,22 +3631,28 @@ def read_namespaced_resource_class_parameters_with_http_info(self, name, namespa local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClassParameters', # noqa: E501 + response_type='V1beta2ResourceClaimTemplate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7739,18 +3660,23 @@ def read_namespaced_resource_class_parameters_with_http_info(self, name, namespa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_resource_class(self, name, **kwargs): # noqa: E501 - """read_resource_class # noqa: E501 + def patch_resource_slice(self, name, body, **kwargs): # noqa: E501 + """patch_resource_slice # noqa: E501 - read the specified ResourceClass # noqa: E501 + partially update the specified ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_resource_class(name, async_req=True) + >>> thread = api.patch_resource_slice(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) + :param str name: name of the ResourceSlice (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -7758,25 +3684,30 @@ def read_resource_class(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClass + :return: V1beta2ResourceSlice If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_resource_class_with_http_info(name, **kwargs) # noqa: E501 + return self.patch_resource_slice_with_http_info(name, body, **kwargs) # noqa: E501 - def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 - """read_resource_class # noqa: E501 + def patch_resource_slice_with_http_info(self, name, body, **kwargs): # noqa: E501 + """patch_resource_slice # noqa: E501 - read the specified ResourceClass # noqa: E501 + partially update the specified ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_resource_class_with_http_info(name, async_req=True) + >>> thread = api.patch_resource_slice_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) + :param str name: name of the ResourceSlice (required) + :param object body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). + :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed + :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch). + :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. + :param bool force: Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -7786,7 +3717,7 @@ def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7795,7 +3726,12 @@ def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 all_params = [ 'name', - 'pretty' + 'body', + 'pretty', + 'dry_run', + 'field_manager', + 'field_validation', + 'force' ] all_params.extend( [ @@ -7810,14 +3746,18 @@ def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_resource_class" % key + " to method patch_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_resource_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `patch_resource_slice`") # noqa: E501 + # verify the required parameter 'body' is set + if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 + local_var_params['body'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `patch_resource_slice`") # noqa: E501 collection_formats = {} @@ -7828,6 +3768,14 @@ def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 + if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 + query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 + if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 + query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 + if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 + query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 + if 'force' in local_var_params and local_var_params['force'] is not None: # noqa: E501 + query_params.append(('force', local_var_params['force'])) # noqa: E501 header_params = {} @@ -7835,22 +3783,28 @@ def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 local_var_files = {} body_params = None + if 'body' in local_var_params: + body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 + + # HTTP header `Content-Type` + header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501 + ['application/json-patch+json', 'application/merge-patch+json', 'application/strategic-merge-patch+json', 'application/apply-patch+yaml', 'application/apply-patch+cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/resourceslices/{name}', 'PATCH', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClass', # noqa: E501 + response_type='V1beta2ResourceSlice', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7858,17 +3812,17 @@ def read_resource_class_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def read_resource_slice(self, name, **kwargs): # noqa: E501 - """read_resource_slice # noqa: E501 + def read_device_class(self, name, **kwargs): # noqa: E501 + """read_device_class # noqa: E501 - read the specified ResourceSlice # noqa: E501 + read the specified DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_resource_slice(name, async_req=True) + >>> thread = api.read_device_class(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceSlice (required) + :param str name: name of the DeviceClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response @@ -7877,24 +3831,24 @@ def read_resource_slice(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceSlice + :return: V1beta2DeviceClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.read_resource_slice_with_http_info(name, **kwargs) # noqa: E501 + return self.read_device_class_with_http_info(name, **kwargs) # noqa: E501 - def read_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 - """read_resource_slice # noqa: E501 + def read_device_class_with_http_info(self, name, **kwargs): # noqa: E501 + """read_device_class # noqa: E501 - read the specified ResourceSlice # noqa: E501 + read the specified DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.read_resource_slice_with_http_info(name, async_req=True) + >>> thread = api.read_device_class_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceSlice (required) + :param str name: name of the DeviceClass (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param _return_http_data_only: response data without head status code and headers @@ -7905,7 +3859,7 @@ def read_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2DeviceClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -7929,14 +3883,14 @@ def read_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method read_resource_slice" % key + " to method read_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `read_resource_slice`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_device_class`") # noqa: E501 collection_formats = {} @@ -7956,20 +3910,20 @@ def read_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 body_params = None # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices/{name}', 'GET', + '/apis/resource.k8s.io/v1beta2/deviceclasses/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceSlice', # noqa: E501 + response_type='V1beta2DeviceClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -7977,23 +3931,19 @@ def read_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_pod_scheduling_context(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_pod_scheduling_context # noqa: E501 + def read_namespaced_resource_claim(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_resource_claim # noqa: E501 - replace the specified PodSchedulingContext # noqa: E501 + read the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_pod_scheduling_context(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_resource_claim(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2PodSchedulingContext body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -8001,30 +3951,26 @@ def replace_namespaced_pod_scheduling_context(self, name, namespace, body, **kwa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_pod_scheduling_context_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_namespaced_resource_claim_with_http_info(name, namespace, **kwargs) # noqa: E501 - def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_pod_scheduling_context # noqa: E501 + def read_namespaced_resource_claim_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_resource_claim # noqa: E501 - replace the specified PodSchedulingContext # noqa: E501 + read the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_pod_scheduling_context_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_resource_claim_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2PodSchedulingContext body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -8034,7 +3980,7 @@ def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespa number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8044,11 +3990,7 @@ def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespa all_params = [ 'name', 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' + 'pretty' ] all_params.extend( [ @@ -8063,22 +4005,18 @@ def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespa if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_pod_scheduling_context" % key + " to method read_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_scheduling_context`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_scheduling_context`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_scheduling_context`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim`") # noqa: E501 collection_formats = {} @@ -8091,12 +4029,6 @@ def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespa query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -8104,24 +4036,22 @@ def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespa local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -8129,23 +4059,19 @@ def replace_namespaced_pod_scheduling_context_with_http_info(self, name, namespa _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_pod_scheduling_context_status(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_pod_scheduling_context_status # noqa: E501 + def read_namespaced_resource_claim_status(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_resource_claim_status # noqa: E501 - replace status of the specified PodSchedulingContext # noqa: E501 + read status of the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_pod_scheduling_context_status(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_resource_claim_status(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2PodSchedulingContext body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -8153,30 +4079,26 @@ def replace_namespaced_pod_scheduling_context_status(self, name, namespace, body number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2PodSchedulingContext + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_pod_scheduling_context_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_namespaced_resource_claim_status_with_http_info(name, namespace, **kwargs) # noqa: E501 - def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_pod_scheduling_context_status # noqa: E501 + def read_namespaced_resource_claim_status_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_resource_claim_status # noqa: E501 - replace status of the specified PodSchedulingContext # noqa: E501 + read status of the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_pod_scheduling_context_status_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_resource_claim_status_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the PodSchedulingContext (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2PodSchedulingContext body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -8186,7 +4108,7 @@ def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2PodSchedulingContext, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8196,11 +4118,7 @@ def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, all_params = [ 'name', 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' + 'pretty' ] all_params.extend( [ @@ -8215,22 +4133,18 @@ def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_pod_scheduling_context_status" % key + " to method read_namespaced_resource_claim_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_pod_scheduling_context_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim_status`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_pod_scheduling_context_status`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_pod_scheduling_context_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim_status`") # noqa: E501 collection_formats = {} @@ -8243,12 +4157,6 @@ def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -8256,24 +4164,22 @@ def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/podschedulingcontexts/{name}/status', 'PUT', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}/status', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2PodSchedulingContext', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -8281,23 +4187,19 @@ def replace_namespaced_pod_scheduling_context_status_with_http_info(self, name, _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_resource_claim(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim # noqa: E501 + def read_namespaced_resource_claim_template(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_resource_claim_template # noqa: E501 - replace the specified ResourceClaim # noqa: E501 + read the specified ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_resource_claim_template(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) + :param str name: name of the ResourceClaimTemplate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -8305,30 +4207,26 @@ def replace_namespaced_resource_claim(self, name, namespace, body, **kwargs): # number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaim + :return: V1beta2ResourceClaimTemplate If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_resource_claim_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_namespaced_resource_claim_template_with_http_info(name, namespace, **kwargs) # noqa: E501 - def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim # noqa: E501 + def read_namespaced_resource_claim_template_with_http_info(self, name, namespace, **kwargs): # noqa: E501 + """read_namespaced_resource_claim_template # noqa: E501 - replace the specified ResourceClaim # noqa: E501 + read the specified ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_namespaced_resource_claim_template_with_http_info(name, namespace, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) + :param str name: name of the ResourceClaimTemplate (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -8338,7 +4236,7 @@ def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8348,11 +4246,7 @@ def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body all_params = [ 'name', 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' + 'pretty' ] all_params.extend( [ @@ -8367,22 +4261,18 @@ def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_resource_claim" % key + " to method read_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_namespaced_resource_claim_template`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `read_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} @@ -8395,12 +4285,6 @@ def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -8408,24 +4292,22 @@ def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 + response_type='V1beta2ResourceClaimTemplate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -8433,23 +4315,18 @@ def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_resource_claim_parameters(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim_parameters # noqa: E501 + def read_resource_slice(self, name, **kwargs): # noqa: E501 + """read_resource_slice # noqa: E501 - replace the specified ResourceClaimParameters # noqa: E501 + read the specified ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_parameters(name, namespace, body, async_req=True) + >>> thread = api.read_resource_slice(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimParameters body: (required) + :param str name: name of the ResourceSlice (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _preload_content: if False, the urllib3.HTTPResponse object will be returned without reading/decoding response data. Default is True. @@ -8457,30 +4334,25 @@ def replace_namespaced_resource_claim_parameters(self, name, namespace, body, ** number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaimParameters + :return: V1beta2ResourceSlice If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_resource_claim_parameters_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.read_resource_slice_with_http_info(name, **kwargs) # noqa: E501 - def replace_namespaced_resource_claim_parameters_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim_parameters # noqa: E501 + def read_resource_slice_with_http_info(self, name, **kwargs): # noqa: E501 + """read_resource_slice # noqa: E501 - replace the specified ResourceClaimParameters # noqa: E501 + read the specified ResourceSlice # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_parameters_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.read_resource_slice_with_http_info(name, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimParameters (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimParameters body: (required) + :param str name: name of the ResourceSlice (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). - :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed - :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. - :param str field_validation: fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered. :param _return_http_data_only: response data without head status code and headers :param _preload_content: if False, the urllib3.HTTPResponse object will @@ -8490,7 +4362,7 @@ def replace_namespaced_resource_claim_parameters_with_http_info(self, name, name number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimParameters, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8499,12 +4371,7 @@ def replace_namespaced_resource_claim_parameters_with_http_info(self, name, name all_params = [ 'name', - 'namespace', - 'body', - 'pretty', - 'dry_run', - 'field_manager', - 'field_validation' + 'pretty' ] all_params.extend( [ @@ -8519,40 +4386,24 @@ def replace_namespaced_resource_claim_parameters_with_http_info(self, name, name if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_resource_claim_parameters" % key + " to method read_resource_slice" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim_parameters`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim_parameters`") # noqa: E501 - # verify the required parameter 'body' is set - if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 - local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `read_resource_slice`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 query_params.append(('pretty', local_var_params['pretty'])) # noqa: E501 - if 'dry_run' in local_var_params and local_var_params['dry_run'] is not None: # noqa: E501 - query_params.append(('dryRun', local_var_params['dry_run'])) # noqa: E501 - if 'field_manager' in local_var_params and local_var_params['field_manager'] is not None: # noqa: E501 - query_params.append(('fieldManager', local_var_params['field_manager'])) # noqa: E501 - if 'field_validation' in local_var_params and local_var_params['field_validation'] is not None: # noqa: E501 - query_params.append(('fieldValidation', local_var_params['field_validation'])) # noqa: E501 header_params = {} @@ -8560,24 +4411,22 @@ def replace_namespaced_resource_claim_parameters_with_http_info(self, name, name local_var_files = {} body_params = None - if 'body' in local_var_params: - body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimparameters/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/resourceslices/{name}', 'GET', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaimParameters', # noqa: E501 + response_type='V1beta2ResourceSlice', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -8585,19 +4434,18 @@ def replace_namespaced_resource_claim_parameters_with_http_info(self, name, name _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_resource_claim_status(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim_status # noqa: E501 + def replace_device_class(self, name, body, **kwargs): # noqa: E501 + """replace_device_class # noqa: E501 - replace status of the specified ResourceClaim # noqa: E501 + replace the specified DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_status(name, namespace, body, async_req=True) + >>> thread = api.replace_device_class(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaim body: (required) + :param str name: name of the DeviceClass (required) + :param V1beta2DeviceClass body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -8609,26 +4457,25 @@ def replace_namespaced_resource_claim_status(self, name, namespace, body, **kwar number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaim + :return: V1beta2DeviceClass If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_resource_claim_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.replace_device_class_with_http_info(name, body, **kwargs) # noqa: E501 - def replace_namespaced_resource_claim_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim_status # noqa: E501 + def replace_device_class_with_http_info(self, name, body, **kwargs): # noqa: E501 + """replace_device_class # noqa: E501 - replace status of the specified ResourceClaim # noqa: E501 + replace the specified DeviceClass # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_status_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.replace_device_class_with_http_info(name, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaim (required) - :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaim body: (required) + :param str name: name of the DeviceClass (required) + :param V1beta2DeviceClass body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -8642,7 +4489,7 @@ def replace_namespaced_resource_claim_status_with_http_info(self, name, namespac number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2DeviceClass, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8651,7 +4498,6 @@ def replace_namespaced_resource_claim_status_with_http_info(self, name, namespac all_params = [ 'name', - 'namespace', 'body', 'pretty', 'dry_run', @@ -8671,30 +4517,24 @@ def replace_namespaced_resource_claim_status_with_http_info(self, name, namespac if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_resource_claim_status" % key + " to method replace_device_class" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim_status`") # noqa: E501 - # verify the required parameter 'namespace' is set - if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 - local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_device_class`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim_status`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_device_class`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 - if 'namespace' in local_var_params: - path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -8716,20 +4556,20 @@ def replace_namespaced_resource_claim_status_with_http_info(self, name, namespac body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaims/{name}/status', 'PUT', + '/apis/resource.k8s.io/v1beta2/deviceclasses/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaim', # noqa: E501 + response_type='V1beta2DeviceClass', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -8737,19 +4577,19 @@ def replace_namespaced_resource_claim_status_with_http_info(self, name, namespac _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_resource_claim_template(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim_template # noqa: E501 + def replace_namespaced_resource_claim(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_resource_claim # noqa: E501 - replace the specified ResourceClaimTemplate # noqa: E501 + replace the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_template(name, namespace, body, async_req=True) + >>> thread = api.replace_namespaced_resource_claim(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimTemplate body: (required) + :param V1beta2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -8761,26 +4601,26 @@ def replace_namespaced_resource_claim_template(self, name, namespace, body, **kw number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClaimTemplate + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_resource_claim_template_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.replace_namespaced_resource_claim_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def replace_namespaced_resource_claim_template_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_claim_template # noqa: E501 + def replace_namespaced_resource_claim_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_resource_claim # noqa: E501 - replace the specified ResourceClaimTemplate # noqa: E501 + replace the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_claim_template_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.replace_namespaced_resource_claim_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClaimTemplate (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClaimTemplate body: (required) + :param V1beta2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -8794,7 +4634,7 @@ def replace_namespaced_resource_claim_template_with_http_info(self, name, namesp number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8823,22 +4663,22 @@ def replace_namespaced_resource_claim_template_with_http_info(self, name, namesp if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_resource_claim_template" % key + " to method replace_namespaced_resource_claim" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim_template`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim`") # noqa: E501 collection_formats = {} @@ -8868,20 +4708,20 @@ def replace_namespaced_resource_claim_template_with_http_info(self, name, namesp body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClaimTemplate', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -8889,19 +4729,19 @@ def replace_namespaced_resource_claim_template_with_http_info(self, name, namesp _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_namespaced_resource_class_parameters(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_class_parameters # noqa: E501 + def replace_namespaced_resource_claim_status(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_resource_claim_status # noqa: E501 - replace the specified ResourceClassParameters # noqa: E501 + replace status of the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_class_parameters(name, namespace, body, async_req=True) + >>> thread = api.replace_namespaced_resource_claim_status(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClassParameters body: (required) + :param V1beta2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -8913,26 +4753,26 @@ def replace_namespaced_resource_class_parameters(self, name, namespace, body, ** number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClassParameters + :return: V1beta2ResourceClaim If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_namespaced_resource_class_parameters_with_http_info(name, namespace, body, **kwargs) # noqa: E501 + return self.replace_namespaced_resource_claim_status_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def replace_namespaced_resource_class_parameters_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 - """replace_namespaced_resource_class_parameters # noqa: E501 + def replace_namespaced_resource_claim_status_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_resource_claim_status # noqa: E501 - replace the specified ResourceClassParameters # noqa: E501 + replace status of the specified ResourceClaim # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_namespaced_resource_class_parameters_with_http_info(name, namespace, body, async_req=True) + >>> thread = api.replace_namespaced_resource_claim_status_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClassParameters (required) + :param str name: name of the ResourceClaim (required) :param str namespace: object name and auth scope, such as for teams and projects (required) - :param V1alpha2ResourceClassParameters body: (required) + :param V1beta2ResourceClaim body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -8946,7 +4786,7 @@ def replace_namespaced_resource_class_parameters_with_http_info(self, name, name number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClassParameters, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaim, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -8975,22 +4815,22 @@ def replace_namespaced_resource_class_parameters_with_http_info(self, name, name if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_namespaced_resource_class_parameters" % key + " to method replace_namespaced_resource_claim_status" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_class_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim_status`") # noqa: E501 # verify the required parameter 'namespace' is set if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 local_var_params['namespace'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_class_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim_status`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_class_parameters`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim_status`") # noqa: E501 collection_formats = {} @@ -9020,20 +4860,20 @@ def replace_namespaced_resource_class_parameters_with_http_info(self, name, name body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/namespaces/{namespace}/resourceclassparameters/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaims/{name}/status', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClassParameters', # noqa: E501 + response_type='V1beta2ResourceClaim', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -9041,18 +4881,19 @@ def replace_namespaced_resource_class_parameters_with_http_info(self, name, name _request_timeout=local_var_params.get('_request_timeout'), collection_formats=collection_formats) - def replace_resource_class(self, name, body, **kwargs): # noqa: E501 - """replace_resource_class # noqa: E501 + def replace_namespaced_resource_claim_template(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_resource_claim_template # noqa: E501 - replace the specified ResourceClass # noqa: E501 + replace the specified ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_resource_class(name, body, async_req=True) + >>> thread = api.replace_namespaced_resource_claim_template(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) - :param V1alpha2ResourceClass body: (required) + :param str name: name of the ResourceClaimTemplate (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param V1beta2ResourceClaimTemplate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -9064,25 +4905,26 @@ def replace_resource_class(self, name, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceClass + :return: V1beta2ResourceClaimTemplate If the method is called asynchronously, returns the request thread. """ kwargs['_return_http_data_only'] = True - return self.replace_resource_class_with_http_info(name, body, **kwargs) # noqa: E501 + return self.replace_namespaced_resource_claim_template_with_http_info(name, namespace, body, **kwargs) # noqa: E501 - def replace_resource_class_with_http_info(self, name, body, **kwargs): # noqa: E501 - """replace_resource_class # noqa: E501 + def replace_namespaced_resource_claim_template_with_http_info(self, name, namespace, body, **kwargs): # noqa: E501 + """replace_namespaced_resource_claim_template # noqa: E501 - replace the specified ResourceClass # noqa: E501 + replace the specified ResourceClaimTemplate # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True - >>> thread = api.replace_resource_class_with_http_info(name, body, async_req=True) + >>> thread = api.replace_namespaced_resource_claim_template_with_http_info(name, namespace, body, async_req=True) >>> result = thread.get() :param async_req bool: execute request asynchronously - :param str name: name of the ResourceClass (required) - :param V1alpha2ResourceClass body: (required) + :param str name: name of the ResourceClaimTemplate (required) + :param str namespace: object name and auth scope, such as for teams and projects (required) + :param V1beta2ResourceClaimTemplate body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -9096,7 +4938,7 @@ def replace_resource_class_with_http_info(self, name, body, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceClass, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceClaimTemplate, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -9105,6 +4947,7 @@ def replace_resource_class_with_http_info(self, name, body, **kwargs): # noqa: all_params = [ 'name', + 'namespace', 'body', 'pretty', 'dry_run', @@ -9124,24 +4967,30 @@ def replace_resource_class_with_http_info(self, name, body, **kwargs): # noqa: if key not in all_params: raise ApiTypeError( "Got an unexpected keyword argument '%s'" - " to method replace_resource_class" % key + " to method replace_namespaced_resource_claim_template" % key ) local_var_params[key] = val del local_var_params['kwargs'] # verify the required parameter 'name' is set if self.api_client.client_side_validation and ('name' not in local_var_params or # noqa: E501 local_var_params['name'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `name` when calling `replace_resource_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `name` when calling `replace_namespaced_resource_claim_template`") # noqa: E501 + # verify the required parameter 'namespace' is set + if self.api_client.client_side_validation and ('namespace' not in local_var_params or # noqa: E501 + local_var_params['namespace'] is None): # noqa: E501 + raise ApiValueError("Missing the required parameter `namespace` when calling `replace_namespaced_resource_claim_template`") # noqa: E501 # verify the required parameter 'body' is set if self.api_client.client_side_validation and ('body' not in local_var_params or # noqa: E501 local_var_params['body'] is None): # noqa: E501 - raise ApiValueError("Missing the required parameter `body` when calling `replace_resource_class`") # noqa: E501 + raise ApiValueError("Missing the required parameter `body` when calling `replace_namespaced_resource_claim_template`") # noqa: E501 collection_formats = {} path_params = {} if 'name' in local_var_params: path_params['name'] = local_var_params['name'] # noqa: E501 + if 'namespace' in local_var_params: + path_params['namespace'] = local_var_params['namespace'] # noqa: E501 query_params = [] if 'pretty' in local_var_params and local_var_params['pretty'] is not None: # noqa: E501 @@ -9163,20 +5012,20 @@ def replace_resource_class_with_http_info(self, name, body, **kwargs): # noqa: body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceclasses/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/namespaces/{namespace}/resourceclaimtemplates/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceClass', # noqa: E501 + response_type='V1beta2ResourceClaimTemplate', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 @@ -9195,7 +5044,7 @@ def replace_resource_slice(self, name, body, **kwargs): # noqa: E501 :param async_req bool: execute request asynchronously :param str name: name of the ResourceSlice (required) - :param V1alpha2ResourceSlice body: (required) + :param V1beta2ResourceSlice body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -9207,7 +5056,7 @@ def replace_resource_slice(self, name, body, **kwargs): # noqa: E501 number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: V1alpha2ResourceSlice + :return: V1beta2ResourceSlice If the method is called asynchronously, returns the request thread. """ @@ -9225,7 +5074,7 @@ def replace_resource_slice_with_http_info(self, name, body, **kwargs): # noqa: :param async_req bool: execute request asynchronously :param str name: name of the ResourceSlice (required) - :param V1alpha2ResourceSlice body: (required) + :param V1beta2ResourceSlice body: (required) :param str pretty: If 'true', then the output is pretty printed. Defaults to 'false' unless the user-agent indicates a browser or command-line HTTP tool (curl and wget). :param str dry_run: When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed :param str field_manager: fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. @@ -9239,7 +5088,7 @@ def replace_resource_slice_with_http_info(self, name, body, **kwargs): # noqa: number provided, it will be total request timeout. It can also be a pair (tuple) of (connection, read) timeouts. - :return: tuple(V1alpha2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) + :return: tuple(V1beta2ResourceSlice, status_code(int), headers(HTTPHeaderDict)) If the method is called asynchronously, returns the request thread. """ @@ -9306,20 +5155,20 @@ def replace_resource_slice_with_http_info(self, name, body, **kwargs): # noqa: body_params = local_var_params['body'] # HTTP header `Accept` header_params['Accept'] = self.api_client.select_header_accept( - ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf']) # noqa: E501 + ['application/json', 'application/yaml', 'application/vnd.kubernetes.protobuf', 'application/cbor']) # noqa: E501 # Authentication setting auth_settings = ['BearerToken'] # noqa: E501 return self.api_client.call_api( - '/apis/resource.k8s.io/v1alpha2/resourceslices/{name}', 'PUT', + '/apis/resource.k8s.io/v1beta2/resourceslices/{name}', 'PUT', path_params, query_params, header_params, body=body_params, post_params=form_params, files=local_var_files, - response_type='V1alpha2ResourceSlice', # noqa: E501 + response_type='V1beta2ResourceSlice', # noqa: E501 auth_settings=auth_settings, async_req=local_var_params.get('async_req'), _return_http_data_only=local_var_params.get('_return_http_data_only'), # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/api/scheduling_api.py b/contrib/python/kubernetes/kubernetes/client/api/scheduling_api.py index 10f5271656c8..d24032c23f1f 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/scheduling_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/scheduling_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/scheduling_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/scheduling_v1_api.py index f67ba99ef5a6..6e38f1e21f32 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/scheduling_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/scheduling_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/storage_api.py b/contrib/python/kubernetes/kubernetes/client/api/storage_api.py index 3a5250093f22..d40cee988bfc 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/storage_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/storage_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/storage_v1_api.py b/contrib/python/kubernetes/kubernetes/client/api/storage_v1_api.py index 23ee903ef73a..984e488d988e 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/storage_v1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/storage_v1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/storage_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/storage_v1alpha1_api.py index 0075c1960aae..1b8b6bf997b6 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/storage_v1alpha1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/storage_v1alpha1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/storage_v1beta1_api.py b/contrib/python/kubernetes/kubernetes/client/api/storage_v1beta1_api.py index 80337f36be2e..c52d22cc7ae6 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/storage_v1beta1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/storage_v1beta1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/storagemigration_api.py b/contrib/python/kubernetes/kubernetes/client/api/storagemigration_api.py index 64a302ae0f2c..52b944af0a8b 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/storagemigration_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/storagemigration_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/storagemigration_v1alpha1_api.py b/contrib/python/kubernetes/kubernetes/client/api/storagemigration_v1alpha1_api.py index 14d51134bea4..9d40acef98f6 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/storagemigration_v1alpha1_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/storagemigration_v1alpha1_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api/version_api.py b/contrib/python/kubernetes/kubernetes/client/api/version_api.py index d8cee530b20e..47f385e62b75 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/version_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/version_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -39,7 +39,7 @@ def __init__(self, api_client=None): def get_code(self, **kwargs): # noqa: E501 """get_code # noqa: E501 - get the code version # noqa: E501 + get the version information for this server # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.get_code(async_req=True) @@ -63,7 +63,7 @@ def get_code(self, **kwargs): # noqa: E501 def get_code_with_http_info(self, **kwargs): # noqa: E501 """get_code # noqa: E501 - get the code version # noqa: E501 + get the version information for this server # noqa: E501 This method makes a synchronous HTTP request by default. To make an asynchronous HTTP request, please pass async_req=True >>> thread = api.get_code_with_http_info(async_req=True) diff --git a/contrib/python/kubernetes/kubernetes/client/api/well_known_api.py b/contrib/python/kubernetes/kubernetes/client/api/well_known_api.py index ab4c5370ea9e..23acb791fa93 100644 --- a/contrib/python/kubernetes/kubernetes/client/api/well_known_api.py +++ b/contrib/python/kubernetes/kubernetes/client/api/well_known_api.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/api_client.py b/contrib/python/kubernetes/kubernetes/client/api_client.py index f77e97c7a980..fff2e820a1af 100644 --- a/contrib/python/kubernetes/kubernetes/client/api_client.py +++ b/contrib/python/kubernetes/kubernetes/client/api_client.py @@ -4,7 +4,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -78,7 +78,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None, self.default_headers[header_name] = header_value self.cookie = cookie # Set default User-Agent. - self.user_agent = 'OpenAPI-Generator/32.0.1/python' + self.user_agent = 'OpenAPI-Generator/33.1.0/python' self.client_side_validation = configuration.client_side_validation def __enter__(self): diff --git a/contrib/python/kubernetes/kubernetes/client/configuration.py b/contrib/python/kubernetes/kubernetes/client/configuration.py index 1ad1c8ebfae0..67ea667dc6cb 100644 --- a/contrib/python/kubernetes/kubernetes/client/configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -353,8 +353,8 @@ def to_debug_report(self): return "Python SDK Debug Report:\n"\ "OS: {env}\n"\ "Python Version: {pyversion}\n"\ - "Version of the API: release-1.32\n"\ - "SDK Package Version: 32.0.1".\ + "Version of the API: release-1.33\n"\ + "SDK Package Version: 33.1.0".\ format(env=sys.platform, pyversion=sys.version) def get_host_settings(self): diff --git a/contrib/python/kubernetes/kubernetes/client/exceptions.py b/contrib/python/kubernetes/kubernetes/client/exceptions.py index cea521294873..092ba0c6aa98 100644 --- a/contrib/python/kubernetes/kubernetes/client/exceptions.py +++ b/contrib/python/kubernetes/kubernetes/client/exceptions.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/__init__.py b/contrib/python/kubernetes/kubernetes/client/models/__init__.py index d8adadd13aee..880798fbaaa7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/__init__.py +++ b/contrib/python/kubernetes/kubernetes/client/models/__init__.py @@ -6,7 +6,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -169,6 +169,7 @@ from kubernetes.client.models.v1_flow_schema_list import V1FlowSchemaList from kubernetes.client.models.v1_flow_schema_spec import V1FlowSchemaSpec from kubernetes.client.models.v1_flow_schema_status import V1FlowSchemaStatus +from kubernetes.client.models.v1_for_node import V1ForNode from kubernetes.client.models.v1_for_zone import V1ForZone from kubernetes.client.models.v1_gce_persistent_disk_volume_source import V1GCEPersistentDiskVolumeSource from kubernetes.client.models.v1_grpc_action import V1GRPCAction @@ -188,6 +189,9 @@ from kubernetes.client.models.v1_host_alias import V1HostAlias from kubernetes.client.models.v1_host_ip import V1HostIP from kubernetes.client.models.v1_host_path_volume_source import V1HostPathVolumeSource +from kubernetes.client.models.v1_ip_address import V1IPAddress +from kubernetes.client.models.v1_ip_address_list import V1IPAddressList +from kubernetes.client.models.v1_ip_address_spec import V1IPAddressSpec from kubernetes.client.models.v1_ip_block import V1IPBlock from kubernetes.client.models.v1_iscsi_persistent_volume_source import V1ISCSIPersistentVolumeSource from kubernetes.client.models.v1_iscsi_volume_source import V1ISCSIVolumeSource @@ -273,6 +277,7 @@ from kubernetes.client.models.v1_node_selector_term import V1NodeSelectorTerm from kubernetes.client.models.v1_node_spec import V1NodeSpec from kubernetes.client.models.v1_node_status import V1NodeStatus +from kubernetes.client.models.v1_node_swap_status import V1NodeSwapStatus from kubernetes.client.models.v1_node_system_info import V1NodeSystemInfo from kubernetes.client.models.v1_non_resource_attributes import V1NonResourceAttributes from kubernetes.client.models.v1_non_resource_policy_rule import V1NonResourcePolicyRule @@ -284,6 +289,7 @@ from kubernetes.client.models.v1_owner_reference import V1OwnerReference from kubernetes.client.models.v1_param_kind import V1ParamKind from kubernetes.client.models.v1_param_ref import V1ParamRef +from kubernetes.client.models.v1_parent_reference import V1ParentReference from kubernetes.client.models.v1_persistent_volume import V1PersistentVolume from kubernetes.client.models.v1_persistent_volume_claim import V1PersistentVolumeClaim from kubernetes.client.models.v1_persistent_volume_claim_condition import V1PersistentVolumeClaimCondition @@ -409,6 +415,10 @@ from kubernetes.client.models.v1_service_account_subject import V1ServiceAccountSubject from kubernetes.client.models.v1_service_account_token_projection import V1ServiceAccountTokenProjection from kubernetes.client.models.v1_service_backend_port import V1ServiceBackendPort +from kubernetes.client.models.v1_service_cidr import V1ServiceCIDR +from kubernetes.client.models.v1_service_cidr_list import V1ServiceCIDRList +from kubernetes.client.models.v1_service_cidr_spec import V1ServiceCIDRSpec +from kubernetes.client.models.v1_service_cidr_status import V1ServiceCIDRStatus from kubernetes.client.models.v1_service_list import V1ServiceList from kubernetes.client.models.v1_service_port import V1ServicePort from kubernetes.client.models.v1_service_spec import V1ServiceSpec @@ -524,6 +534,8 @@ from kubernetes.client.models.v1alpha3_allocation_result import V1alpha3AllocationResult from kubernetes.client.models.v1alpha3_basic_device import V1alpha3BasicDevice from kubernetes.client.models.v1alpha3_cel_device_selector import V1alpha3CELDeviceSelector +from kubernetes.client.models.v1alpha3_counter import V1alpha3Counter +from kubernetes.client.models.v1alpha3_counter_set import V1alpha3CounterSet from kubernetes.client.models.v1alpha3_device import V1alpha3Device from kubernetes.client.models.v1alpha3_device_allocation_configuration import V1alpha3DeviceAllocationConfiguration from kubernetes.client.models.v1alpha3_device_allocation_result import V1alpha3DeviceAllocationResult @@ -535,9 +547,17 @@ from kubernetes.client.models.v1alpha3_device_class_list import V1alpha3DeviceClassList from kubernetes.client.models.v1alpha3_device_class_spec import V1alpha3DeviceClassSpec from kubernetes.client.models.v1alpha3_device_constraint import V1alpha3DeviceConstraint +from kubernetes.client.models.v1alpha3_device_counter_consumption import V1alpha3DeviceCounterConsumption from kubernetes.client.models.v1alpha3_device_request import V1alpha3DeviceRequest from kubernetes.client.models.v1alpha3_device_request_allocation_result import V1alpha3DeviceRequestAllocationResult from kubernetes.client.models.v1alpha3_device_selector import V1alpha3DeviceSelector +from kubernetes.client.models.v1alpha3_device_sub_request import V1alpha3DeviceSubRequest +from kubernetes.client.models.v1alpha3_device_taint import V1alpha3DeviceTaint +from kubernetes.client.models.v1alpha3_device_taint_rule import V1alpha3DeviceTaintRule +from kubernetes.client.models.v1alpha3_device_taint_rule_list import V1alpha3DeviceTaintRuleList +from kubernetes.client.models.v1alpha3_device_taint_rule_spec import V1alpha3DeviceTaintRuleSpec +from kubernetes.client.models.v1alpha3_device_taint_selector import V1alpha3DeviceTaintSelector +from kubernetes.client.models.v1alpha3_device_toleration import V1alpha3DeviceToleration from kubernetes.client.models.v1alpha3_network_device_data import V1alpha3NetworkDeviceData from kubernetes.client.models.v1alpha3_opaque_device_configuration import V1alpha3OpaqueDeviceConfiguration from kubernetes.client.models.v1alpha3_resource_claim import V1alpha3ResourceClaim @@ -557,6 +577,11 @@ from kubernetes.client.models.v1beta1_audit_annotation import V1beta1AuditAnnotation from kubernetes.client.models.v1beta1_basic_device import V1beta1BasicDevice from kubernetes.client.models.v1beta1_cel_device_selector import V1beta1CELDeviceSelector +from kubernetes.client.models.v1beta1_cluster_trust_bundle import V1beta1ClusterTrustBundle +from kubernetes.client.models.v1beta1_cluster_trust_bundle_list import V1beta1ClusterTrustBundleList +from kubernetes.client.models.v1beta1_cluster_trust_bundle_spec import V1beta1ClusterTrustBundleSpec +from kubernetes.client.models.v1beta1_counter import V1beta1Counter +from kubernetes.client.models.v1beta1_counter_set import V1beta1CounterSet from kubernetes.client.models.v1beta1_device import V1beta1Device from kubernetes.client.models.v1beta1_device_allocation_configuration import V1beta1DeviceAllocationConfiguration from kubernetes.client.models.v1beta1_device_allocation_result import V1beta1DeviceAllocationResult @@ -569,13 +594,20 @@ from kubernetes.client.models.v1beta1_device_class_list import V1beta1DeviceClassList from kubernetes.client.models.v1beta1_device_class_spec import V1beta1DeviceClassSpec from kubernetes.client.models.v1beta1_device_constraint import V1beta1DeviceConstraint +from kubernetes.client.models.v1beta1_device_counter_consumption import V1beta1DeviceCounterConsumption from kubernetes.client.models.v1beta1_device_request import V1beta1DeviceRequest from kubernetes.client.models.v1beta1_device_request_allocation_result import V1beta1DeviceRequestAllocationResult from kubernetes.client.models.v1beta1_device_selector import V1beta1DeviceSelector +from kubernetes.client.models.v1beta1_device_sub_request import V1beta1DeviceSubRequest +from kubernetes.client.models.v1beta1_device_taint import V1beta1DeviceTaint +from kubernetes.client.models.v1beta1_device_toleration import V1beta1DeviceToleration from kubernetes.client.models.v1beta1_expression_warning import V1beta1ExpressionWarning from kubernetes.client.models.v1beta1_ip_address import V1beta1IPAddress from kubernetes.client.models.v1beta1_ip_address_list import V1beta1IPAddressList from kubernetes.client.models.v1beta1_ip_address_spec import V1beta1IPAddressSpec +from kubernetes.client.models.v1beta1_lease_candidate import V1beta1LeaseCandidate +from kubernetes.client.models.v1beta1_lease_candidate_list import V1beta1LeaseCandidateList +from kubernetes.client.models.v1beta1_lease_candidate_spec import V1beta1LeaseCandidateSpec from kubernetes.client.models.v1beta1_match_condition import V1beta1MatchCondition from kubernetes.client.models.v1beta1_match_resources import V1beta1MatchResources from kubernetes.client.models.v1beta1_named_rule_with_operations import V1beta1NamedRuleWithOperations @@ -596,8 +628,6 @@ from kubernetes.client.models.v1beta1_resource_slice import V1beta1ResourceSlice from kubernetes.client.models.v1beta1_resource_slice_list import V1beta1ResourceSliceList from kubernetes.client.models.v1beta1_resource_slice_spec import V1beta1ResourceSliceSpec -from kubernetes.client.models.v1beta1_self_subject_review import V1beta1SelfSubjectReview -from kubernetes.client.models.v1beta1_self_subject_review_status import V1beta1SelfSubjectReviewStatus from kubernetes.client.models.v1beta1_service_cidr import V1beta1ServiceCIDR from kubernetes.client.models.v1beta1_service_cidr_list import V1beta1ServiceCIDRList from kubernetes.client.models.v1beta1_service_cidr_spec import V1beta1ServiceCIDRSpec @@ -614,6 +644,45 @@ from kubernetes.client.models.v1beta1_variable import V1beta1Variable from kubernetes.client.models.v1beta1_volume_attributes_class import V1beta1VolumeAttributesClass from kubernetes.client.models.v1beta1_volume_attributes_class_list import V1beta1VolumeAttributesClassList +from kubernetes.client.models.v1beta2_allocated_device_status import V1beta2AllocatedDeviceStatus +from kubernetes.client.models.v1beta2_allocation_result import V1beta2AllocationResult +from kubernetes.client.models.v1beta2_cel_device_selector import V1beta2CELDeviceSelector +from kubernetes.client.models.v1beta2_counter import V1beta2Counter +from kubernetes.client.models.v1beta2_counter_set import V1beta2CounterSet +from kubernetes.client.models.v1beta2_device import V1beta2Device +from kubernetes.client.models.v1beta2_device_allocation_configuration import V1beta2DeviceAllocationConfiguration +from kubernetes.client.models.v1beta2_device_allocation_result import V1beta2DeviceAllocationResult +from kubernetes.client.models.v1beta2_device_attribute import V1beta2DeviceAttribute +from kubernetes.client.models.v1beta2_device_capacity import V1beta2DeviceCapacity +from kubernetes.client.models.v1beta2_device_claim import V1beta2DeviceClaim +from kubernetes.client.models.v1beta2_device_claim_configuration import V1beta2DeviceClaimConfiguration +from kubernetes.client.models.v1beta2_device_class import V1beta2DeviceClass +from kubernetes.client.models.v1beta2_device_class_configuration import V1beta2DeviceClassConfiguration +from kubernetes.client.models.v1beta2_device_class_list import V1beta2DeviceClassList +from kubernetes.client.models.v1beta2_device_class_spec import V1beta2DeviceClassSpec +from kubernetes.client.models.v1beta2_device_constraint import V1beta2DeviceConstraint +from kubernetes.client.models.v1beta2_device_counter_consumption import V1beta2DeviceCounterConsumption +from kubernetes.client.models.v1beta2_device_request import V1beta2DeviceRequest +from kubernetes.client.models.v1beta2_device_request_allocation_result import V1beta2DeviceRequestAllocationResult +from kubernetes.client.models.v1beta2_device_selector import V1beta2DeviceSelector +from kubernetes.client.models.v1beta2_device_sub_request import V1beta2DeviceSubRequest +from kubernetes.client.models.v1beta2_device_taint import V1beta2DeviceTaint +from kubernetes.client.models.v1beta2_device_toleration import V1beta2DeviceToleration +from kubernetes.client.models.v1beta2_exact_device_request import V1beta2ExactDeviceRequest +from kubernetes.client.models.v1beta2_network_device_data import V1beta2NetworkDeviceData +from kubernetes.client.models.v1beta2_opaque_device_configuration import V1beta2OpaqueDeviceConfiguration +from kubernetes.client.models.v1beta2_resource_claim import V1beta2ResourceClaim +from kubernetes.client.models.v1beta2_resource_claim_consumer_reference import V1beta2ResourceClaimConsumerReference +from kubernetes.client.models.v1beta2_resource_claim_list import V1beta2ResourceClaimList +from kubernetes.client.models.v1beta2_resource_claim_spec import V1beta2ResourceClaimSpec +from kubernetes.client.models.v1beta2_resource_claim_status import V1beta2ResourceClaimStatus +from kubernetes.client.models.v1beta2_resource_claim_template import V1beta2ResourceClaimTemplate +from kubernetes.client.models.v1beta2_resource_claim_template_list import V1beta2ResourceClaimTemplateList +from kubernetes.client.models.v1beta2_resource_claim_template_spec import V1beta2ResourceClaimTemplateSpec +from kubernetes.client.models.v1beta2_resource_pool import V1beta2ResourcePool +from kubernetes.client.models.v1beta2_resource_slice import V1beta2ResourceSlice +from kubernetes.client.models.v1beta2_resource_slice_list import V1beta2ResourceSliceList +from kubernetes.client.models.v1beta2_resource_slice_spec import V1beta2ResourceSliceSpec from kubernetes.client.models.v2_container_resource_metric_source import V2ContainerResourceMetricSource from kubernetes.client.models.v2_container_resource_metric_status import V2ContainerResourceMetricStatus from kubernetes.client.models.v2_cross_version_object_reference import V2CrossVersionObjectReference diff --git a/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_service_reference.py b/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_service_reference.py index 7aada42b2106..7db203b984cb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_service_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_service_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_webhook_client_config.py b/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_webhook_client_config.py index 8d2cd9abe702..e5180773d32f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_webhook_client_config.py +++ b/contrib/python/kubernetes/kubernetes/client/models/admissionregistration_v1_webhook_client_config.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_service_reference.py b/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_service_reference.py index e2d4381103e8..48bdf140458e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_service_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_service_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_webhook_client_config.py b/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_webhook_client_config.py index 4caa1b38578a..785bfd10141f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_webhook_client_config.py +++ b/contrib/python/kubernetes/kubernetes/client/models/apiextensions_v1_webhook_client_config.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/apiregistration_v1_service_reference.py b/contrib/python/kubernetes/kubernetes/client/models/apiregistration_v1_service_reference.py index df7ff4ec78f8..da8a9ba2f401 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/apiregistration_v1_service_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/apiregistration_v1_service_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/authentication_v1_token_request.py b/contrib/python/kubernetes/kubernetes/client/models/authentication_v1_token_request.py index 2291d70c3357..6837bf50b8e9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/authentication_v1_token_request.py +++ b/contrib/python/kubernetes/kubernetes/client/models/authentication_v1_token_request.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/core_v1_endpoint_port.py b/contrib/python/kubernetes/kubernetes/client/models/core_v1_endpoint_port.py index 22100f6e91e4..4a27a90cbe2c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/core_v1_endpoint_port.py +++ b/contrib/python/kubernetes/kubernetes/client/models/core_v1_endpoint_port.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/core_v1_event.py b/contrib/python/kubernetes/kubernetes/client/models/core_v1_event.py index 0bd8c0292d52..5f33a5249d3b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/core_v1_event.py +++ b/contrib/python/kubernetes/kubernetes/client/models/core_v1_event.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_list.py b/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_list.py index 99dd1b70d115..122c01523e84 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_series.py b/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_series.py index 8b6bb71f95f5..710386c71fa6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_series.py +++ b/contrib/python/kubernetes/kubernetes/client/models/core_v1_event_series.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/discovery_v1_endpoint_port.py b/contrib/python/kubernetes/kubernetes/client/models/discovery_v1_endpoint_port.py index 7cf1a420ec9d..18e7e69547c4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/discovery_v1_endpoint_port.py +++ b/contrib/python/kubernetes/kubernetes/client/models/discovery_v1_endpoint_port.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -117,7 +117,7 @@ def name(self, name): def port(self): """Gets the port of this DiscoveryV1EndpointPort. # noqa: E501 - port represents the port number of the endpoint. If this is not specified, ports are not restricted and must be interpreted in the context of the specific consumer. # noqa: E501 + port represents the port number of the endpoint. If the EndpointSlice is derived from a Kubernetes service, this must be set to the service's target port. EndpointSlices used for other purposes may have a nil port. # noqa: E501 :return: The port of this DiscoveryV1EndpointPort. # noqa: E501 :rtype: int @@ -128,7 +128,7 @@ def port(self): def port(self, port): """Sets the port of this DiscoveryV1EndpointPort. - port represents the port number of the endpoint. If this is not specified, ports are not restricted and must be interpreted in the context of the specific consumer. # noqa: E501 + port represents the port number of the endpoint. If the EndpointSlice is derived from a Kubernetes service, this must be set to the service's target port. EndpointSlices used for other purposes may have a nil port. # noqa: E501 :param port: The port of this DiscoveryV1EndpointPort. # noqa: E501 :type: int diff --git a/contrib/python/kubernetes/kubernetes/client/models/events_v1_event.py b/contrib/python/kubernetes/kubernetes/client/models/events_v1_event.py index 3810b81bfc1f..f4acb4b1be12 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/events_v1_event.py +++ b/contrib/python/kubernetes/kubernetes/client/models/events_v1_event.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_list.py b/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_list.py index 8f5041cf6beb..257a9e0b0008 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_series.py b/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_series.py index 86ef4c0ea780..aea315f3074b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_series.py +++ b/contrib/python/kubernetes/kubernetes/client/models/events_v1_event_series.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/flowcontrol_v1_subject.py b/contrib/python/kubernetes/kubernetes/client/models/flowcontrol_v1_subject.py index 1b003c02385d..fb12f8ef1019 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/flowcontrol_v1_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/flowcontrol_v1_subject.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/rbac_v1_subject.py b/contrib/python/kubernetes/kubernetes/client/models/rbac_v1_subject.py index fe6e285925fa..273ed70e6e57 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/rbac_v1_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/rbac_v1_subject.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/storage_v1_token_request.py b/contrib/python/kubernetes/kubernetes/client/models/storage_v1_token_request.py index 25b3e88779d5..a01de4f32650 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/storage_v1_token_request.py +++ b/contrib/python/kubernetes/kubernetes/client/models/storage_v1_token_request.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_affinity.py b/contrib/python/kubernetes/kubernetes/client/models/v1_affinity.py index a2bb84b36617..fd2c8cc3d07b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_affinity.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_affinity.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_aggregation_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_aggregation_rule.py index cec72ff20435..3a62103499a9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_aggregation_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_aggregation_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_group.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_group.py index f8c836b7db05..4df686be408e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_group.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_group.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_group_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_group_list.py index 799d4eb47e5a..3bc8db3f35af 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_group_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_group_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource.py index e1343d26dacd..68965456725d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource_list.py index 265d97150e3a..bf366b714ee4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_resource_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service.py index 402ecaa86f8d..52ef82feee12 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_condition.py index 908966f5ca78..90cc7df604ab 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_list.py index 5b167e8210ef..f1d2cc306ff7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_spec.py index 38ef27f4545b..ea1d080a4083 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_status.py index 99472e054cbd..80a5c1d2f9bc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_service_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_api_versions.py b/contrib/python/kubernetes/kubernetes/client/models/v1_api_versions.py index 6274486ec9fa..3e0ac08152b8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_api_versions.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_api_versions.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_app_armor_profile.py b/contrib/python/kubernetes/kubernetes/client/models/v1_app_armor_profile.py index 557da358abd7..5d8859c703b5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_app_armor_profile.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_app_armor_profile.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_attached_volume.py b/contrib/python/kubernetes/kubernetes/client/models/v1_attached_volume.py index fe8fcf864b97..695ac38191ef 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_attached_volume.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_attached_volume.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_audit_annotation.py b/contrib/python/kubernetes/kubernetes/client/models/v1_audit_annotation.py index f4a4db6ab43b..d5efa68c503b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_audit_annotation.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_audit_annotation.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_aws_elastic_block_store_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_aws_elastic_block_store_volume_source.py index bc8520f72b6d..8a7b0bfade3a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_aws_elastic_block_store_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_aws_elastic_block_store_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_azure_disk_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_azure_disk_volume_source.py index d063df4742d3..15d9320325e4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_azure_disk_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_azure_disk_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_persistent_volume_source.py index 1052c172d487..4bdf9420de5d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_volume_source.py index db7eb875b9c9..6decdda53e1d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_azure_file_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_binding.py b/contrib/python/kubernetes/kubernetes/client/models/v1_binding.py index 911c9c298671..93e56ec06d5e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_binding.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_binding.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_bound_object_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_bound_object_reference.py index c82617bf662f..4c24053bb8eb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_bound_object_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_bound_object_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_capabilities.py b/contrib/python/kubernetes/kubernetes/client/models/v1_capabilities.py index 3420c0e64854..797457692b97 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_capabilities.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_capabilities.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_persistent_volume_source.py index 6d4867f372f4..b6ab2f59bec4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_volume_source.py index dec7b6307fba..a68767ec4bdd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ceph_fs_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request.py b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request.py index 1a2fa74aa93e..0f2d92d89dd3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_condition.py index 61b236620813..1ee215aff562 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_list.py index b470f4c8b634..30958cb0bf6a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_spec.py index cac57e07ccf6..033e10d8cfbe 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_status.py index cd5d90caafbd..8923ac5881b3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_certificate_signing_request_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_persistent_volume_source.py index d0e19db86d6e..5a6945537b3b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_volume_source.py index 24e92c1502d9..1787f00066c3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cinder_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_claim_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_claim_source.py deleted file mode 100644 index 7c7c417766ac..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_claim_source.py +++ /dev/null @@ -1,150 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1ClaimSource(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'resource_claim_name': 'str', - 'resource_claim_template_name': 'str' - } - - attribute_map = { - 'resource_claim_name': 'resourceClaimName', - 'resource_claim_template_name': 'resourceClaimTemplateName' - } - - def __init__(self, resource_claim_name=None, resource_claim_template_name=None, local_vars_configuration=None): # noqa: E501 - """V1ClaimSource - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._resource_claim_name = None - self._resource_claim_template_name = None - self.discriminator = None - - if resource_claim_name is not None: - self.resource_claim_name = resource_claim_name - if resource_claim_template_name is not None: - self.resource_claim_template_name = resource_claim_template_name - - @property - def resource_claim_name(self): - """Gets the resource_claim_name of this V1ClaimSource. # noqa: E501 - - ResourceClaimName is the name of a ResourceClaim object in the same namespace as this pod. # noqa: E501 - - :return: The resource_claim_name of this V1ClaimSource. # noqa: E501 - :rtype: str - """ - return self._resource_claim_name - - @resource_claim_name.setter - def resource_claim_name(self, resource_claim_name): - """Sets the resource_claim_name of this V1ClaimSource. - - ResourceClaimName is the name of a ResourceClaim object in the same namespace as this pod. # noqa: E501 - - :param resource_claim_name: The resource_claim_name of this V1ClaimSource. # noqa: E501 - :type: str - """ - - self._resource_claim_name = resource_claim_name - - @property - def resource_claim_template_name(self): - """Gets the resource_claim_template_name of this V1ClaimSource. # noqa: E501 - - ResourceClaimTemplateName is the name of a ResourceClaimTemplate object in the same namespace as this pod. The template will be used to create a new ResourceClaim, which will be bound to this pod. When this pod is deleted, the ResourceClaim will also be deleted. The pod name and resource name, along with a generated component, will be used to form a unique name for the ResourceClaim, which will be recorded in pod.status.resourceClaimStatuses. This field is immutable and no changes will be made to the corresponding ResourceClaim by the control plane after creating the ResourceClaim. # noqa: E501 - - :return: The resource_claim_template_name of this V1ClaimSource. # noqa: E501 - :rtype: str - """ - return self._resource_claim_template_name - - @resource_claim_template_name.setter - def resource_claim_template_name(self, resource_claim_template_name): - """Sets the resource_claim_template_name of this V1ClaimSource. - - ResourceClaimTemplateName is the name of a ResourceClaimTemplate object in the same namespace as this pod. The template will be used to create a new ResourceClaim, which will be bound to this pod. When this pod is deleted, the ResourceClaim will also be deleted. The pod name and resource name, along with a generated component, will be used to form a unique name for the ResourceClaim, which will be recorded in pod.status.resourceClaimStatuses. This field is immutable and no changes will be made to the corresponding ResourceClaim by the control plane after creating the ResourceClaim. # noqa: E501 - - :param resource_claim_template_name: The resource_claim_template_name of this V1ClaimSource. # noqa: E501 - :type: str - """ - - self._resource_claim_template_name = resource_claim_template_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1ClaimSource): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1ClaimSource): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_client_ip_config.py b/contrib/python/kubernetes/kubernetes/client/models/v1_client_ip_config.py index 2d3501e6b835..77148891e4ff 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_client_ip_config.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_client_ip_config.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role.py index 56233b10728e..63e93870bbd9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding.py index 45b46ab167be..77fd9c7aec83 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding_list.py index adf7df8c74ba..eacfed22c158 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_binding_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_list.py index a1c9e0b49f82..bce77c5eef38 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_role_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_trust_bundle_projection.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_trust_bundle_projection.py index 8b90e4f682d6..3b4006cbb911 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_trust_bundle_projection.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cluster_trust_bundle_projection.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_component_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_component_condition.py index 27cbb834eb09..2f7c3266732c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_component_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_component_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_component_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_component_status.py index 5a1c23ffb7b0..694a34989b5b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_component_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_component_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_component_status_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_component_status_list.py index bfea0dda3827..769ac891305f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_component_status_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_component_status_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_condition.py index e06f9aed9798..226eb76853f0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map.py index 76589f8755b4..9532f67f301f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_env_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_env_source.py index b9cb17a5c97b..fbe24f6b52c9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_env_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_env_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_key_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_key_selector.py index addd69b4fd48..9087a9df897a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_key_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_key_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_list.py index 3004767948aa..7e690e602a52 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_node_config_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_node_config_source.py index b7be3bc4ff13..358cfde24aaf 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_node_config_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_node_config_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_projection.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_projection.py index 6752cf0bf51d..3ad46f2b4d61 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_projection.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_projection.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_volume_source.py index c3ba143f3875..1f4fb52e745d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_config_map_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container.py index 9f026292b189..4b90e8c9ee4b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_image.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_image.py index 7823fff24e88..064c73dd26d6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_image.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_image.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_port.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_port.py index d2751618937f..384c88b414fb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_port.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_port.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_resize_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_resize_policy.py index 354b56264d3c..c23ffa2cbbba 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_resize_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_resize_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state.py index d3c1b8e4c8bf..0552659ab655 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_running.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_running.py index b01d40b72a45..39776202d3a7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_running.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_running.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_terminated.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_terminated.py index e95d3e04108f..1c21d8f33f68 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_terminated.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_terminated.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_waiting.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_waiting.py index 79438afee501..3d824d0bd781 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_waiting.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_state_waiting.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_status.py index 4807e0846092..c75863107dc6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -45,6 +45,7 @@ class V1ContainerStatus(object): 'restart_count': 'int', 'started': 'bool', 'state': 'V1ContainerState', + 'stop_signal': 'str', 'user': 'V1ContainerUser', 'volume_mounts': 'list[V1VolumeMountStatus]' } @@ -62,11 +63,12 @@ class V1ContainerStatus(object): 'restart_count': 'restartCount', 'started': 'started', 'state': 'state', + 'stop_signal': 'stopSignal', 'user': 'user', 'volume_mounts': 'volumeMounts' } - def __init__(self, allocated_resources=None, allocated_resources_status=None, container_id=None, image=None, image_id=None, last_state=None, name=None, ready=None, resources=None, restart_count=None, started=None, state=None, user=None, volume_mounts=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, allocated_resources=None, allocated_resources_status=None, container_id=None, image=None, image_id=None, last_state=None, name=None, ready=None, resources=None, restart_count=None, started=None, state=None, stop_signal=None, user=None, volume_mounts=None, local_vars_configuration=None): # noqa: E501 """V1ContainerStatus - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -84,6 +86,7 @@ def __init__(self, allocated_resources=None, allocated_resources_status=None, co self._restart_count = None self._started = None self._state = None + self._stop_signal = None self._user = None self._volume_mounts = None self.discriminator = None @@ -107,6 +110,8 @@ def __init__(self, allocated_resources=None, allocated_resources_status=None, co self.started = started if state is not None: self.state = state + if stop_signal is not None: + self.stop_signal = stop_signal if user is not None: self.user = user if volume_mounts is not None: @@ -392,6 +397,29 @@ def state(self, state): self._state = state + @property + def stop_signal(self): + """Gets the stop_signal of this V1ContainerStatus. # noqa: E501 + + StopSignal reports the effective stop signal for this container # noqa: E501 + + :return: The stop_signal of this V1ContainerStatus. # noqa: E501 + :rtype: str + """ + return self._stop_signal + + @stop_signal.setter + def stop_signal(self, stop_signal): + """Sets the stop_signal of this V1ContainerStatus. + + StopSignal reports the effective stop signal for this container # noqa: E501 + + :param stop_signal: The stop_signal of this V1ContainerStatus. # noqa: E501 + :type: str + """ + + self._stop_signal = stop_signal + @property def user(self): """Gets the user of this V1ContainerStatus. # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_container_user.py b/contrib/python/kubernetes/kubernetes/client/models/v1_container_user.py index e37895b87944..1c8fddf1b959 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_container_user.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_container_user.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision.py b/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision.py index ad3f7d17a0a4..617e94e64d94 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision_list.py index 574b3b1ae66e..3e186c4eaf87 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_controller_revision_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job.py index 4f82415c5298..66efc4ec1c25 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_list.py index b23dd439cdad..f62f7f8110b3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_spec.py index bb507750f05d..227695d547fa 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_status.py index a500426b75b2..02f75ac643df 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cron_job_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_cross_version_object_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_cross_version_object_reference.py index 721cedca984b..8b3c95463c1b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_cross_version_object_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_cross_version_object_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver.py index f3b59dbfb99a..1a9a1ae0bd22 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_list.py index 6591f6beacc0..6aafce560d51 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_spec.py index 332661c47935..ce94cd434835 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_driver_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -35,6 +35,7 @@ class V1CSIDriverSpec(object): openapi_types = { 'attach_required': 'bool', 'fs_group_policy': 'str', + 'node_allocatable_update_period_seconds': 'int', 'pod_info_on_mount': 'bool', 'requires_republish': 'bool', 'se_linux_mount': 'bool', @@ -46,6 +47,7 @@ class V1CSIDriverSpec(object): attribute_map = { 'attach_required': 'attachRequired', 'fs_group_policy': 'fsGroupPolicy', + 'node_allocatable_update_period_seconds': 'nodeAllocatableUpdatePeriodSeconds', 'pod_info_on_mount': 'podInfoOnMount', 'requires_republish': 'requiresRepublish', 'se_linux_mount': 'seLinuxMount', @@ -54,7 +56,7 @@ class V1CSIDriverSpec(object): 'volume_lifecycle_modes': 'volumeLifecycleModes' } - def __init__(self, attach_required=None, fs_group_policy=None, pod_info_on_mount=None, requires_republish=None, se_linux_mount=None, storage_capacity=None, token_requests=None, volume_lifecycle_modes=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, attach_required=None, fs_group_policy=None, node_allocatable_update_period_seconds=None, pod_info_on_mount=None, requires_republish=None, se_linux_mount=None, storage_capacity=None, token_requests=None, volume_lifecycle_modes=None, local_vars_configuration=None): # noqa: E501 """V1CSIDriverSpec - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -62,6 +64,7 @@ def __init__(self, attach_required=None, fs_group_policy=None, pod_info_on_mount self._attach_required = None self._fs_group_policy = None + self._node_allocatable_update_period_seconds = None self._pod_info_on_mount = None self._requires_republish = None self._se_linux_mount = None @@ -74,6 +77,8 @@ def __init__(self, attach_required=None, fs_group_policy=None, pod_info_on_mount self.attach_required = attach_required if fs_group_policy is not None: self.fs_group_policy = fs_group_policy + if node_allocatable_update_period_seconds is not None: + self.node_allocatable_update_period_seconds = node_allocatable_update_period_seconds if pod_info_on_mount is not None: self.pod_info_on_mount = pod_info_on_mount if requires_republish is not None: @@ -133,6 +138,29 @@ def fs_group_policy(self, fs_group_policy): self._fs_group_policy = fs_group_policy + @property + def node_allocatable_update_period_seconds(self): + """Gets the node_allocatable_update_period_seconds of this V1CSIDriverSpec. # noqa: E501 + + nodeAllocatableUpdatePeriodSeconds specifies the interval between periodic updates of the CSINode allocatable capacity for this driver. When set, both periodic updates and updates triggered by capacity-related failures are enabled. If not set, no updates occur (neither periodic nor upon detecting capacity-related failures), and the allocatable.count remains static. The minimum allowed value for this field is 10 seconds. This is an alpha feature and requires the MutableCSINodeAllocatableCount feature gate to be enabled. This field is mutable. # noqa: E501 + + :return: The node_allocatable_update_period_seconds of this V1CSIDriverSpec. # noqa: E501 + :rtype: int + """ + return self._node_allocatable_update_period_seconds + + @node_allocatable_update_period_seconds.setter + def node_allocatable_update_period_seconds(self, node_allocatable_update_period_seconds): + """Sets the node_allocatable_update_period_seconds of this V1CSIDriverSpec. + + nodeAllocatableUpdatePeriodSeconds specifies the interval between periodic updates of the CSINode allocatable capacity for this driver. When set, both periodic updates and updates triggered by capacity-related failures are enabled. If not set, no updates occur (neither periodic nor upon detecting capacity-related failures), and the allocatable.count remains static. The minimum allowed value for this field is 10 seconds. This is an alpha feature and requires the MutableCSINodeAllocatableCount feature gate to be enabled. This field is mutable. # noqa: E501 + + :param node_allocatable_update_period_seconds: The node_allocatable_update_period_seconds of this V1CSIDriverSpec. # noqa: E501 + :type: int + """ + + self._node_allocatable_update_period_seconds = node_allocatable_update_period_seconds + @property def pod_info_on_mount(self): """Gets the pod_info_on_mount of this V1CSIDriverSpec. # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node.py index b6726a0460f2..fba381f805bc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_driver.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_driver.py index 2e5410a4aac8..25ed8b050e8e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_driver.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_driver.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_list.py index 2a87412c6124..4a020d24ba91 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_spec.py index 37666fa007b4..90ba00a8630f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_node_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_persistent_volume_source.py index dee48ecad71e..3c0c0ba3b84b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity.py index 2df732d0105d..b6461ddce341 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity_list.py index 340a1f404326..da7261b10748 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_storage_capacity_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_volume_source.py index bff9f9a47d9f..c14fc155c783 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_csi_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_csi_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_column_definition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_column_definition.py index 16253d444713..2a6eff31c1e1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_column_definition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_column_definition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_conversion.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_conversion.py index b90e74e65ef5..6975d2c8477c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_conversion.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_conversion.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition.py index 5e66d8785bf5..84e3c2ecf72e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_condition.py index 6716a05e6f6f..b3e31695551a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_list.py index 8114037f96e8..55565e299954 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_names.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_names.py index 6a2b21970903..d580b8e019cc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_names.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_names.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_spec.py index 93f0748ef1df..1574d872a3b7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_status.py index a227af9a12b2..0a14052b568a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_version.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_version.py index ff2c8d071fd3..0651b329a46e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_version.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_definition_version.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresource_scale.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresource_scale.py index 190d568885b6..239c9a74583b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresource_scale.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresource_scale.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresources.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresources.py index 640ec38f934c..0c9b5bcd0aff 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresources.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_subresources.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_validation.py b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_validation.py index ba74eac0958c..365dfbc348ea 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_validation.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_custom_resource_validation.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_endpoint.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_endpoint.py index fb859084097c..98fe08d6e0ae 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_endpoint.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_endpoint.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set.py index b292bea25333..6c5df53b37a8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_condition.py index a1a7505a9eec..694e628d8154 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_list.py index defc0f29ea88..8447d344af62 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_spec.py index 67300561fe9d..583e6c4a20cd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_status.py index d2a5540adeb1..3801375abbf9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_update_strategy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_update_strategy.py index f8bd77d8375c..d286d9804804 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_update_strategy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_daemon_set_update_strategy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_delete_options.py b/contrib/python/kubernetes/kubernetes/client/models/v1_delete_options.py index b39bcd137cde..8bec1cfede0b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_delete_options.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_delete_options.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment.py b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment.py index f3eda2a95204..394ef641180a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_condition.py index 7e689022d545..a50dd01efa77 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_list.py index a59d79c63c10..4ac2249b2960 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_spec.py index 643637afbeb4..27ad72fa3d23 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_status.py index b4a95d4e92ac..bf72b772c5b5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -39,6 +39,7 @@ class V1DeploymentStatus(object): 'observed_generation': 'int', 'ready_replicas': 'int', 'replicas': 'int', + 'terminating_replicas': 'int', 'unavailable_replicas': 'int', 'updated_replicas': 'int' } @@ -50,11 +51,12 @@ class V1DeploymentStatus(object): 'observed_generation': 'observedGeneration', 'ready_replicas': 'readyReplicas', 'replicas': 'replicas', + 'terminating_replicas': 'terminatingReplicas', 'unavailable_replicas': 'unavailableReplicas', 'updated_replicas': 'updatedReplicas' } - def __init__(self, available_replicas=None, collision_count=None, conditions=None, observed_generation=None, ready_replicas=None, replicas=None, unavailable_replicas=None, updated_replicas=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, available_replicas=None, collision_count=None, conditions=None, observed_generation=None, ready_replicas=None, replicas=None, terminating_replicas=None, unavailable_replicas=None, updated_replicas=None, local_vars_configuration=None): # noqa: E501 """V1DeploymentStatus - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -66,6 +68,7 @@ def __init__(self, available_replicas=None, collision_count=None, conditions=Non self._observed_generation = None self._ready_replicas = None self._replicas = None + self._terminating_replicas = None self._unavailable_replicas = None self._updated_replicas = None self.discriminator = None @@ -82,6 +85,8 @@ def __init__(self, available_replicas=None, collision_count=None, conditions=Non self.ready_replicas = ready_replicas if replicas is not None: self.replicas = replicas + if terminating_replicas is not None: + self.terminating_replicas = terminating_replicas if unavailable_replicas is not None: self.unavailable_replicas = unavailable_replicas if updated_replicas is not None: @@ -91,7 +96,7 @@ def __init__(self, available_replicas=None, collision_count=None, conditions=Non def available_replicas(self): """Gets the available_replicas of this V1DeploymentStatus. # noqa: E501 - Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. # noqa: E501 + Total number of available non-terminating pods (ready for at least minReadySeconds) targeted by this deployment. # noqa: E501 :return: The available_replicas of this V1DeploymentStatus. # noqa: E501 :rtype: int @@ -102,7 +107,7 @@ def available_replicas(self): def available_replicas(self, available_replicas): """Sets the available_replicas of this V1DeploymentStatus. - Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. # noqa: E501 + Total number of available non-terminating pods (ready for at least minReadySeconds) targeted by this deployment. # noqa: E501 :param available_replicas: The available_replicas of this V1DeploymentStatus. # noqa: E501 :type: int @@ -183,7 +188,7 @@ def observed_generation(self, observed_generation): def ready_replicas(self): """Gets the ready_replicas of this V1DeploymentStatus. # noqa: E501 - readyReplicas is the number of pods targeted by this Deployment with a Ready Condition. # noqa: E501 + Total number of non-terminating pods targeted by this Deployment with a Ready Condition. # noqa: E501 :return: The ready_replicas of this V1DeploymentStatus. # noqa: E501 :rtype: int @@ -194,7 +199,7 @@ def ready_replicas(self): def ready_replicas(self, ready_replicas): """Sets the ready_replicas of this V1DeploymentStatus. - readyReplicas is the number of pods targeted by this Deployment with a Ready Condition. # noqa: E501 + Total number of non-terminating pods targeted by this Deployment with a Ready Condition. # noqa: E501 :param ready_replicas: The ready_replicas of this V1DeploymentStatus. # noqa: E501 :type: int @@ -206,7 +211,7 @@ def ready_replicas(self, ready_replicas): def replicas(self): """Gets the replicas of this V1DeploymentStatus. # noqa: E501 - Total number of non-terminated pods targeted by this deployment (their labels match the selector). # noqa: E501 + Total number of non-terminating pods targeted by this deployment (their labels match the selector). # noqa: E501 :return: The replicas of this V1DeploymentStatus. # noqa: E501 :rtype: int @@ -217,7 +222,7 @@ def replicas(self): def replicas(self, replicas): """Sets the replicas of this V1DeploymentStatus. - Total number of non-terminated pods targeted by this deployment (their labels match the selector). # noqa: E501 + Total number of non-terminating pods targeted by this deployment (their labels match the selector). # noqa: E501 :param replicas: The replicas of this V1DeploymentStatus. # noqa: E501 :type: int @@ -225,6 +230,29 @@ def replicas(self, replicas): self._replicas = replicas + @property + def terminating_replicas(self): + """Gets the terminating_replicas of this V1DeploymentStatus. # noqa: E501 + + Total number of terminating pods targeted by this deployment. Terminating pods have a non-null .metadata.deletionTimestamp and have not yet reached the Failed or Succeeded .status.phase. This is an alpha field. Enable DeploymentReplicaSetTerminatingReplicas to be able to use this field. # noqa: E501 + + :return: The terminating_replicas of this V1DeploymentStatus. # noqa: E501 + :rtype: int + """ + return self._terminating_replicas + + @terminating_replicas.setter + def terminating_replicas(self, terminating_replicas): + """Sets the terminating_replicas of this V1DeploymentStatus. + + Total number of terminating pods targeted by this deployment. Terminating pods have a non-null .metadata.deletionTimestamp and have not yet reached the Failed or Succeeded .status.phase. This is an alpha field. Enable DeploymentReplicaSetTerminatingReplicas to be able to use this field. # noqa: E501 + + :param terminating_replicas: The terminating_replicas of this V1DeploymentStatus. # noqa: E501 + :type: int + """ + + self._terminating_replicas = terminating_replicas + @property def unavailable_replicas(self): """Gets the unavailable_replicas of this V1DeploymentStatus. # noqa: E501 @@ -252,7 +280,7 @@ def unavailable_replicas(self, unavailable_replicas): def updated_replicas(self): """Gets the updated_replicas of this V1DeploymentStatus. # noqa: E501 - Total number of non-terminated pods targeted by this deployment that have the desired template spec. # noqa: E501 + Total number of non-terminating pods targeted by this deployment that have the desired template spec. # noqa: E501 :return: The updated_replicas of this V1DeploymentStatus. # noqa: E501 :rtype: int @@ -263,7 +291,7 @@ def updated_replicas(self): def updated_replicas(self, updated_replicas): """Sets the updated_replicas of this V1DeploymentStatus. - Total number of non-terminated pods targeted by this deployment that have the desired template spec. # noqa: E501 + Total number of non-terminating pods targeted by this deployment that have the desired template spec. # noqa: E501 :param updated_replicas: The updated_replicas of this V1DeploymentStatus. # noqa: E501 :type: int diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_strategy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_strategy.py index 367538058a76..9793060b9408 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_strategy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_deployment_strategy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_projection.py b/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_projection.py index f2887cdcccc9..d87a2007f779 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_projection.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_projection.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_file.py b/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_file.py index e21f87973674..7ea7c854b835 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_file.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_file.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_source.py index d0f51c468c00..04a480e2a12e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_downward_api_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_empty_dir_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_empty_dir_volume_source.py index 45943244fbf0..8800fb94bde4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_empty_dir_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_empty_dir_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint.py index 7c3bda2be0d8..a06a08c3142e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -90,7 +90,7 @@ def __init__(self, addresses=None, conditions=None, deprecated_topology=None, hi def addresses(self): """Gets the addresses of this V1Endpoint. # noqa: E501 - addresses of this endpoint. The contents of this field are interpreted according to the corresponding EndpointSlice addressType field. Consumers must handle different types of addresses in the context of their own capabilities. This must contain at least one address but no more than 100. These are all assumed to be fungible and clients may choose to only use the first element. Refer to: https://issue.k8s.io/106267 # noqa: E501 + addresses of this endpoint. For EndpointSlices of addressType \"IPv4\" or \"IPv6\", the values are IP addresses in canonical form. The syntax and semantics of other addressType values are not defined. This must contain at least one address but no more than 100. EndpointSlices generated by the EndpointSlice controller will always have exactly 1 address. No semantics are defined for additional addresses beyond the first, and kube-proxy does not look at them. # noqa: E501 :return: The addresses of this V1Endpoint. # noqa: E501 :rtype: list[str] @@ -101,7 +101,7 @@ def addresses(self): def addresses(self, addresses): """Sets the addresses of this V1Endpoint. - addresses of this endpoint. The contents of this field are interpreted according to the corresponding EndpointSlice addressType field. Consumers must handle different types of addresses in the context of their own capabilities. This must contain at least one address but no more than 100. These are all assumed to be fungible and clients may choose to only use the first element. Refer to: https://issue.k8s.io/106267 # noqa: E501 + addresses of this endpoint. For EndpointSlices of addressType \"IPv4\" or \"IPv6\", the values are IP addresses in canonical form. The syntax and semantics of other addressType values are not defined. This must contain at least one address but no more than 100. EndpointSlices generated by the EndpointSlice controller will always have exactly 1 address. No semantics are defined for additional addresses beyond the first, and kube-proxy does not look at them. # noqa: E501 :param addresses: The addresses of this V1Endpoint. # noqa: E501 :type: list[str] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_address.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_address.py index 1b336b93b42e..222e36b5a677 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_address.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_address.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_conditions.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_conditions.py index 2beb64c22905..6fa95ea357b8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_conditions.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_conditions.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -66,7 +66,7 @@ def __init__(self, ready=None, serving=None, terminating=None, local_vars_config def ready(self): """Gets the ready of this V1EndpointConditions. # noqa: E501 - ready indicates that this endpoint is prepared to receive traffic, according to whatever system is managing the endpoint. A nil value indicates an unknown state. In most cases consumers should interpret this unknown state as ready. For compatibility reasons, ready should never be \"true\" for terminating endpoints, except when the normal readiness behavior is being explicitly overridden, for example when the associated Service has set the publishNotReadyAddresses flag. # noqa: E501 + ready indicates that this endpoint is ready to receive traffic, according to whatever system is managing the endpoint. A nil value should be interpreted as \"true\". In general, an endpoint should be marked ready if it is serving and not terminating, though this can be overridden in some cases, such as when the associated Service has set the publishNotReadyAddresses flag. # noqa: E501 :return: The ready of this V1EndpointConditions. # noqa: E501 :rtype: bool @@ -77,7 +77,7 @@ def ready(self): def ready(self, ready): """Sets the ready of this V1EndpointConditions. - ready indicates that this endpoint is prepared to receive traffic, according to whatever system is managing the endpoint. A nil value indicates an unknown state. In most cases consumers should interpret this unknown state as ready. For compatibility reasons, ready should never be \"true\" for terminating endpoints, except when the normal readiness behavior is being explicitly overridden, for example when the associated Service has set the publishNotReadyAddresses flag. # noqa: E501 + ready indicates that this endpoint is ready to receive traffic, according to whatever system is managing the endpoint. A nil value should be interpreted as \"true\". In general, an endpoint should be marked ready if it is serving and not terminating, though this can be overridden in some cases, such as when the associated Service has set the publishNotReadyAddresses flag. # noqa: E501 :param ready: The ready of this V1EndpointConditions. # noqa: E501 :type: bool @@ -89,7 +89,7 @@ def ready(self, ready): def serving(self): """Gets the serving of this V1EndpointConditions. # noqa: E501 - serving is identical to ready except that it is set regardless of the terminating state of endpoints. This condition should be set to true for a ready endpoint that is terminating. If nil, consumers should defer to the ready condition. # noqa: E501 + serving indicates that this endpoint is able to receive traffic, according to whatever system is managing the endpoint. For endpoints backed by pods, the EndpointSlice controller will mark the endpoint as serving if the pod's Ready condition is True. A nil value should be interpreted as \"true\". # noqa: E501 :return: The serving of this V1EndpointConditions. # noqa: E501 :rtype: bool @@ -100,7 +100,7 @@ def serving(self): def serving(self, serving): """Sets the serving of this V1EndpointConditions. - serving is identical to ready except that it is set regardless of the terminating state of endpoints. This condition should be set to true for a ready endpoint that is terminating. If nil, consumers should defer to the ready condition. # noqa: E501 + serving indicates that this endpoint is able to receive traffic, according to whatever system is managing the endpoint. For endpoints backed by pods, the EndpointSlice controller will mark the endpoint as serving if the pod's Ready condition is True. A nil value should be interpreted as \"true\". # noqa: E501 :param serving: The serving of this V1EndpointConditions. # noqa: E501 :type: bool @@ -112,7 +112,7 @@ def serving(self, serving): def terminating(self): """Gets the terminating of this V1EndpointConditions. # noqa: E501 - terminating indicates that this endpoint is terminating. A nil value indicates an unknown state. Consumers should interpret this unknown state to mean that the endpoint is not terminating. # noqa: E501 + terminating indicates that this endpoint is terminating. A nil value should be interpreted as \"false\". # noqa: E501 :return: The terminating of this V1EndpointConditions. # noqa: E501 :rtype: bool @@ -123,7 +123,7 @@ def terminating(self): def terminating(self, terminating): """Sets the terminating of this V1EndpointConditions. - terminating indicates that this endpoint is terminating. A nil value indicates an unknown state. Consumers should interpret this unknown state to mean that the endpoint is not terminating. # noqa: E501 + terminating indicates that this endpoint is terminating. A nil value should be interpreted as \"false\". # noqa: E501 :param terminating: The terminating of this V1EndpointConditions. # noqa: E501 :type: bool diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_hints.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_hints.py index 68ed940f2e75..d26f0efa0fad 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_hints.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_hints.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -33,30 +33,58 @@ class V1EndpointHints(object): and the value is json key in definition. """ openapi_types = { + 'for_nodes': 'list[V1ForNode]', 'for_zones': 'list[V1ForZone]' } attribute_map = { + 'for_nodes': 'forNodes', 'for_zones': 'forZones' } - def __init__(self, for_zones=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, for_nodes=None, for_zones=None, local_vars_configuration=None): # noqa: E501 """V1EndpointHints - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration + self._for_nodes = None self._for_zones = None self.discriminator = None + if for_nodes is not None: + self.for_nodes = for_nodes if for_zones is not None: self.for_zones = for_zones + @property + def for_nodes(self): + """Gets the for_nodes of this V1EndpointHints. # noqa: E501 + + forNodes indicates the node(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. This is an Alpha feature and is only used when the PreferSameTrafficDistribution feature gate is enabled. # noqa: E501 + + :return: The for_nodes of this V1EndpointHints. # noqa: E501 + :rtype: list[V1ForNode] + """ + return self._for_nodes + + @for_nodes.setter + def for_nodes(self, for_nodes): + """Sets the for_nodes of this V1EndpointHints. + + forNodes indicates the node(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. This is an Alpha feature and is only used when the PreferSameTrafficDistribution feature gate is enabled. # noqa: E501 + + :param for_nodes: The for_nodes of this V1EndpointHints. # noqa: E501 + :type: list[V1ForNode] + """ + + self._for_nodes = for_nodes + @property def for_zones(self): """Gets the for_zones of this V1EndpointHints. # noqa: E501 - forZones indicates the zone(s) this endpoint should be consumed by to enable topology aware routing. # noqa: E501 + forZones indicates the zone(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. # noqa: E501 :return: The for_zones of this V1EndpointHints. # noqa: E501 :rtype: list[V1ForZone] @@ -67,7 +95,7 @@ def for_zones(self): def for_zones(self, for_zones): """Sets the for_zones of this V1EndpointHints. - forZones indicates the zone(s) this endpoint should be consumed by to enable topology aware routing. # noqa: E501 + forZones indicates the zone(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. # noqa: E501 :param for_zones: The for_zones of this V1EndpointHints. # noqa: E501 :type: list[V1ForZone] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice.py index 701418b64580..d52e5e5bbf7e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -79,7 +79,7 @@ def __init__(self, address_type=None, api_version=None, endpoints=None, kind=Non def address_type(self): """Gets the address_type of this V1EndpointSlice. # noqa: E501 - addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name. # noqa: E501 + addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name. (Deprecated) The EndpointSlice controller only generates, and kube-proxy only processes, slices of addressType \"IPv4\" and \"IPv6\". No semantics are defined for the \"FQDN\" type. # noqa: E501 :return: The address_type of this V1EndpointSlice. # noqa: E501 :rtype: str @@ -90,7 +90,7 @@ def address_type(self): def address_type(self, address_type): """Sets the address_type of this V1EndpointSlice. - addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name. # noqa: E501 + addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name. (Deprecated) The EndpointSlice controller only generates, and kube-proxy only processes, slices of addressType \"IPv4\" and \"IPv6\". No semantics are defined for the \"FQDN\" type. # noqa: E501 :param address_type: The address_type of this V1EndpointSlice. # noqa: E501 :type: str @@ -196,7 +196,7 @@ def metadata(self, metadata): def ports(self): """Gets the ports of this V1EndpointSlice. # noqa: E501 - ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. When ports is empty, it indicates that there are no defined ports. When a port is defined with a nil port value, it indicates \"all ports\". Each slice may include a maximum of 100 ports. # noqa: E501 + ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. Each slice may include a maximum of 100 ports. Services always have at least 1 port, so EndpointSlices generated by the EndpointSlice controller will likewise always have at least 1 port. EndpointSlices used for other purposes may have an empty ports list. # noqa: E501 :return: The ports of this V1EndpointSlice. # noqa: E501 :rtype: list[DiscoveryV1EndpointPort] @@ -207,7 +207,7 @@ def ports(self): def ports(self, ports): """Sets the ports of this V1EndpointSlice. - ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. When ports is empty, it indicates that there are no defined ports. When a port is defined with a nil port value, it indicates \"all ports\". Each slice may include a maximum of 100 ports. # noqa: E501 + ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. Each slice may include a maximum of 100 ports. Services always have at least 1 port, so EndpointSlices generated by the EndpointSlice controller will likewise always have at least 1 port. EndpointSlices used for other purposes may have an empty ports list. # noqa: E501 :param ports: The ports of this V1EndpointSlice. # noqa: E501 :type: list[DiscoveryV1EndpointPort] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice_list.py index 3514475adaa4..652378462b46 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_slice_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_subset.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_subset.py index adfaa00db100..a27ff3a758f7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_subset.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoint_subset.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints.py index 0d50bbc848d7..8ed2c4e350d3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints_list.py index beb32af07e30..af4cf76cc70c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_endpoints_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_env_from_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_env_from_source.py index 3e25bf2109c1..4df30f6fa503 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_env_from_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_env_from_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -87,7 +87,7 @@ def config_map_ref(self, config_map_ref): def prefix(self): """Gets the prefix of this V1EnvFromSource. # noqa: E501 - An optional identifier to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. # noqa: E501 + Optional text to prepend to the name of each environment variable. Must be a C_IDENTIFIER. # noqa: E501 :return: The prefix of this V1EnvFromSource. # noqa: E501 :rtype: str @@ -98,7 +98,7 @@ def prefix(self): def prefix(self, prefix): """Sets the prefix of this V1EnvFromSource. - An optional identifier to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. # noqa: E501 + Optional text to prepend to the name of each environment variable. Must be a C_IDENTIFIER. # noqa: E501 :param prefix: The prefix of this V1EnvFromSource. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_env_var.py b/contrib/python/kubernetes/kubernetes/client/models/v1_env_var.py index fdd294b5981e..428687899451 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_env_var.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_env_var.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_env_var_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_env_var_source.py index d36c9f1ebaea..014e5f93a14a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_env_var_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_env_var_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_container.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_container.py index 2f671ab256df..954816b3d9e4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_container.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_container.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_volume_source.py index a85e1ca03140..3003f1c2b818 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ephemeral_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_event_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_event_source.py index e03c6784cb6b..a4d6ea50d69c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_event_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_event_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_eviction.py b/contrib/python/kubernetes/kubernetes/client/models/v1_eviction.py index e38518aacfeb..2f7b9531b607 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_eviction.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_eviction.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_exec_action.py b/contrib/python/kubernetes/kubernetes/client/models/v1_exec_action.py index b59981448a51..e3c1c76e65b4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_exec_action.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_exec_action.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_exempt_priority_level_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_exempt_priority_level_configuration.py index 2699cfc81055..fb40310b1096 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_exempt_priority_level_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_exempt_priority_level_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_expression_warning.py b/contrib/python/kubernetes/kubernetes/client/models/v1_expression_warning.py index d2edd906dcfb..2b1733d49b48 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_expression_warning.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_expression_warning.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_external_documentation.py b/contrib/python/kubernetes/kubernetes/client/models/v1_external_documentation.py index 18236dd9c33f..d761e1973ceb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_external_documentation.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_external_documentation.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_fc_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_fc_volume_source.py index 89c88086076c..04200a4409d7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_fc_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_fc_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_attributes.py b/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_attributes.py index b85ccb858d84..84afbaafbc33 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_attributes.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_attributes.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_requirement.py b/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_requirement.py index 93eba687d9f9..0e10f429c6c3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_requirement.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_field_selector_requirement.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flex_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flex_persistent_volume_source.py index e95b087a1dbe..6fa3db432be2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flex_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flex_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flex_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flex_volume_source.py index d50f1552eae2..91a7f617e4af 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flex_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flex_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flocker_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flocker_volume_source.py index 0e4bbeeff143..8ede8b659826 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flocker_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flocker_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_distinguisher_method.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_distinguisher_method.py index 65dd783bc232..3d0455462468 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_distinguisher_method.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_distinguisher_method.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema.py index 1e7f153cf509..d893474bc53e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_condition.py index 4f6e4b5c6036..573ed8b8a43c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_list.py index 89ed7aad90df..4fd31dca8c90 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_spec.py index ab041089e9be..1400d1248ee1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_status.py index 26450ca182de..da9ce9ec80b2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_flow_schema_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1beta3_user_subject.py b/contrib/python/kubernetes/kubernetes/client/models/v1_for_node.py similarity index 80% rename from contrib/python/kubernetes/kubernetes/client/models/v1beta3_user_subject.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_for_node.py index 3bcb36815c50..6cce66f60256 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1beta3_user_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_for_node.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.31 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1beta3UserSubject(object): +class V1ForNode(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -41,7 +41,7 @@ class V1beta3UserSubject(object): } def __init__(self, name=None, local_vars_configuration=None): # noqa: E501 - """V1beta3UserSubject - a model defined in OpenAPI""" # noqa: E501 + """V1ForNode - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -53,22 +53,22 @@ def __init__(self, name=None, local_vars_configuration=None): # noqa: E501 @property def name(self): - """Gets the name of this V1beta3UserSubject. # noqa: E501 + """Gets the name of this V1ForNode. # noqa: E501 - `name` is the username that matches, or \"*\" to match all usernames. Required. # noqa: E501 + name represents the name of the node. # noqa: E501 - :return: The name of this V1beta3UserSubject. # noqa: E501 + :return: The name of this V1ForNode. # noqa: E501 :rtype: str """ return self._name @name.setter def name(self, name): - """Sets the name of this V1beta3UserSubject. + """Sets the name of this V1ForNode. - `name` is the username that matches, or \"*\" to match all usernames. Required. # noqa: E501 + name represents the name of the node. # noqa: E501 - :param name: The name of this V1beta3UserSubject. # noqa: E501 + :param name: The name of this V1ForNode. # noqa: E501 :type: str """ if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 @@ -110,14 +110,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1beta3UserSubject): + if not isinstance(other, V1ForNode): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1beta3UserSubject): + if not isinstance(other, V1ForNode): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_for_zone.py b/contrib/python/kubernetes/kubernetes/client/models/v1_for_zone.py index afe1a495ded7..f752e6d15b50 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_for_zone.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_for_zone.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_gce_persistent_disk_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_gce_persistent_disk_volume_source.py index 1ddedc61b040..343885c434d0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_gce_persistent_disk_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_gce_persistent_disk_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_git_repo_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_git_repo_volume_source.py index 47feab6cebe6..ddf4de6e8edf 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_git_repo_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_git_repo_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_persistent_volume_source.py index a5055ed22a3c..9b15d2c495c9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_volume_source.py index 1f690fc061c8..8108a629fb52 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_glusterfs_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_group_subject.py b/contrib/python/kubernetes/kubernetes/client/models/v1_group_subject.py index da6cca3a76a8..2ca56868490b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_group_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_group_subject.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_group_version_for_discovery.py b/contrib/python/kubernetes/kubernetes/client/models/v1_group_version_for_discovery.py index 8fa9cba78f07..36dbe8936598 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_group_version_for_discovery.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_group_version_for_discovery.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_grpc_action.py b/contrib/python/kubernetes/kubernetes/client/models/v1_grpc_action.py index fc7d82ea239a..78a4e9e94ca7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_grpc_action.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_grpc_action.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler.py b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler.py index 1344b8a62263..e33a89022bbc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_list.py index 75ebb770adab..7f02258168fc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_spec.py index b8780135f0fe..a2e7763085f2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_status.py index 239123572c98..456f1215e540 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_horizontal_pod_autoscaler_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_host_alias.py b/contrib/python/kubernetes/kubernetes/client/models/v1_host_alias.py index 75af1a7578d2..a5c19cacfdfe 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_host_alias.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_host_alias.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_host_ip.py b/contrib/python/kubernetes/kubernetes/client/models/v1_host_ip.py index ce28a05c591a..6250f8c979a5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_host_ip.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_host_ip.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_host_path_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_host_path_volume_source.py index 942f79ea375e..113904d1d68e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_host_path_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_host_path_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_http_get_action.py b/contrib/python/kubernetes/kubernetes/client/models/v1_http_get_action.py index 7dad65340201..4e896809d64e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_http_get_action.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_http_get_action.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_http_header.py b/contrib/python/kubernetes/kubernetes/client/models/v1_http_header.py index 67a323a7074e..ba9f38afcf25 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_http_header.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_http_header.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_path.py b/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_path.py index e9fcd24d2562..59ed42eda6a3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_path.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_path.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_rule_value.py b/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_rule_value.py index a0ac0b7c5fc1..d6fe4a727f03 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_rule_value.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_http_ingress_rule_value.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_image_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_image_volume_source.py index beb66f20d5cf..da6363db3ed4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_image_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_image_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress.py index e7b2efe1b0ec..a100bd27191f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_backend.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_backend.py index d56fd5931f02..9d41bdbc6e11 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_backend.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_backend.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class.py index 8e4df111a915..c9b0c1f72063 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_list.py index fd5255bca91d..3e842fcf1598 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_parameters_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_parameters_reference.py index c6be6eb6ebd0..3d615cfd390d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_parameters_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_parameters_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_spec.py index a8d468ad64a9..ed6e54551a75 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_class_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_list.py index b5f97740cf2d..88eed4e4ee34 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_ingress.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_ingress.py index 8c96184eb1f4..7a1a28d3ce30 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_ingress.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_ingress.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_status.py index 356924f99363..2862de7bcd89 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_load_balancer_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_port_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_port_status.py index 23dc487d06c2..40d33def1e90 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_port_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_port_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_rule.py index 4f5e83ad8911..b866034634c5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_service_backend.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_service_backend.py index 5c788cd1bcf1..90e4f9b6707b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_service_backend.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_service_backend.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_spec.py index 5b2c8100d808..5d77bd72cd9f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_status.py index dd40a850eb56..2cc4c94a5efa 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_tls.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_tls.py index ec435226ff27..3a40d1b4ab84 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_tls.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ingress_tls.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_address.py similarity index 78% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_ip_address.py index f7aca23efabf..08943f2b4d8f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_address.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1IPAddress(object): +class V1IPAddress(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -36,7 +36,7 @@ class V1alpha1IPAddress(object): 'api_version': 'str', 'kind': 'str', 'metadata': 'V1ObjectMeta', - 'spec': 'V1alpha1IPAddressSpec' + 'spec': 'V1IPAddressSpec' } attribute_map = { @@ -47,7 +47,7 @@ class V1alpha1IPAddress(object): } def __init__(self, api_version=None, kind=None, metadata=None, spec=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1IPAddress - a model defined in OpenAPI""" # noqa: E501 + """V1IPAddress - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -69,22 +69,22 @@ def __init__(self, api_version=None, kind=None, metadata=None, spec=None, local_ @property def api_version(self): - """Gets the api_version of this V1alpha1IPAddress. # noqa: E501 + """Gets the api_version of this V1IPAddress. # noqa: E501 APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :return: The api_version of this V1alpha1IPAddress. # noqa: E501 + :return: The api_version of this V1IPAddress. # noqa: E501 :rtype: str """ return self._api_version @api_version.setter def api_version(self, api_version): - """Sets the api_version of this V1alpha1IPAddress. + """Sets the api_version of this V1IPAddress. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :param api_version: The api_version of this V1alpha1IPAddress. # noqa: E501 + :param api_version: The api_version of this V1IPAddress. # noqa: E501 :type: str """ @@ -92,22 +92,22 @@ def api_version(self, api_version): @property def kind(self): - """Gets the kind of this V1alpha1IPAddress. # noqa: E501 + """Gets the kind of this V1IPAddress. # noqa: E501 Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :return: The kind of this V1alpha1IPAddress. # noqa: E501 + :return: The kind of this V1IPAddress. # noqa: E501 :rtype: str """ return self._kind @kind.setter def kind(self, kind): - """Sets the kind of this V1alpha1IPAddress. + """Sets the kind of this V1IPAddress. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :param kind: The kind of this V1alpha1IPAddress. # noqa: E501 + :param kind: The kind of this V1IPAddress. # noqa: E501 :type: str """ @@ -115,20 +115,20 @@ def kind(self, kind): @property def metadata(self): - """Gets the metadata of this V1alpha1IPAddress. # noqa: E501 + """Gets the metadata of this V1IPAddress. # noqa: E501 - :return: The metadata of this V1alpha1IPAddress. # noqa: E501 + :return: The metadata of this V1IPAddress. # noqa: E501 :rtype: V1ObjectMeta """ return self._metadata @metadata.setter def metadata(self, metadata): - """Sets the metadata of this V1alpha1IPAddress. + """Sets the metadata of this V1IPAddress. - :param metadata: The metadata of this V1alpha1IPAddress. # noqa: E501 + :param metadata: The metadata of this V1IPAddress. # noqa: E501 :type: V1ObjectMeta """ @@ -136,21 +136,21 @@ def metadata(self, metadata): @property def spec(self): - """Gets the spec of this V1alpha1IPAddress. # noqa: E501 + """Gets the spec of this V1IPAddress. # noqa: E501 - :return: The spec of this V1alpha1IPAddress. # noqa: E501 - :rtype: V1alpha1IPAddressSpec + :return: The spec of this V1IPAddress. # noqa: E501 + :rtype: V1IPAddressSpec """ return self._spec @spec.setter def spec(self, spec): - """Sets the spec of this V1alpha1IPAddress. + """Sets the spec of this V1IPAddress. - :param spec: The spec of this V1alpha1IPAddress. # noqa: E501 - :type: V1alpha1IPAddressSpec + :param spec: The spec of this V1IPAddress. # noqa: E501 + :type: V1IPAddressSpec """ self._spec = spec @@ -189,14 +189,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1IPAddress): + if not isinstance(other, V1IPAddress): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1IPAddress): + if not isinstance(other, V1IPAddress): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_address_list.py similarity index 78% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address_list.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_ip_address_list.py index aa5c5d447543..a9862597d24c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_address_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1IPAddressList(object): +class V1IPAddressList(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -34,7 +34,7 @@ class V1alpha1IPAddressList(object): """ openapi_types = { 'api_version': 'str', - 'items': 'list[V1alpha1IPAddress]', + 'items': 'list[V1IPAddress]', 'kind': 'str', 'metadata': 'V1ListMeta' } @@ -47,7 +47,7 @@ class V1alpha1IPAddressList(object): } def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1IPAddressList - a model defined in OpenAPI""" # noqa: E501 + """V1IPAddressList - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -68,22 +68,22 @@ def __init__(self, api_version=None, items=None, kind=None, metadata=None, local @property def api_version(self): - """Gets the api_version of this V1alpha1IPAddressList. # noqa: E501 + """Gets the api_version of this V1IPAddressList. # noqa: E501 APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :return: The api_version of this V1alpha1IPAddressList. # noqa: E501 + :return: The api_version of this V1IPAddressList. # noqa: E501 :rtype: str """ return self._api_version @api_version.setter def api_version(self, api_version): - """Sets the api_version of this V1alpha1IPAddressList. + """Sets the api_version of this V1IPAddressList. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :param api_version: The api_version of this V1alpha1IPAddressList. # noqa: E501 + :param api_version: The api_version of this V1IPAddressList. # noqa: E501 :type: str """ @@ -91,23 +91,23 @@ def api_version(self, api_version): @property def items(self): - """Gets the items of this V1alpha1IPAddressList. # noqa: E501 + """Gets the items of this V1IPAddressList. # noqa: E501 items is the list of IPAddresses. # noqa: E501 - :return: The items of this V1alpha1IPAddressList. # noqa: E501 - :rtype: list[V1alpha1IPAddress] + :return: The items of this V1IPAddressList. # noqa: E501 + :rtype: list[V1IPAddress] """ return self._items @items.setter def items(self, items): - """Sets the items of this V1alpha1IPAddressList. + """Sets the items of this V1IPAddressList. items is the list of IPAddresses. # noqa: E501 - :param items: The items of this V1alpha1IPAddressList. # noqa: E501 - :type: list[V1alpha1IPAddress] + :param items: The items of this V1IPAddressList. # noqa: E501 + :type: list[V1IPAddress] """ if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 @@ -116,22 +116,22 @@ def items(self, items): @property def kind(self): - """Gets the kind of this V1alpha1IPAddressList. # noqa: E501 + """Gets the kind of this V1IPAddressList. # noqa: E501 Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :return: The kind of this V1alpha1IPAddressList. # noqa: E501 + :return: The kind of this V1IPAddressList. # noqa: E501 :rtype: str """ return self._kind @kind.setter def kind(self, kind): - """Sets the kind of this V1alpha1IPAddressList. + """Sets the kind of this V1IPAddressList. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :param kind: The kind of this V1alpha1IPAddressList. # noqa: E501 + :param kind: The kind of this V1IPAddressList. # noqa: E501 :type: str """ @@ -139,20 +139,20 @@ def kind(self, kind): @property def metadata(self): - """Gets the metadata of this V1alpha1IPAddressList. # noqa: E501 + """Gets the metadata of this V1IPAddressList. # noqa: E501 - :return: The metadata of this V1alpha1IPAddressList. # noqa: E501 + :return: The metadata of this V1IPAddressList. # noqa: E501 :rtype: V1ListMeta """ return self._metadata @metadata.setter def metadata(self, metadata): - """Sets the metadata of this V1alpha1IPAddressList. + """Sets the metadata of this V1IPAddressList. - :param metadata: The metadata of this V1alpha1IPAddressList. # noqa: E501 + :param metadata: The metadata of this V1IPAddressList. # noqa: E501 :type: V1ListMeta """ @@ -192,14 +192,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1IPAddressList): + if not isinstance(other, V1IPAddressList): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1IPAddressList): + if not isinstance(other, V1IPAddressList): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_address_spec.py similarity index 80% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address_spec.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_ip_address_spec.py index 920e24e29e8b..912359c35ed9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_ip_address_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_address_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1IPAddressSpec(object): +class V1IPAddressSpec(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -33,7 +33,7 @@ class V1alpha1IPAddressSpec(object): and the value is json key in definition. """ openapi_types = { - 'parent_ref': 'V1alpha1ParentReference' + 'parent_ref': 'V1ParentReference' } attribute_map = { @@ -41,7 +41,7 @@ class V1alpha1IPAddressSpec(object): } def __init__(self, parent_ref=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1IPAddressSpec - a model defined in OpenAPI""" # noqa: E501 + """V1IPAddressSpec - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -53,21 +53,21 @@ def __init__(self, parent_ref=None, local_vars_configuration=None): # noqa: E50 @property def parent_ref(self): - """Gets the parent_ref of this V1alpha1IPAddressSpec. # noqa: E501 + """Gets the parent_ref of this V1IPAddressSpec. # noqa: E501 - :return: The parent_ref of this V1alpha1IPAddressSpec. # noqa: E501 - :rtype: V1alpha1ParentReference + :return: The parent_ref of this V1IPAddressSpec. # noqa: E501 + :rtype: V1ParentReference """ return self._parent_ref @parent_ref.setter def parent_ref(self, parent_ref): - """Sets the parent_ref of this V1alpha1IPAddressSpec. + """Sets the parent_ref of this V1IPAddressSpec. - :param parent_ref: The parent_ref of this V1alpha1IPAddressSpec. # noqa: E501 - :type: V1alpha1ParentReference + :param parent_ref: The parent_ref of this V1IPAddressSpec. # noqa: E501 + :type: V1ParentReference """ if self.local_vars_configuration.client_side_validation and parent_ref is None: # noqa: E501 raise ValueError("Invalid value for `parent_ref`, must not be `None`") # noqa: E501 @@ -108,14 +108,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1IPAddressSpec): + if not isinstance(other, V1IPAddressSpec): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1IPAddressSpec): + if not isinstance(other, V1IPAddressSpec): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_ip_block.py b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_block.py index 9f10a82685bc..5cbc02e5d8ca 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_ip_block.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_ip_block.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_persistent_volume_source.py index 6d851f48d5c5..ed7dfb352fae 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_volume_source.py index 4c740abe5f1a..55561b39654c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_iscsi_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_job.py b/contrib/python/kubernetes/kubernetes/client/models/v1_job.py index 67dd8a3b6145..9ab9bf909f21 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_job.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_job.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_job_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_job_condition.py index f8c2e786bb42..c1ae8f2e5fbf 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_job_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_job_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_job_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_job_list.py index 9345b954cbaf..54208bc5a48b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_job_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_job_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_job_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_job_spec.py index d28dcf00d3d0..189887f95364 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_job_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_job_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -176,7 +176,7 @@ def backoff_limit(self, backoff_limit): def backoff_limit_per_index(self): """Gets the backoff_limit_per_index of this V1JobSpec. # noqa: E501 - Specifies the limit for the number of retries within an index before marking this index as failed. When enabled the number of failures per index is kept in the pod's batch.kubernetes.io/job-index-failure-count annotation. It can only be set when Job's completionMode=Indexed, and the Pod's restart policy is Never. The field is immutable. This field is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). # noqa: E501 + Specifies the limit for the number of retries within an index before marking this index as failed. When enabled the number of failures per index is kept in the pod's batch.kubernetes.io/job-index-failure-count annotation. It can only be set when Job's completionMode=Indexed, and the Pod's restart policy is Never. The field is immutable. # noqa: E501 :return: The backoff_limit_per_index of this V1JobSpec. # noqa: E501 :rtype: int @@ -187,7 +187,7 @@ def backoff_limit_per_index(self): def backoff_limit_per_index(self, backoff_limit_per_index): """Sets the backoff_limit_per_index of this V1JobSpec. - Specifies the limit for the number of retries within an index before marking this index as failed. When enabled the number of failures per index is kept in the pod's batch.kubernetes.io/job-index-failure-count annotation. It can only be set when Job's completionMode=Indexed, and the Pod's restart policy is Never. The field is immutable. This field is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). # noqa: E501 + Specifies the limit for the number of retries within an index before marking this index as failed. When enabled the number of failures per index is kept in the pod's batch.kubernetes.io/job-index-failure-count annotation. It can only be set when Job's completionMode=Indexed, and the Pod's restart policy is Never. The field is immutable. # noqa: E501 :param backoff_limit_per_index: The backoff_limit_per_index of this V1JobSpec. # noqa: E501 :type: int @@ -291,7 +291,7 @@ def manual_selector(self, manual_selector): def max_failed_indexes(self): """Gets the max_failed_indexes of this V1JobSpec. # noqa: E501 - Specifies the maximal number of failed indexes before marking the Job as failed, when backoffLimitPerIndex is set. Once the number of failed indexes exceeds this number the entire Job is marked as Failed and its execution is terminated. When left as null the job continues execution of all of its indexes and is marked with the `Complete` Job condition. It can only be specified when backoffLimitPerIndex is set. It can be null or up to completions. It is required and must be less than or equal to 10^4 when is completions greater than 10^5. This field is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). # noqa: E501 + Specifies the maximal number of failed indexes before marking the Job as failed, when backoffLimitPerIndex is set. Once the number of failed indexes exceeds this number the entire Job is marked as Failed and its execution is terminated. When left as null the job continues execution of all of its indexes and is marked with the `Complete` Job condition. It can only be specified when backoffLimitPerIndex is set. It can be null or up to completions. It is required and must be less than or equal to 10^4 when is completions greater than 10^5. # noqa: E501 :return: The max_failed_indexes of this V1JobSpec. # noqa: E501 :rtype: int @@ -302,7 +302,7 @@ def max_failed_indexes(self): def max_failed_indexes(self, max_failed_indexes): """Sets the max_failed_indexes of this V1JobSpec. - Specifies the maximal number of failed indexes before marking the Job as failed, when backoffLimitPerIndex is set. Once the number of failed indexes exceeds this number the entire Job is marked as Failed and its execution is terminated. When left as null the job continues execution of all of its indexes and is marked with the `Complete` Job condition. It can only be specified when backoffLimitPerIndex is set. It can be null or up to completions. It is required and must be less than or equal to 10^4 when is completions greater than 10^5. This field is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). # noqa: E501 + Specifies the maximal number of failed indexes before marking the Job as failed, when backoffLimitPerIndex is set. Once the number of failed indexes exceeds this number the entire Job is marked as Failed and its execution is terminated. When left as null the job continues execution of all of its indexes and is marked with the `Complete` Job condition. It can only be specified when backoffLimitPerIndex is set. It can be null or up to completions. It is required and must be less than or equal to 10^4 when is completions greater than 10^5. # noqa: E501 :param max_failed_indexes: The max_failed_indexes of this V1JobSpec. # noqa: E501 :type: int diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_job_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_job_status.py index f3d0b3cf5c10..e1d6cabc536e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_job_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_job_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -221,7 +221,7 @@ def failed(self, failed): def failed_indexes(self): """Gets the failed_indexes of this V1JobStatus. # noqa: E501 - FailedIndexes holds the failed indexes when spec.backoffLimitPerIndex is set. The indexes are represented in the text format analogous as for the `completedIndexes` field, ie. they are kept as decimal integers separated by commas. The numbers are listed in increasing order. Three or more consecutive numbers are compressed and represented by the first and last element of the series, separated by a hyphen. For example, if the failed indexes are 1, 3, 4, 5 and 7, they are represented as \"1,3-5,7\". The set of failed indexes cannot overlap with the set of completed indexes. This field is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). # noqa: E501 + FailedIndexes holds the failed indexes when spec.backoffLimitPerIndex is set. The indexes are represented in the text format analogous as for the `completedIndexes` field, ie. they are kept as decimal integers separated by commas. The numbers are listed in increasing order. Three or more consecutive numbers are compressed and represented by the first and last element of the series, separated by a hyphen. For example, if the failed indexes are 1, 3, 4, 5 and 7, they are represented as \"1,3-5,7\". The set of failed indexes cannot overlap with the set of completed indexes. # noqa: E501 :return: The failed_indexes of this V1JobStatus. # noqa: E501 :rtype: str @@ -232,7 +232,7 @@ def failed_indexes(self): def failed_indexes(self, failed_indexes): """Sets the failed_indexes of this V1JobStatus. - FailedIndexes holds the failed indexes when spec.backoffLimitPerIndex is set. The indexes are represented in the text format analogous as for the `completedIndexes` field, ie. they are kept as decimal integers separated by commas. The numbers are listed in increasing order. Three or more consecutive numbers are compressed and represented by the first and last element of the series, separated by a hyphen. For example, if the failed indexes are 1, 3, 4, 5 and 7, they are represented as \"1,3-5,7\". The set of failed indexes cannot overlap with the set of completed indexes. This field is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). # noqa: E501 + FailedIndexes holds the failed indexes when spec.backoffLimitPerIndex is set. The indexes are represented in the text format analogous as for the `completedIndexes` field, ie. they are kept as decimal integers separated by commas. The numbers are listed in increasing order. Three or more consecutive numbers are compressed and represented by the first and last element of the series, separated by a hyphen. For example, if the failed indexes are 1, 3, 4, 5 and 7, they are represented as \"1,3-5,7\". The set of failed indexes cannot overlap with the set of completed indexes. # noqa: E501 :param failed_indexes: The failed_indexes of this V1JobStatus. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_job_template_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_job_template_spec.py index ab3661bf1ebe..ecf6fe0575d1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_job_template_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_job_template_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_json_schema_props.py b/contrib/python/kubernetes/kubernetes/client/models/v1_json_schema_props.py index bb4bae3731e5..900d1c0b0612 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_json_schema_props.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_json_schema_props.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_key_to_path.py b/contrib/python/kubernetes/kubernetes/client/models/v1_key_to_path.py index d62569b18ad4..e081fc4ef564 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_key_to_path.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_key_to_path.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector.py index 22f6027b7bba..6a2a5d3918b5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_attributes.py b/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_attributes.py index 2496e1cfc382..9bf0a7594ab8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_attributes.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_attributes.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_requirement.py b/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_requirement.py index d379a431728a..c3c7d6615e0c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_requirement.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_label_selector_requirement.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_lease.py b/contrib/python/kubernetes/kubernetes/client/models/v1_lease.py index e6c1ad2a0532..3c30a1259343 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_lease.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_lease.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_lease_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_lease_list.py index ebc499fbc91f..5e6bb5fb828a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_lease_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_lease_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_lease_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_lease_spec.py index 827b26a5e6ca..7d6238582973 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_lease_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_lease_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle.py b/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle.py index 92c83e71ea9b..164fcb02191b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -34,15 +34,17 @@ class V1Lifecycle(object): """ openapi_types = { 'post_start': 'V1LifecycleHandler', - 'pre_stop': 'V1LifecycleHandler' + 'pre_stop': 'V1LifecycleHandler', + 'stop_signal': 'str' } attribute_map = { 'post_start': 'postStart', - 'pre_stop': 'preStop' + 'pre_stop': 'preStop', + 'stop_signal': 'stopSignal' } - def __init__(self, post_start=None, pre_stop=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, post_start=None, pre_stop=None, stop_signal=None, local_vars_configuration=None): # noqa: E501 """V1Lifecycle - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -50,12 +52,15 @@ def __init__(self, post_start=None, pre_stop=None, local_vars_configuration=None self._post_start = None self._pre_stop = None + self._stop_signal = None self.discriminator = None if post_start is not None: self.post_start = post_start if pre_stop is not None: self.pre_stop = pre_stop + if stop_signal is not None: + self.stop_signal = stop_signal @property def post_start(self): @@ -99,6 +104,29 @@ def pre_stop(self, pre_stop): self._pre_stop = pre_stop + @property + def stop_signal(self): + """Gets the stop_signal of this V1Lifecycle. # noqa: E501 + + StopSignal defines which signal will be sent to a container when it is being stopped. If not specified, the default is defined by the container runtime in use. StopSignal can only be set for Pods with a non-empty .spec.os.name # noqa: E501 + + :return: The stop_signal of this V1Lifecycle. # noqa: E501 + :rtype: str + """ + return self._stop_signal + + @stop_signal.setter + def stop_signal(self, stop_signal): + """Sets the stop_signal of this V1Lifecycle. + + StopSignal defines which signal will be sent to a container when it is being stopped. If not specified, the default is defined by the container runtime in use. StopSignal can only be set for Pods with a non-empty .spec.os.name # noqa: E501 + + :param stop_signal: The stop_signal of this V1Lifecycle. # noqa: E501 + :type: str + """ + + self._stop_signal = stop_signal + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle_handler.py b/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle_handler.py index f1c751f7d749..bc6cfb64cceb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle_handler.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_lifecycle_handler.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range.py b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range.py index 23e65b9cb518..3eb6be6351ac 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_item.py b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_item.py index 51f2a0319948..df6c94b9a632 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_item.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_item.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_list.py index 2b46d335fa00..94361103084d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_spec.py index d495adf15dbc..b05901db1886 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_range_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_response.py b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_response.py index 55e212dce280..67f1c4cfb800 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_limit_response.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_limit_response.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_limited_priority_level_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_limited_priority_level_configuration.py index 9151a1ed49d9..a3f3dd21678f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_limited_priority_level_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_limited_priority_level_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_linux_container_user.py b/contrib/python/kubernetes/kubernetes/client/models/v1_linux_container_user.py index ada85cfb04f7..0c15e2514eec 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_linux_container_user.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_linux_container_user.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_list_meta.py b/contrib/python/kubernetes/kubernetes/client/models/v1_list_meta.py index 683cec482184..5bd9f324d686 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_list_meta.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_list_meta.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_ingress.py b/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_ingress.py index 5e68a596064a..f5e50aeb711b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_ingress.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_ingress.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_status.py index f1f049499969..5622d2bef90f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_load_balancer_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_local_object_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_local_object_reference.py index 291dbddf917d..e4023cf0c6ec 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_local_object_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_local_object_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_local_subject_access_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1_local_subject_access_review.py index 84676ac726d2..2c1efb4da08d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_local_subject_access_review.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_local_subject_access_review.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_local_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_local_volume_source.py index ffead23e9476..d7e20cdb7031 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_local_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_local_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_managed_fields_entry.py b/contrib/python/kubernetes/kubernetes/client/models/v1_managed_fields_entry.py index 4ebf5c1f3a39..17532f6cb1f7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_managed_fields_entry.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_managed_fields_entry.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_match_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_match_condition.py index ad1c26b72415..2c0485628677 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_match_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_match_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_match_resources.py b/contrib/python/kubernetes/kubernetes/client/models/v1_match_resources.py index fc1296676ae4..4fd99d647ee6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_match_resources.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_match_resources.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_modify_volume_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_modify_volume_status.py index 065a10bf5f45..713cd5d2bf7b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_modify_volume_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_modify_volume_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook.py b/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook.py index df61a49c4597..cb4b86b015b6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration.py index 05694d6397f6..f0755b874f8e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration_list.py index 095cc0434776..526e8e939f95 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_mutating_webhook_configuration_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_named_rule_with_operations.py b/contrib/python/kubernetes/kubernetes/client/models/v1_named_rule_with_operations.py index 4e4ffb823379..04f9ee1c5ec2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_named_rule_with_operations.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_named_rule_with_operations.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace.py b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace.py index f312d7b41382..cbda60af4072 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_condition.py index b903f378a3e8..a342914f774f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_list.py index 91ffbf9ed43b..4c31f7a19f59 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_spec.py index 44d6c7fed34b..ab9a0d0308c5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_status.py index 0af7f5b63321..b154803fe09e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_namespace_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy.py index bfda1e92d009..f90bb0070f71 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_egress_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_egress_rule.py index 3f569bb34bd8..eda7ef1f466d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_egress_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_egress_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_ingress_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_ingress_rule.py index b79dfd852070..96dc0973a917 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_ingress_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_ingress_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_list.py index c9ae518574a1..4e302bc220dd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_peer.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_peer.py index c9c5751ea5ae..d49a81360f7f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_peer.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_peer.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_port.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_port.py index 794f66a2cdf1..69a8a02ff264 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_port.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_port.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_spec.py index b17e6e7c0716..404f1f4b9928 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_network_policy_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_nfs_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_nfs_volume_source.py index f833fce4da89..8c9ccfcbd0c7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_nfs_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_nfs_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node.py index 8c5a525c2c01..a41a077bb870 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_address.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_address.py index 448526f55976..a5b4cdcd7342 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_address.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_address.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_affinity.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_affinity.py index ba83fe83516c..52abd5eabdce 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_affinity.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_affinity.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_condition.py index dfab630ad457..1da94ac87b8a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_source.py index 1d42de997684..9f5fe3a22420 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_status.py index 4e662e93a009..34359d547a9a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_config_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_daemon_endpoints.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_daemon_endpoints.py index b17358270996..0b8941c3df59 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_daemon_endpoints.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_daemon_endpoints.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_features.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_features.py index 5240c0c7d214..294febb2541f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_features.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_features.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_list.py index 1388d3565156..6a1df68b56f1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler.py index 2cec08a993e9..cdd7ec6e8383 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler_features.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler_features.py index b50ec1e1cfd5..bff5623128b0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler_features.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_runtime_handler_features.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector.py index ab0424b1d6ee..441335e6f1e5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_requirement.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_requirement.py index 8aa23aa7100c..fe05c009335f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_requirement.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_requirement.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_term.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_term.py index 92ecc79da0ae..71d15aa4e36a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_term.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_selector_term.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_spec.py index 1b7da48f9f4c..f440ab66c5db 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_status.py index 2ebfb535ef65..5bf9602a797c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1beta1_self_subject_review_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_swap_status.py similarity index 68% rename from contrib/python/kubernetes/kubernetes/client/models/v1beta1_self_subject_review_status.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_node_swap_status.py index 4d8a13c28430..20908eab15e6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1beta1_self_subject_review_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_swap_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1beta1SelfSubjectReviewStatus(object): +class V1NodeSwapStatus(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -33,45 +33,47 @@ class V1beta1SelfSubjectReviewStatus(object): and the value is json key in definition. """ openapi_types = { - 'user_info': 'V1UserInfo' + 'capacity': 'int' } attribute_map = { - 'user_info': 'userInfo' + 'capacity': 'capacity' } - def __init__(self, user_info=None, local_vars_configuration=None): # noqa: E501 - """V1beta1SelfSubjectReviewStatus - a model defined in OpenAPI""" # noqa: E501 + def __init__(self, capacity=None, local_vars_configuration=None): # noqa: E501 + """V1NodeSwapStatus - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration - self._user_info = None + self._capacity = None self.discriminator = None - if user_info is not None: - self.user_info = user_info + if capacity is not None: + self.capacity = capacity @property - def user_info(self): - """Gets the user_info of this V1beta1SelfSubjectReviewStatus. # noqa: E501 + def capacity(self): + """Gets the capacity of this V1NodeSwapStatus. # noqa: E501 + Total amount of swap memory in bytes. # noqa: E501 - :return: The user_info of this V1beta1SelfSubjectReviewStatus. # noqa: E501 - :rtype: V1UserInfo + :return: The capacity of this V1NodeSwapStatus. # noqa: E501 + :rtype: int """ - return self._user_info + return self._capacity - @user_info.setter - def user_info(self, user_info): - """Sets the user_info of this V1beta1SelfSubjectReviewStatus. + @capacity.setter + def capacity(self, capacity): + """Sets the capacity of this V1NodeSwapStatus. + Total amount of swap memory in bytes. # noqa: E501 - :param user_info: The user_info of this V1beta1SelfSubjectReviewStatus. # noqa: E501 - :type: V1UserInfo + :param capacity: The capacity of this V1NodeSwapStatus. # noqa: E501 + :type: int """ - self._user_info = user_info + self._capacity = capacity def to_dict(self): """Returns the model properties as a dict""" @@ -107,14 +109,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1beta1SelfSubjectReviewStatus): + if not isinstance(other, V1NodeSwapStatus): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1beta1SelfSubjectReviewStatus): + if not isinstance(other, V1NodeSwapStatus): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_node_system_info.py b/contrib/python/kubernetes/kubernetes/client/models/v1_node_system_info.py index f41f065fa0c1..8aec82b3f8b4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_node_system_info.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_node_system_info.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -42,6 +42,7 @@ class V1NodeSystemInfo(object): 'machine_id': 'str', 'operating_system': 'str', 'os_image': 'str', + 'swap': 'V1NodeSwapStatus', 'system_uuid': 'str' } @@ -55,10 +56,11 @@ class V1NodeSystemInfo(object): 'machine_id': 'machineID', 'operating_system': 'operatingSystem', 'os_image': 'osImage', + 'swap': 'swap', 'system_uuid': 'systemUUID' } - def __init__(self, architecture=None, boot_id=None, container_runtime_version=None, kernel_version=None, kube_proxy_version=None, kubelet_version=None, machine_id=None, operating_system=None, os_image=None, system_uuid=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, architecture=None, boot_id=None, container_runtime_version=None, kernel_version=None, kube_proxy_version=None, kubelet_version=None, machine_id=None, operating_system=None, os_image=None, swap=None, system_uuid=None, local_vars_configuration=None): # noqa: E501 """V1NodeSystemInfo - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -73,6 +75,7 @@ def __init__(self, architecture=None, boot_id=None, container_runtime_version=No self._machine_id = None self._operating_system = None self._os_image = None + self._swap = None self._system_uuid = None self.discriminator = None @@ -85,6 +88,8 @@ def __init__(self, architecture=None, boot_id=None, container_runtime_version=No self.machine_id = machine_id self.operating_system = operating_system self.os_image = os_image + if swap is not None: + self.swap = swap self.system_uuid = system_uuid @property @@ -312,6 +317,27 @@ def os_image(self, os_image): self._os_image = os_image + @property + def swap(self): + """Gets the swap of this V1NodeSystemInfo. # noqa: E501 + + + :return: The swap of this V1NodeSystemInfo. # noqa: E501 + :rtype: V1NodeSwapStatus + """ + return self._swap + + @swap.setter + def swap(self, swap): + """Sets the swap of this V1NodeSystemInfo. + + + :param swap: The swap of this V1NodeSystemInfo. # noqa: E501 + :type: V1NodeSwapStatus + """ + + self._swap = swap + @property def system_uuid(self): """Gets the system_uuid of this V1NodeSystemInfo. # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_attributes.py b/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_attributes.py index ef28d540ea13..d10efbb7390b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_attributes.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_attributes.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_policy_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_policy_rule.py index 70204e65b430..3cb6bc676511 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_policy_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_policy_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_rule.py index 9bfbeab0cc24..79478d795817 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_non_resource_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_object_field_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_object_field_selector.py index 469c63614d53..f33086d6dccb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_object_field_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_object_field_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_object_meta.py b/contrib/python/kubernetes/kubernetes/client/models/v1_object_meta.py index 5de4b2f56c2b..90bf830de997 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_object_meta.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_object_meta.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_object_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_object_reference.py index 317a1ae5e7d6..337980dd4d9d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_object_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_object_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_overhead.py b/contrib/python/kubernetes/kubernetes/client/models/v1_overhead.py index a4cd9b9f2c26..ada4101ead1d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_overhead.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_overhead.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_owner_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_owner_reference.py index a137e6d6d62f..0e943ae9eeab 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_owner_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_owner_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_param_kind.py b/contrib/python/kubernetes/kubernetes/client/models/v1_param_kind.py index 45f19ff992e5..dab1990d1651 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_param_kind.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_param_kind.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_param_ref.py b/contrib/python/kubernetes/kubernetes/client/models/v1_param_ref.py index a935c2516d3b..48edb3ab54d9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_param_ref.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_param_ref.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_parent_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_parent_reference.py similarity index 77% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_parent_reference.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_parent_reference.py index 4ccb9d5e7f73..9988b506473c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_parent_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_parent_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1ParentReference(object): +class V1ParentReference(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -47,7 +47,7 @@ class V1alpha1ParentReference(object): } def __init__(self, group=None, name=None, namespace=None, resource=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ParentReference - a model defined in OpenAPI""" # noqa: E501 + """V1ParentReference - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -67,22 +67,22 @@ def __init__(self, group=None, name=None, namespace=None, resource=None, local_v @property def group(self): - """Gets the group of this V1alpha1ParentReference. # noqa: E501 + """Gets the group of this V1ParentReference. # noqa: E501 Group is the group of the object being referenced. # noqa: E501 - :return: The group of this V1alpha1ParentReference. # noqa: E501 + :return: The group of this V1ParentReference. # noqa: E501 :rtype: str """ return self._group @group.setter def group(self, group): - """Sets the group of this V1alpha1ParentReference. + """Sets the group of this V1ParentReference. Group is the group of the object being referenced. # noqa: E501 - :param group: The group of this V1alpha1ParentReference. # noqa: E501 + :param group: The group of this V1ParentReference. # noqa: E501 :type: str """ @@ -90,22 +90,22 @@ def group(self, group): @property def name(self): - """Gets the name of this V1alpha1ParentReference. # noqa: E501 + """Gets the name of this V1ParentReference. # noqa: E501 Name is the name of the object being referenced. # noqa: E501 - :return: The name of this V1alpha1ParentReference. # noqa: E501 + :return: The name of this V1ParentReference. # noqa: E501 :rtype: str """ return self._name @name.setter def name(self, name): - """Sets the name of this V1alpha1ParentReference. + """Sets the name of this V1ParentReference. Name is the name of the object being referenced. # noqa: E501 - :param name: The name of this V1alpha1ParentReference. # noqa: E501 + :param name: The name of this V1ParentReference. # noqa: E501 :type: str """ if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 @@ -115,22 +115,22 @@ def name(self, name): @property def namespace(self): - """Gets the namespace of this V1alpha1ParentReference. # noqa: E501 + """Gets the namespace of this V1ParentReference. # noqa: E501 Namespace is the namespace of the object being referenced. # noqa: E501 - :return: The namespace of this V1alpha1ParentReference. # noqa: E501 + :return: The namespace of this V1ParentReference. # noqa: E501 :rtype: str """ return self._namespace @namespace.setter def namespace(self, namespace): - """Sets the namespace of this V1alpha1ParentReference. + """Sets the namespace of this V1ParentReference. Namespace is the namespace of the object being referenced. # noqa: E501 - :param namespace: The namespace of this V1alpha1ParentReference. # noqa: E501 + :param namespace: The namespace of this V1ParentReference. # noqa: E501 :type: str """ @@ -138,22 +138,22 @@ def namespace(self, namespace): @property def resource(self): - """Gets the resource of this V1alpha1ParentReference. # noqa: E501 + """Gets the resource of this V1ParentReference. # noqa: E501 Resource is the resource of the object being referenced. # noqa: E501 - :return: The resource of this V1alpha1ParentReference. # noqa: E501 + :return: The resource of this V1ParentReference. # noqa: E501 :rtype: str """ return self._resource @resource.setter def resource(self, resource): - """Sets the resource of this V1alpha1ParentReference. + """Sets the resource of this V1ParentReference. Resource is the resource of the object being referenced. # noqa: E501 - :param resource: The resource of this V1alpha1ParentReference. # noqa: E501 + :param resource: The resource of this V1ParentReference. # noqa: E501 :type: str """ if self.local_vars_configuration.client_side_validation and resource is None: # noqa: E501 @@ -195,14 +195,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ParentReference): + if not isinstance(other, V1ParentReference): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ParentReference): + if not isinstance(other, V1ParentReference): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume.py index ec88e6dc7cd3..d59ebf91d9d7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim.py index 2143e90130ff..2ca5c141b9ce 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_condition.py index cbcc3740edc2..62d574146892 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_list.py index 4cdd3bd44366..4233a1186659 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_spec.py index 384acf117c72..86cbb6931fb6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_status.py index c445843ddbef..07287a48bd63 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_template.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_template.py index b3e169ed2729..416fbed96582 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_template.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_template.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_volume_source.py index f6e81d19b325..18a63c1c9eab 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_claim_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_list.py index 93392e360634..dcfaad94c93b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_spec.py index 52dbe9fde9d4..731924c0415d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_status.py index 63d81393c276..56b176514825 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_persistent_volume_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_photon_persistent_disk_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_photon_persistent_disk_volume_source.py index 392f03c19a22..77bf33c7ff00 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_photon_persistent_disk_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_photon_persistent_disk_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod.py index e37d37efae55..302fdb774e53 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity.py index ead609e1f02f..a8308d8280bd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity_term.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity_term.py index d60130782c47..5ca260bd8418 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity_term.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_affinity_term.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -101,7 +101,7 @@ def label_selector(self, label_selector): def match_label_keys(self): """Gets the match_label_keys of this V1PodAffinityTerm. # noqa: E501 - MatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both matchLabelKeys and labelSelector. Also, matchLabelKeys cannot be set when labelSelector isn't set. This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default). # noqa: E501 + MatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both matchLabelKeys and labelSelector. Also, matchLabelKeys cannot be set when labelSelector isn't set. # noqa: E501 :return: The match_label_keys of this V1PodAffinityTerm. # noqa: E501 :rtype: list[str] @@ -112,7 +112,7 @@ def match_label_keys(self): def match_label_keys(self, match_label_keys): """Sets the match_label_keys of this V1PodAffinityTerm. - MatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both matchLabelKeys and labelSelector. Also, matchLabelKeys cannot be set when labelSelector isn't set. This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default). # noqa: E501 + MatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both matchLabelKeys and labelSelector. Also, matchLabelKeys cannot be set when labelSelector isn't set. # noqa: E501 :param match_label_keys: The match_label_keys of this V1PodAffinityTerm. # noqa: E501 :type: list[str] @@ -124,7 +124,7 @@ def match_label_keys(self, match_label_keys): def mismatch_label_keys(self): """Gets the mismatch_label_keys of this V1PodAffinityTerm. # noqa: E501 - MismatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both mismatchLabelKeys and labelSelector. Also, mismatchLabelKeys cannot be set when labelSelector isn't set. This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default). # noqa: E501 + MismatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both mismatchLabelKeys and labelSelector. Also, mismatchLabelKeys cannot be set when labelSelector isn't set. # noqa: E501 :return: The mismatch_label_keys of this V1PodAffinityTerm. # noqa: E501 :rtype: list[str] @@ -135,7 +135,7 @@ def mismatch_label_keys(self): def mismatch_label_keys(self, mismatch_label_keys): """Sets the mismatch_label_keys of this V1PodAffinityTerm. - MismatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both mismatchLabelKeys and labelSelector. Also, mismatchLabelKeys cannot be set when labelSelector isn't set. This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default). # noqa: E501 + MismatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both mismatchLabelKeys and labelSelector. Also, mismatchLabelKeys cannot be set when labelSelector isn't set. # noqa: E501 :param mismatch_label_keys: The mismatch_label_keys of this V1PodAffinityTerm. # noqa: E501 :type: list[str] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_anti_affinity.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_anti_affinity.py index 19319edac3b6..71b5309c73d8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_anti_affinity.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_anti_affinity.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_condition.py index 13a3c80f2f02..df58dd580e81 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -36,6 +36,7 @@ class V1PodCondition(object): 'last_probe_time': 'datetime', 'last_transition_time': 'datetime', 'message': 'str', + 'observed_generation': 'int', 'reason': 'str', 'status': 'str', 'type': 'str' @@ -45,12 +46,13 @@ class V1PodCondition(object): 'last_probe_time': 'lastProbeTime', 'last_transition_time': 'lastTransitionTime', 'message': 'message', + 'observed_generation': 'observedGeneration', 'reason': 'reason', 'status': 'status', 'type': 'type' } - def __init__(self, last_probe_time=None, last_transition_time=None, message=None, reason=None, status=None, type=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, last_probe_time=None, last_transition_time=None, message=None, observed_generation=None, reason=None, status=None, type=None, local_vars_configuration=None): # noqa: E501 """V1PodCondition - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -59,6 +61,7 @@ def __init__(self, last_probe_time=None, last_transition_time=None, message=None self._last_probe_time = None self._last_transition_time = None self._message = None + self._observed_generation = None self._reason = None self._status = None self._type = None @@ -70,6 +73,8 @@ def __init__(self, last_probe_time=None, last_transition_time=None, message=None self.last_transition_time = last_transition_time if message is not None: self.message = message + if observed_generation is not None: + self.observed_generation = observed_generation if reason is not None: self.reason = reason self.status = status @@ -144,6 +149,29 @@ def message(self, message): self._message = message + @property + def observed_generation(self): + """Gets the observed_generation of this V1PodCondition. # noqa: E501 + + If set, this represents the .metadata.generation that the pod condition was set based upon. This is an alpha field. Enable PodObservedGenerationTracking to be able to use this field. # noqa: E501 + + :return: The observed_generation of this V1PodCondition. # noqa: E501 + :rtype: int + """ + return self._observed_generation + + @observed_generation.setter + def observed_generation(self, observed_generation): + """Sets the observed_generation of this V1PodCondition. + + If set, this represents the .metadata.generation that the pod condition was set based upon. This is an alpha field. Enable PodObservedGenerationTracking to be able to use this field. # noqa: E501 + + :param observed_generation: The observed_generation of this V1PodCondition. # noqa: E501 + :type: int + """ + + self._observed_generation = observed_generation + @property def reason(self): """Gets the reason of this V1PodCondition. # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget.py index e0ee3e9ba05f..f4ced43577f1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_list.py index 19dc5298a825..1a9bfd038a65 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_spec.py index 6d9abd2ad2a0..b1ccd90ef235 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -138,7 +138,7 @@ def selector(self, selector): def unhealthy_pod_eviction_policy(self): """Gets the unhealthy_pod_eviction_policy of this V1PodDisruptionBudgetSpec. # noqa: E501 - UnhealthyPodEvictionPolicy defines the criteria for when unhealthy pods should be considered for eviction. Current implementation considers healthy pods, as pods that have status.conditions item with type=\"Ready\",status=\"True\". Valid policies are IfHealthyBudget and AlwaysAllow. If no policy is specified, the default behavior will be used, which corresponds to the IfHealthyBudget policy. IfHealthyBudget policy means that running pods (status.phase=\"Running\"), but not yet healthy can be evicted only if the guarded application is not disrupted (status.currentHealthy is at least equal to status.desiredHealthy). Healthy pods will be subject to the PDB for eviction. AlwaysAllow policy means that all running pods (status.phase=\"Running\"), but not yet healthy are considered disrupted and can be evicted regardless of whether the criteria in a PDB is met. This means perspective running pods of a disrupted application might not get a chance to become healthy. Healthy pods will be subject to the PDB for eviction. Additional policies may be added in the future. Clients making eviction decisions should disallow eviction of unhealthy pods if they encounter an unrecognized policy in this field. This field is beta-level. The eviction API uses this field when the feature gate PDBUnhealthyPodEvictionPolicy is enabled (enabled by default). # noqa: E501 + UnhealthyPodEvictionPolicy defines the criteria for when unhealthy pods should be considered for eviction. Current implementation considers healthy pods, as pods that have status.conditions item with type=\"Ready\",status=\"True\". Valid policies are IfHealthyBudget and AlwaysAllow. If no policy is specified, the default behavior will be used, which corresponds to the IfHealthyBudget policy. IfHealthyBudget policy means that running pods (status.phase=\"Running\"), but not yet healthy can be evicted only if the guarded application is not disrupted (status.currentHealthy is at least equal to status.desiredHealthy). Healthy pods will be subject to the PDB for eviction. AlwaysAllow policy means that all running pods (status.phase=\"Running\"), but not yet healthy are considered disrupted and can be evicted regardless of whether the criteria in a PDB is met. This means perspective running pods of a disrupted application might not get a chance to become healthy. Healthy pods will be subject to the PDB for eviction. Additional policies may be added in the future. Clients making eviction decisions should disallow eviction of unhealthy pods if they encounter an unrecognized policy in this field. # noqa: E501 :return: The unhealthy_pod_eviction_policy of this V1PodDisruptionBudgetSpec. # noqa: E501 :rtype: str @@ -149,7 +149,7 @@ def unhealthy_pod_eviction_policy(self): def unhealthy_pod_eviction_policy(self, unhealthy_pod_eviction_policy): """Sets the unhealthy_pod_eviction_policy of this V1PodDisruptionBudgetSpec. - UnhealthyPodEvictionPolicy defines the criteria for when unhealthy pods should be considered for eviction. Current implementation considers healthy pods, as pods that have status.conditions item with type=\"Ready\",status=\"True\". Valid policies are IfHealthyBudget and AlwaysAllow. If no policy is specified, the default behavior will be used, which corresponds to the IfHealthyBudget policy. IfHealthyBudget policy means that running pods (status.phase=\"Running\"), but not yet healthy can be evicted only if the guarded application is not disrupted (status.currentHealthy is at least equal to status.desiredHealthy). Healthy pods will be subject to the PDB for eviction. AlwaysAllow policy means that all running pods (status.phase=\"Running\"), but not yet healthy are considered disrupted and can be evicted regardless of whether the criteria in a PDB is met. This means perspective running pods of a disrupted application might not get a chance to become healthy. Healthy pods will be subject to the PDB for eviction. Additional policies may be added in the future. Clients making eviction decisions should disallow eviction of unhealthy pods if they encounter an unrecognized policy in this field. This field is beta-level. The eviction API uses this field when the feature gate PDBUnhealthyPodEvictionPolicy is enabled (enabled by default). # noqa: E501 + UnhealthyPodEvictionPolicy defines the criteria for when unhealthy pods should be considered for eviction. Current implementation considers healthy pods, as pods that have status.conditions item with type=\"Ready\",status=\"True\". Valid policies are IfHealthyBudget and AlwaysAllow. If no policy is specified, the default behavior will be used, which corresponds to the IfHealthyBudget policy. IfHealthyBudget policy means that running pods (status.phase=\"Running\"), but not yet healthy can be evicted only if the guarded application is not disrupted (status.currentHealthy is at least equal to status.desiredHealthy). Healthy pods will be subject to the PDB for eviction. AlwaysAllow policy means that all running pods (status.phase=\"Running\"), but not yet healthy are considered disrupted and can be evicted regardless of whether the criteria in a PDB is met. This means perspective running pods of a disrupted application might not get a chance to become healthy. Healthy pods will be subject to the PDB for eviction. Additional policies may be added in the future. Clients making eviction decisions should disallow eviction of unhealthy pods if they encounter an unrecognized policy in this field. # noqa: E501 :param unhealthy_pod_eviction_policy: The unhealthy_pod_eviction_policy of this V1PodDisruptionBudgetSpec. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_status.py index d7983fa43ef8..1f4913b5430e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_disruption_budget_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config.py index 860952a40b63..1de3ef23f619 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config_option.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config_option.py index 5cc15db4ccb1..253861a9cfe9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config_option.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_dns_config_option.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy.py index 72f6833f18a8..24735a7552d6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_exit_codes_requirement.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_exit_codes_requirement.py index 0718a04dc152..b22aad2424a9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_exit_codes_requirement.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_exit_codes_requirement.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_pod_conditions_pattern.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_pod_conditions_pattern.py index 92e84b3f1c72..8bff4188591c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_pod_conditions_pattern.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_on_pod_conditions_pattern.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_rule.py index 366232e56568..dd7593afb7fe 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_failure_policy_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -65,7 +65,7 @@ def __init__(self, action=None, on_exit_codes=None, on_pod_conditions=None, loca def action(self): """Gets the action of this V1PodFailurePolicyRule. # noqa: E501 - Specifies the action taken on a pod failure when the requirements are satisfied. Possible values are: - FailJob: indicates that the pod's job is marked as Failed and all running pods are terminated. - FailIndex: indicates that the pod's index is marked as Failed and will not be restarted. This value is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). - Ignore: indicates that the counter towards the .backoffLimit is not incremented and a replacement pod is created. - Count: indicates that the pod is handled in the default way - the counter towards the .backoffLimit is incremented. Additional values are considered to be added in the future. Clients should react to an unknown action by skipping the rule. # noqa: E501 + Specifies the action taken on a pod failure when the requirements are satisfied. Possible values are: - FailJob: indicates that the pod's job is marked as Failed and all running pods are terminated. - FailIndex: indicates that the pod's index is marked as Failed and will not be restarted. - Ignore: indicates that the counter towards the .backoffLimit is not incremented and a replacement pod is created. - Count: indicates that the pod is handled in the default way - the counter towards the .backoffLimit is incremented. Additional values are considered to be added in the future. Clients should react to an unknown action by skipping the rule. # noqa: E501 :return: The action of this V1PodFailurePolicyRule. # noqa: E501 :rtype: str @@ -76,7 +76,7 @@ def action(self): def action(self, action): """Sets the action of this V1PodFailurePolicyRule. - Specifies the action taken on a pod failure when the requirements are satisfied. Possible values are: - FailJob: indicates that the pod's job is marked as Failed and all running pods are terminated. - FailIndex: indicates that the pod's index is marked as Failed and will not be restarted. This value is beta-level. It can be used when the `JobBackoffLimitPerIndex` feature gate is enabled (enabled by default). - Ignore: indicates that the counter towards the .backoffLimit is not incremented and a replacement pod is created. - Count: indicates that the pod is handled in the default way - the counter towards the .backoffLimit is incremented. Additional values are considered to be added in the future. Clients should react to an unknown action by skipping the rule. # noqa: E501 + Specifies the action taken on a pod failure when the requirements are satisfied. Possible values are: - FailJob: indicates that the pod's job is marked as Failed and all running pods are terminated. - FailIndex: indicates that the pod's index is marked as Failed and will not be restarted. - Ignore: indicates that the counter towards the .backoffLimit is not incremented and a replacement pod is created. - Count: indicates that the pod is handled in the default way - the counter towards the .backoffLimit is incremented. Additional values are considered to be added in the future. Clients should react to an unknown action by skipping the rule. # noqa: E501 :param action: The action of this V1PodFailurePolicyRule. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_ip.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_ip.py index 1f006912610f..9527215cff2b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_ip.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_ip.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_list.py index 8904c1f94bc6..c5f5506b68a7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_os.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_os.py index 546aaed19e1b..79d212fc47bd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_os.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_os.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_readiness_gate.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_readiness_gate.py index 1f42e29489d1..6d8f4b227bbf 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_readiness_gate.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_readiness_gate.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim.py index e8f4bc3d7f8f..27346a5b424d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim_status.py index 2ce3e6af69b4..fb2ff9c27a51 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_resource_claim_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_scheduling_gate.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_scheduling_gate.py index 50d5925b4f16..91e65caeb531 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_scheduling_gate.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_scheduling_gate.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_security_context.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_security_context.py index 1473bf1d8018..f131057672f0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_security_context.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_security_context.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_spec.py index 9d891f558e01..d3af12396948 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -593,7 +593,7 @@ def image_pull_secrets(self, image_pull_secrets): def init_containers(self): """Gets the init_containers of this V1PodSpec. # noqa: E501 - List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, Liveness probes, or Startup probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ # noqa: E501 + List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, Liveness probes, or Startup probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ # noqa: E501 :return: The init_containers of this V1PodSpec. # noqa: E501 :rtype: list[V1Container] @@ -604,7 +604,7 @@ def init_containers(self): def init_containers(self, init_containers): """Sets the init_containers of this V1PodSpec. - List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, Liveness probes, or Startup probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ # noqa: E501 + List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, Liveness probes, or Startup probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ # noqa: E501 :param init_containers: The init_containers of this V1PodSpec. # noqa: E501 :type: list[V1Container] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_status.py index 6ce0d330be12..4430e2dfafd5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -41,6 +41,7 @@ class V1PodStatus(object): 'init_container_statuses': 'list[V1ContainerStatus]', 'message': 'str', 'nominated_node_name': 'str', + 'observed_generation': 'int', 'phase': 'str', 'pod_ip': 'str', 'pod_i_ps': 'list[V1PodIP]', @@ -60,6 +61,7 @@ class V1PodStatus(object): 'init_container_statuses': 'initContainerStatuses', 'message': 'message', 'nominated_node_name': 'nominatedNodeName', + 'observed_generation': 'observedGeneration', 'phase': 'phase', 'pod_ip': 'podIP', 'pod_i_ps': 'podIPs', @@ -70,7 +72,7 @@ class V1PodStatus(object): 'start_time': 'startTime' } - def __init__(self, conditions=None, container_statuses=None, ephemeral_container_statuses=None, host_ip=None, host_i_ps=None, init_container_statuses=None, message=None, nominated_node_name=None, phase=None, pod_ip=None, pod_i_ps=None, qos_class=None, reason=None, resize=None, resource_claim_statuses=None, start_time=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, conditions=None, container_statuses=None, ephemeral_container_statuses=None, host_ip=None, host_i_ps=None, init_container_statuses=None, message=None, nominated_node_name=None, observed_generation=None, phase=None, pod_ip=None, pod_i_ps=None, qos_class=None, reason=None, resize=None, resource_claim_statuses=None, start_time=None, local_vars_configuration=None): # noqa: E501 """V1PodStatus - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -84,6 +86,7 @@ def __init__(self, conditions=None, container_statuses=None, ephemeral_container self._init_container_statuses = None self._message = None self._nominated_node_name = None + self._observed_generation = None self._phase = None self._pod_ip = None self._pod_i_ps = None @@ -110,6 +113,8 @@ def __init__(self, conditions=None, container_statuses=None, ephemeral_container self.message = message if nominated_node_name is not None: self.nominated_node_name = nominated_node_name + if observed_generation is not None: + self.observed_generation = observed_generation if phase is not None: self.phase = phase if pod_ip is not None: @@ -311,6 +316,29 @@ def nominated_node_name(self, nominated_node_name): self._nominated_node_name = nominated_node_name + @property + def observed_generation(self): + """Gets the observed_generation of this V1PodStatus. # noqa: E501 + + If set, this represents the .metadata.generation that the pod status was set based upon. This is an alpha field. Enable PodObservedGenerationTracking to be able to use this field. # noqa: E501 + + :return: The observed_generation of this V1PodStatus. # noqa: E501 + :rtype: int + """ + return self._observed_generation + + @observed_generation.setter + def observed_generation(self, observed_generation): + """Sets the observed_generation of this V1PodStatus. + + If set, this represents the .metadata.generation that the pod status was set based upon. This is an alpha field. Enable PodObservedGenerationTracking to be able to use this field. # noqa: E501 + + :param observed_generation: The observed_generation of this V1PodStatus. # noqa: E501 + :type: int + """ + + self._observed_generation = observed_generation + @property def phase(self): """Gets the phase of this V1PodStatus. # noqa: E501 @@ -430,7 +458,7 @@ def reason(self, reason): def resize(self): """Gets the resize of this V1PodStatus. # noqa: E501 - Status of resources resize desired for pod's containers. It is empty if no resources resize is pending. Any changes to container resources will automatically set this to \"Proposed\" # noqa: E501 + Status of resources resize desired for pod's containers. It is empty if no resources resize is pending. Any changes to container resources will automatically set this to \"Proposed\" Deprecated: Resize status is moved to two pod conditions PodResizePending and PodResizeInProgress. PodResizePending will track states where the spec has been resized, but the Kubelet has not yet allocated the resources. PodResizeInProgress will track in-progress resizes, and should be present whenever allocated resources != acknowledged resources. # noqa: E501 :return: The resize of this V1PodStatus. # noqa: E501 :rtype: str @@ -441,7 +469,7 @@ def resize(self): def resize(self, resize): """Sets the resize of this V1PodStatus. - Status of resources resize desired for pod's containers. It is empty if no resources resize is pending. Any changes to container resources will automatically set this to \"Proposed\" # noqa: E501 + Status of resources resize desired for pod's containers. It is empty if no resources resize is pending. Any changes to container resources will automatically set this to \"Proposed\" Deprecated: Resize status is moved to two pod conditions PodResizePending and PodResizeInProgress. PodResizePending will track states where the spec has been resized, but the Kubelet has not yet allocated the resources. PodResizeInProgress will track in-progress resizes, and should be present whenever allocated resources != acknowledged resources. # noqa: E501 :param resize: The resize of this V1PodStatus. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template.py index 67fc9d1a0273..4589badf6009 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_list.py index ec737ed0dbd4..e98ab25d31c2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_spec.py index 8a85a0b1821b..62457ca97262 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_pod_template_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rule.py index ca351fabaf84..acd22b65f620 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rules_with_subjects.py b/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rules_with_subjects.py index b96fa4f4865d..ecac0a65ebd0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rules_with_subjects.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_policy_rules_with_subjects.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_port_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_port_status.py index 11c6ed8f8075..320d980a34ea 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_port_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_port_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_portworx_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_portworx_volume_source.py index ab8830fd3fd4..d86ecbf68c85 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_portworx_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_portworx_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_preconditions.py b/contrib/python/kubernetes/kubernetes/client/models/v1_preconditions.py index fb17e34cee13..e30303ca2d93 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_preconditions.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_preconditions.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_preferred_scheduling_term.py b/contrib/python/kubernetes/kubernetes/client/models/v1_preferred_scheduling_term.py index 76f4b81f861f..fd66bb2eff5b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_preferred_scheduling_term.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_preferred_scheduling_term.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class.py index 44d734fd25e4..d6808b4d827e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class_list.py index 125f9fe94e27..4ceece8c780b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_class_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration.py index 4586c19f5efc..d55245890270 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_condition.py index 4ed39cd7ec55..6b586855c5cb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_list.py index 8ad2c415d64d..1529ccc6c802 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_reference.py index a2c86d4571be..ea048377d49e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_spec.py index ca4ac1306b39..8d1a7bf1f351 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_status.py index 1084e9ff69db..38f51b9198e9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_priority_level_configuration_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_probe.py b/contrib/python/kubernetes/kubernetes/client/models/v1_probe.py index b123151e006f..c71ec51ef0ef 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_probe.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_probe.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_projected_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_projected_volume_source.py index 4ab8ec24ef11..268623cdc286 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_projected_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_projected_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_queuing_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_queuing_configuration.py index 167375aa47d2..a5644ba58b37 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_queuing_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_queuing_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_quobyte_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_quobyte_volume_source.py index ac7f924e2656..fec13447fd3b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_quobyte_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_quobyte_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_persistent_volume_source.py index 8e909cf74158..fee7c44076f8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_volume_source.py index e4e4da5a4fa0..e47f43e2903f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_rbd_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set.py index da2795ca56a4..91080ff54b1b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_condition.py index c7e044c2b515..ac88cabc7cca 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_list.py index 92aaf2a7482f..c6bf9bd52a00 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -93,7 +93,7 @@ def api_version(self, api_version): def items(self): """Gets the items of this V1ReplicaSetList. # noqa: E501 - List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller # noqa: E501 + List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset # noqa: E501 :return: The items of this V1ReplicaSetList. # noqa: E501 :rtype: list[V1ReplicaSet] @@ -104,7 +104,7 @@ def items(self): def items(self, items): """Sets the items of this V1ReplicaSetList. - List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller # noqa: E501 + List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset # noqa: E501 :param items: The items of this V1ReplicaSetList. # noqa: E501 :type: list[V1ReplicaSet] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_spec.py index 88400f8b2a17..db07c4f84db5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -93,7 +93,7 @@ def min_ready_seconds(self, min_ready_seconds): def replicas(self): """Gets the replicas of this V1ReplicaSetSpec. # noqa: E501 - Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller # noqa: E501 + Replicas is the number of desired pods. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset # noqa: E501 :return: The replicas of this V1ReplicaSetSpec. # noqa: E501 :rtype: int @@ -104,7 +104,7 @@ def replicas(self): def replicas(self, replicas): """Sets the replicas of this V1ReplicaSetSpec. - Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller # noqa: E501 + Replicas is the number of desired pods. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset # noqa: E501 :param replicas: The replicas of this V1ReplicaSetSpec. # noqa: E501 :type: int diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_status.py index 23aec080c91f..55ae0741f3d0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replica_set_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -38,7 +38,8 @@ class V1ReplicaSetStatus(object): 'fully_labeled_replicas': 'int', 'observed_generation': 'int', 'ready_replicas': 'int', - 'replicas': 'int' + 'replicas': 'int', + 'terminating_replicas': 'int' } attribute_map = { @@ -47,10 +48,11 @@ class V1ReplicaSetStatus(object): 'fully_labeled_replicas': 'fullyLabeledReplicas', 'observed_generation': 'observedGeneration', 'ready_replicas': 'readyReplicas', - 'replicas': 'replicas' + 'replicas': 'replicas', + 'terminating_replicas': 'terminatingReplicas' } - def __init__(self, available_replicas=None, conditions=None, fully_labeled_replicas=None, observed_generation=None, ready_replicas=None, replicas=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, available_replicas=None, conditions=None, fully_labeled_replicas=None, observed_generation=None, ready_replicas=None, replicas=None, terminating_replicas=None, local_vars_configuration=None): # noqa: E501 """V1ReplicaSetStatus - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -62,6 +64,7 @@ def __init__(self, available_replicas=None, conditions=None, fully_labeled_repli self._observed_generation = None self._ready_replicas = None self._replicas = None + self._terminating_replicas = None self.discriminator = None if available_replicas is not None: @@ -75,12 +78,14 @@ def __init__(self, available_replicas=None, conditions=None, fully_labeled_repli if ready_replicas is not None: self.ready_replicas = ready_replicas self.replicas = replicas + if terminating_replicas is not None: + self.terminating_replicas = terminating_replicas @property def available_replicas(self): """Gets the available_replicas of this V1ReplicaSetStatus. # noqa: E501 - The number of available replicas (ready for at least minReadySeconds) for this replica set. # noqa: E501 + The number of available non-terminating pods (ready for at least minReadySeconds) for this replica set. # noqa: E501 :return: The available_replicas of this V1ReplicaSetStatus. # noqa: E501 :rtype: int @@ -91,7 +96,7 @@ def available_replicas(self): def available_replicas(self, available_replicas): """Sets the available_replicas of this V1ReplicaSetStatus. - The number of available replicas (ready for at least minReadySeconds) for this replica set. # noqa: E501 + The number of available non-terminating pods (ready for at least minReadySeconds) for this replica set. # noqa: E501 :param available_replicas: The available_replicas of this V1ReplicaSetStatus. # noqa: E501 :type: int @@ -126,7 +131,7 @@ def conditions(self, conditions): def fully_labeled_replicas(self): """Gets the fully_labeled_replicas of this V1ReplicaSetStatus. # noqa: E501 - The number of pods that have labels matching the labels of the pod template of the replicaset. # noqa: E501 + The number of non-terminating pods that have labels matching the labels of the pod template of the replicaset. # noqa: E501 :return: The fully_labeled_replicas of this V1ReplicaSetStatus. # noqa: E501 :rtype: int @@ -137,7 +142,7 @@ def fully_labeled_replicas(self): def fully_labeled_replicas(self, fully_labeled_replicas): """Sets the fully_labeled_replicas of this V1ReplicaSetStatus. - The number of pods that have labels matching the labels of the pod template of the replicaset. # noqa: E501 + The number of non-terminating pods that have labels matching the labels of the pod template of the replicaset. # noqa: E501 :param fully_labeled_replicas: The fully_labeled_replicas of this V1ReplicaSetStatus. # noqa: E501 :type: int @@ -172,7 +177,7 @@ def observed_generation(self, observed_generation): def ready_replicas(self): """Gets the ready_replicas of this V1ReplicaSetStatus. # noqa: E501 - readyReplicas is the number of pods targeted by this ReplicaSet with a Ready Condition. # noqa: E501 + The number of non-terminating pods targeted by this ReplicaSet with a Ready Condition. # noqa: E501 :return: The ready_replicas of this V1ReplicaSetStatus. # noqa: E501 :rtype: int @@ -183,7 +188,7 @@ def ready_replicas(self): def ready_replicas(self, ready_replicas): """Sets the ready_replicas of this V1ReplicaSetStatus. - readyReplicas is the number of pods targeted by this ReplicaSet with a Ready Condition. # noqa: E501 + The number of non-terminating pods targeted by this ReplicaSet with a Ready Condition. # noqa: E501 :param ready_replicas: The ready_replicas of this V1ReplicaSetStatus. # noqa: E501 :type: int @@ -195,7 +200,7 @@ def ready_replicas(self, ready_replicas): def replicas(self): """Gets the replicas of this V1ReplicaSetStatus. # noqa: E501 - Replicas is the most recently observed number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller # noqa: E501 + Replicas is the most recently observed number of non-terminating pods. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset # noqa: E501 :return: The replicas of this V1ReplicaSetStatus. # noqa: E501 :rtype: int @@ -206,7 +211,7 @@ def replicas(self): def replicas(self, replicas): """Sets the replicas of this V1ReplicaSetStatus. - Replicas is the most recently observed number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller # noqa: E501 + Replicas is the most recently observed number of non-terminating pods. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset # noqa: E501 :param replicas: The replicas of this V1ReplicaSetStatus. # noqa: E501 :type: int @@ -216,6 +221,29 @@ def replicas(self, replicas): self._replicas = replicas + @property + def terminating_replicas(self): + """Gets the terminating_replicas of this V1ReplicaSetStatus. # noqa: E501 + + The number of terminating pods for this replica set. Terminating pods have a non-null .metadata.deletionTimestamp and have not yet reached the Failed or Succeeded .status.phase. This is an alpha field. Enable DeploymentReplicaSetTerminatingReplicas to be able to use this field. # noqa: E501 + + :return: The terminating_replicas of this V1ReplicaSetStatus. # noqa: E501 + :rtype: int + """ + return self._terminating_replicas + + @terminating_replicas.setter + def terminating_replicas(self, terminating_replicas): + """Sets the terminating_replicas of this V1ReplicaSetStatus. + + The number of terminating pods for this replica set. Terminating pods have a non-null .metadata.deletionTimestamp and have not yet reached the Failed or Succeeded .status.phase. This is an alpha field. Enable DeploymentReplicaSetTerminatingReplicas to be able to use this field. # noqa: E501 + + :param terminating_replicas: The terminating_replicas of this V1ReplicaSetStatus. # noqa: E501 + :type: int + """ + + self._terminating_replicas = terminating_replicas + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller.py index e49abfb5cf6b..9313e863b6f4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_condition.py index 78fbeb5fa0af..8a868881f386 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_list.py index 0bb81214cf63..f909bf05c547 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_spec.py index 1e817a8caa75..2c2060879343 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_status.py index 0dc800f76277..22c513a73207 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_replication_controller_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_attributes.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_attributes.py index 5894cc1522b5..5595310776e3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_attributes.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_attributes.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_claim.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_claim.py index 0240af162d5a..0e06ae5da0c7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_claim.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_claim.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_field_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_field_selector.py index a27bf72dd7cc..4cbea6833525 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_field_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_field_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_health.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_health.py index 9aea5eab105c..22034411891c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_health.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_health.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_policy_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_policy_rule.py index 08925e83ee7c..c0f590888042 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_policy_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_policy_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota.py index e9071fc424b1..924895060157 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_list.py index 7a10f2fb6870..f0bb0adb42fa 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_spec.py index ef3df9fbd438..604aebda029b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_status.py index 9b6ead84d049..f5b5f89abc03 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_quota_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_requirements.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_requirements.py index c3ebb58d5954..af9958e37759 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_requirements.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_requirements.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_rule.py index a490689bf87d..6d1d08ede5d8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_status.py index 546fd6e82fa8..80092039cf5d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_resource_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_resource_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_role.py b/contrib/python/kubernetes/kubernetes/client/models/v1_role.py index f4c076625d1a..421746d47bcc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_role.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_role.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding.py b/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding.py index 940b70ea9c88..35fa351ec93d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding_list.py index 21df0045ffb6..06a35a76e728 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_role_binding_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_role_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_role_list.py index 6c53ab40c24e..de4f89230d07 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_role_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_role_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_role_ref.py b/contrib/python/kubernetes/kubernetes/client/models/v1_role_ref.py index 2da42d6b3686..bee863ca7cde 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_role_ref.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_role_ref.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_daemon_set.py b/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_daemon_set.py index d161e75601ba..690db4241bb7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_daemon_set.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_daemon_set.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_deployment.py b/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_deployment.py index 11aeb12500e3..bc4fd93303b2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_deployment.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_deployment.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_stateful_set_strategy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_stateful_set_strategy.py index 41ca7fc055d5..bf75c45e757c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_stateful_set_strategy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_rolling_update_stateful_set_strategy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_rule_with_operations.py b/contrib/python/kubernetes/kubernetes/client/models/v1_rule_with_operations.py index 1e52b3fcea58..5c3dbdcf0afc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_rule_with_operations.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_rule_with_operations.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class.py index 66f5972bff50..5a35ab599dda 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class_list.py index d9e6341ca85d..07fca8d13ac4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_runtime_class_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scale.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scale.py index d2265ffceb9f..08830a931569 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scale.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scale.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_persistent_volume_source.py index 21b8697046e0..8e6500f1531c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_volume_source.py index 9eb7badb50be..41be97e15309 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_io_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_spec.py index 423d80bffa91..47a1a5e96c4a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_status.py index c49c996efb79..8042495d950e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scale_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scale_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scheduling.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scheduling.py index 806ae4f3be8b..2e69fa2fb429 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scheduling.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scheduling.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scope_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scope_selector.py index 9686005ac87e..c0f2133a2e16 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scope_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scope_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_scoped_resource_selector_requirement.py b/contrib/python/kubernetes/kubernetes/client/models/v1_scoped_resource_selector_requirement.py index 44a3b37667d7..8f60e24d9124 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_scoped_resource_selector_requirement.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_scoped_resource_selector_requirement.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_se_linux_options.py b/contrib/python/kubernetes/kubernetes/client/models/v1_se_linux_options.py index 971c7c0ca25a..ca2a0fd1674c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_se_linux_options.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_se_linux_options.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_seccomp_profile.py b/contrib/python/kubernetes/kubernetes/client/models/v1_seccomp_profile.py index 3885a6c5cb17..61a446297e65 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_seccomp_profile.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_seccomp_profile.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret.py index f3d0b1a58d2e..b88eed3d7808 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_env_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_env_source.py index a8fc44ce84f8..f10f317d1544 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_env_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_env_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_key_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_key_selector.py index 198a116154a7..0be2680c53d6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_key_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_key_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_list.py index 80e5d29b2ca2..f2254b491846 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_projection.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_projection.py index d11e688a3d1e..ac5e8e09f378 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_projection.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_projection.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_reference.py index b4275635a6fa..22e8a020f91f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_volume_source.py index 421cc2fa5c63..6132e555a86a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_secret_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_secret_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_security_context.py b/contrib/python/kubernetes/kubernetes/client/models/v1_security_context.py index 1213ca371f0c..f1a81954699a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_security_context.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_security_context.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_selectable_field.py b/contrib/python/kubernetes/kubernetes/client/models/v1_selectable_field.py index e3595d4ad777..8ea1339cf68e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_selectable_field.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_selectable_field.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review.py index 6fc042535a82..8b1f74a918f1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review_spec.py index d0c9dd251afe..31bfb83f7766 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_access_review_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review.py index 9fae1db217e4..ce67c1781158 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review_status.py index ebb24d64195e..2ead41ee34ed 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_review_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review.py index 50359fd87494..30da0dc5a439 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review_spec.py index 505d25757cff..85f69ada3b04 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_self_subject_rules_review_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_server_address_by_client_cidr.py b/contrib/python/kubernetes/kubernetes/client/models/v1_server_address_by_client_cidr.py index 82b3549b5acc..90bc0c35bc9f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_server_address_by_client_cidr.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_server_address_by_client_cidr.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service.py index 574c21c1e8bb..ae4d7d19dde4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account.py index 1dd00cd37843..af094cd1a085 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_list.py index 6fb70de4e956..f10f69dd4611 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_subject.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_subject.py index 7a1049e79c1d..2c372a342e2c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_subject.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_token_projection.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_token_projection.py index 2769aa692fed..d74ee4a358c7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_token_projection.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_account_token_projection.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_backend_port.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_backend_port.py index 02a7385ca442..849d258506b5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_backend_port.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_backend_port.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1beta3_flow_schema.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr.py similarity index 75% rename from contrib/python/kubernetes/kubernetes/client/models/v1beta3_flow_schema.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr.py index 705a9bfe1db8..301706f81527 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1beta3_flow_schema.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.31 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1beta3FlowSchema(object): +class V1ServiceCIDR(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -36,8 +36,8 @@ class V1beta3FlowSchema(object): 'api_version': 'str', 'kind': 'str', 'metadata': 'V1ObjectMeta', - 'spec': 'V1beta3FlowSchemaSpec', - 'status': 'V1beta3FlowSchemaStatus' + 'spec': 'V1ServiceCIDRSpec', + 'status': 'V1ServiceCIDRStatus' } attribute_map = { @@ -49,7 +49,7 @@ class V1beta3FlowSchema(object): } def __init__(self, api_version=None, kind=None, metadata=None, spec=None, status=None, local_vars_configuration=None): # noqa: E501 - """V1beta3FlowSchema - a model defined in OpenAPI""" # noqa: E501 + """V1ServiceCIDR - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -74,22 +74,22 @@ def __init__(self, api_version=None, kind=None, metadata=None, spec=None, status @property def api_version(self): - """Gets the api_version of this V1beta3FlowSchema. # noqa: E501 + """Gets the api_version of this V1ServiceCIDR. # noqa: E501 APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :return: The api_version of this V1beta3FlowSchema. # noqa: E501 + :return: The api_version of this V1ServiceCIDR. # noqa: E501 :rtype: str """ return self._api_version @api_version.setter def api_version(self, api_version): - """Sets the api_version of this V1beta3FlowSchema. + """Sets the api_version of this V1ServiceCIDR. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :param api_version: The api_version of this V1beta3FlowSchema. # noqa: E501 + :param api_version: The api_version of this V1ServiceCIDR. # noqa: E501 :type: str """ @@ -97,22 +97,22 @@ def api_version(self, api_version): @property def kind(self): - """Gets the kind of this V1beta3FlowSchema. # noqa: E501 + """Gets the kind of this V1ServiceCIDR. # noqa: E501 Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :return: The kind of this V1beta3FlowSchema. # noqa: E501 + :return: The kind of this V1ServiceCIDR. # noqa: E501 :rtype: str """ return self._kind @kind.setter def kind(self, kind): - """Sets the kind of this V1beta3FlowSchema. + """Sets the kind of this V1ServiceCIDR. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :param kind: The kind of this V1beta3FlowSchema. # noqa: E501 + :param kind: The kind of this V1ServiceCIDR. # noqa: E501 :type: str """ @@ -120,20 +120,20 @@ def kind(self, kind): @property def metadata(self): - """Gets the metadata of this V1beta3FlowSchema. # noqa: E501 + """Gets the metadata of this V1ServiceCIDR. # noqa: E501 - :return: The metadata of this V1beta3FlowSchema. # noqa: E501 + :return: The metadata of this V1ServiceCIDR. # noqa: E501 :rtype: V1ObjectMeta """ return self._metadata @metadata.setter def metadata(self, metadata): - """Sets the metadata of this V1beta3FlowSchema. + """Sets the metadata of this V1ServiceCIDR. - :param metadata: The metadata of this V1beta3FlowSchema. # noqa: E501 + :param metadata: The metadata of this V1ServiceCIDR. # noqa: E501 :type: V1ObjectMeta """ @@ -141,42 +141,42 @@ def metadata(self, metadata): @property def spec(self): - """Gets the spec of this V1beta3FlowSchema. # noqa: E501 + """Gets the spec of this V1ServiceCIDR. # noqa: E501 - :return: The spec of this V1beta3FlowSchema. # noqa: E501 - :rtype: V1beta3FlowSchemaSpec + :return: The spec of this V1ServiceCIDR. # noqa: E501 + :rtype: V1ServiceCIDRSpec """ return self._spec @spec.setter def spec(self, spec): - """Sets the spec of this V1beta3FlowSchema. + """Sets the spec of this V1ServiceCIDR. - :param spec: The spec of this V1beta3FlowSchema. # noqa: E501 - :type: V1beta3FlowSchemaSpec + :param spec: The spec of this V1ServiceCIDR. # noqa: E501 + :type: V1ServiceCIDRSpec """ self._spec = spec @property def status(self): - """Gets the status of this V1beta3FlowSchema. # noqa: E501 + """Gets the status of this V1ServiceCIDR. # noqa: E501 - :return: The status of this V1beta3FlowSchema. # noqa: E501 - :rtype: V1beta3FlowSchemaStatus + :return: The status of this V1ServiceCIDR. # noqa: E501 + :rtype: V1ServiceCIDRStatus """ return self._status @status.setter def status(self, status): - """Sets the status of this V1beta3FlowSchema. + """Sets the status of this V1ServiceCIDR. - :param status: The status of this V1beta3FlowSchema. # noqa: E501 - :type: V1beta3FlowSchemaStatus + :param status: The status of this V1ServiceCIDR. # noqa: E501 + :type: V1ServiceCIDRStatus """ self._status = status @@ -215,14 +215,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1beta3FlowSchema): + if not isinstance(other, V1ServiceCIDR): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1beta3FlowSchema): + if not isinstance(other, V1ServiceCIDR): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_list.py similarity index 78% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_list.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_list.py index c52129a67831..45cd8d62dea8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1ServiceCIDRList(object): +class V1ServiceCIDRList(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -34,7 +34,7 @@ class V1alpha1ServiceCIDRList(object): """ openapi_types = { 'api_version': 'str', - 'items': 'list[V1alpha1ServiceCIDR]', + 'items': 'list[V1ServiceCIDR]', 'kind': 'str', 'metadata': 'V1ListMeta' } @@ -47,7 +47,7 @@ class V1alpha1ServiceCIDRList(object): } def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ServiceCIDRList - a model defined in OpenAPI""" # noqa: E501 + """V1ServiceCIDRList - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -68,22 +68,22 @@ def __init__(self, api_version=None, items=None, kind=None, metadata=None, local @property def api_version(self): - """Gets the api_version of this V1alpha1ServiceCIDRList. # noqa: E501 + """Gets the api_version of this V1ServiceCIDRList. # noqa: E501 APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :return: The api_version of this V1alpha1ServiceCIDRList. # noqa: E501 + :return: The api_version of this V1ServiceCIDRList. # noqa: E501 :rtype: str """ return self._api_version @api_version.setter def api_version(self, api_version): - """Sets the api_version of this V1alpha1ServiceCIDRList. + """Sets the api_version of this V1ServiceCIDRList. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :param api_version: The api_version of this V1alpha1ServiceCIDRList. # noqa: E501 + :param api_version: The api_version of this V1ServiceCIDRList. # noqa: E501 :type: str """ @@ -91,23 +91,23 @@ def api_version(self, api_version): @property def items(self): - """Gets the items of this V1alpha1ServiceCIDRList. # noqa: E501 + """Gets the items of this V1ServiceCIDRList. # noqa: E501 items is the list of ServiceCIDRs. # noqa: E501 - :return: The items of this V1alpha1ServiceCIDRList. # noqa: E501 - :rtype: list[V1alpha1ServiceCIDR] + :return: The items of this V1ServiceCIDRList. # noqa: E501 + :rtype: list[V1ServiceCIDR] """ return self._items @items.setter def items(self, items): - """Sets the items of this V1alpha1ServiceCIDRList. + """Sets the items of this V1ServiceCIDRList. items is the list of ServiceCIDRs. # noqa: E501 - :param items: The items of this V1alpha1ServiceCIDRList. # noqa: E501 - :type: list[V1alpha1ServiceCIDR] + :param items: The items of this V1ServiceCIDRList. # noqa: E501 + :type: list[V1ServiceCIDR] """ if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 @@ -116,22 +116,22 @@ def items(self, items): @property def kind(self): - """Gets the kind of this V1alpha1ServiceCIDRList. # noqa: E501 + """Gets the kind of this V1ServiceCIDRList. # noqa: E501 Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :return: The kind of this V1alpha1ServiceCIDRList. # noqa: E501 + :return: The kind of this V1ServiceCIDRList. # noqa: E501 :rtype: str """ return self._kind @kind.setter def kind(self, kind): - """Sets the kind of this V1alpha1ServiceCIDRList. + """Sets the kind of this V1ServiceCIDRList. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :param kind: The kind of this V1alpha1ServiceCIDRList. # noqa: E501 + :param kind: The kind of this V1ServiceCIDRList. # noqa: E501 :type: str """ @@ -139,20 +139,20 @@ def kind(self, kind): @property def metadata(self): - """Gets the metadata of this V1alpha1ServiceCIDRList. # noqa: E501 + """Gets the metadata of this V1ServiceCIDRList. # noqa: E501 - :return: The metadata of this V1alpha1ServiceCIDRList. # noqa: E501 + :return: The metadata of this V1ServiceCIDRList. # noqa: E501 :rtype: V1ListMeta """ return self._metadata @metadata.setter def metadata(self, metadata): - """Sets the metadata of this V1alpha1ServiceCIDRList. + """Sets the metadata of this V1ServiceCIDRList. - :param metadata: The metadata of this V1alpha1ServiceCIDRList. # noqa: E501 + :param metadata: The metadata of this V1ServiceCIDRList. # noqa: E501 :type: V1ListMeta """ @@ -192,14 +192,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ServiceCIDRList): + if not isinstance(other, V1ServiceCIDRList): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ServiceCIDRList): + if not isinstance(other, V1ServiceCIDRList): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_spec.py similarity index 85% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_spec.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_spec.py index 0c7f4c702e65..4aa2a03a5a82 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1ServiceCIDRSpec(object): +class V1ServiceCIDRSpec(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -41,7 +41,7 @@ class V1alpha1ServiceCIDRSpec(object): } def __init__(self, cidrs=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ServiceCIDRSpec - a model defined in OpenAPI""" # noqa: E501 + """V1ServiceCIDRSpec - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -54,22 +54,22 @@ def __init__(self, cidrs=None, local_vars_configuration=None): # noqa: E501 @property def cidrs(self): - """Gets the cidrs of this V1alpha1ServiceCIDRSpec. # noqa: E501 + """Gets the cidrs of this V1ServiceCIDRSpec. # noqa: E501 CIDRs defines the IP blocks in CIDR notation (e.g. \"192.168.0.0/24\" or \"2001:db8::/64\") from which to assign service cluster IPs. Max of two CIDRs is allowed, one of each IP family. This field is immutable. # noqa: E501 - :return: The cidrs of this V1alpha1ServiceCIDRSpec. # noqa: E501 + :return: The cidrs of this V1ServiceCIDRSpec. # noqa: E501 :rtype: list[str] """ return self._cidrs @cidrs.setter def cidrs(self, cidrs): - """Sets the cidrs of this V1alpha1ServiceCIDRSpec. + """Sets the cidrs of this V1ServiceCIDRSpec. CIDRs defines the IP blocks in CIDR notation (e.g. \"192.168.0.0/24\" or \"2001:db8::/64\") from which to assign service cluster IPs. Max of two CIDRs is allowed, one of each IP family. This field is immutable. # noqa: E501 - :param cidrs: The cidrs of this V1alpha1ServiceCIDRSpec. # noqa: E501 + :param cidrs: The cidrs of this V1ServiceCIDRSpec. # noqa: E501 :type: list[str] """ @@ -109,14 +109,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ServiceCIDRSpec): + if not isinstance(other, V1ServiceCIDRSpec): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ServiceCIDRSpec): + if not isinstance(other, V1ServiceCIDRSpec): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_status.py similarity index 83% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_status.py rename to contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_status.py index bd31f5a6ba08..9aaad031eb58 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_cidr_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1ServiceCIDRStatus(object): +class V1ServiceCIDRStatus(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -41,7 +41,7 @@ class V1alpha1ServiceCIDRStatus(object): } def __init__(self, conditions=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ServiceCIDRStatus - a model defined in OpenAPI""" # noqa: E501 + """V1ServiceCIDRStatus - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -54,22 +54,22 @@ def __init__(self, conditions=None, local_vars_configuration=None): # noqa: E50 @property def conditions(self): - """Gets the conditions of this V1alpha1ServiceCIDRStatus. # noqa: E501 + """Gets the conditions of this V1ServiceCIDRStatus. # noqa: E501 conditions holds an array of metav1.Condition that describe the state of the ServiceCIDR. Current service state # noqa: E501 - :return: The conditions of this V1alpha1ServiceCIDRStatus. # noqa: E501 + :return: The conditions of this V1ServiceCIDRStatus. # noqa: E501 :rtype: list[V1Condition] """ return self._conditions @conditions.setter def conditions(self, conditions): - """Sets the conditions of this V1alpha1ServiceCIDRStatus. + """Sets the conditions of this V1ServiceCIDRStatus. conditions holds an array of metav1.Condition that describe the state of the ServiceCIDR. Current service state # noqa: E501 - :param conditions: The conditions of this V1alpha1ServiceCIDRStatus. # noqa: E501 + :param conditions: The conditions of this V1ServiceCIDRStatus. # noqa: E501 :type: list[V1Condition] """ @@ -109,14 +109,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ServiceCIDRStatus): + if not isinstance(other, V1ServiceCIDRStatus): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ServiceCIDRStatus): + if not isinstance(other, V1ServiceCIDRStatus): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_list.py index 5d00bacdb9aa..682c869ea181 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_port.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_port.py index 87e42c66f0f9..5501aef91122 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_port.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_port.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_spec.py index e12a61f7ee82..fc6f45e7b71d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -563,7 +563,7 @@ def session_affinity_config(self, session_affinity_config): def traffic_distribution(self): """Gets the traffic_distribution of this V1ServiceSpec. # noqa: E501 - TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are topologically close (e.g., same zone). This is a beta field and requires enabling ServiceTrafficDistribution feature. # noqa: E501 + TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are in the same zone. # noqa: E501 :return: The traffic_distribution of this V1ServiceSpec. # noqa: E501 :rtype: str @@ -574,7 +574,7 @@ def traffic_distribution(self): def traffic_distribution(self, traffic_distribution): """Sets the traffic_distribution of this V1ServiceSpec. - TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are topologically close (e.g., same zone). This is a beta field and requires enabling ServiceTrafficDistribution feature. # noqa: E501 + TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are in the same zone. # noqa: E501 :param traffic_distribution: The traffic_distribution of this V1ServiceSpec. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_service_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_service_status.py index 4b570d8fa120..35f979bb6fd5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_service_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_service_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_session_affinity_config.py b/contrib/python/kubernetes/kubernetes/client/models/v1_session_affinity_config.py index e043a7f07edb..0b1f3c6a137f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_session_affinity_config.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_session_affinity_config.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_sleep_action.py b/contrib/python/kubernetes/kubernetes/client/models/v1_sleep_action.py index a6e2abe2f0f9..e3fc769ef3b4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_sleep_action.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_sleep_action.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set.py index 8cd34735fcae..5959ef6d7442 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_condition.py index 8d1168a4682e..1132bfba9271 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_list.py index 43fba34baffc..6f448b4f255d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_ordinals.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_ordinals.py index 821b79cae005..f66b6dd0028a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_ordinals.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_ordinals.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_persistent_volume_claim_retention_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_persistent_volume_claim_retention_policy.py index ca814a4b72e2..02a70965a27e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_persistent_volume_claim_retention_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_persistent_volume_claim_retention_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_spec.py index 8ff0b63e266b..17b78b0e1cb5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -92,7 +92,8 @@ def __init__(self, min_ready_seconds=None, ordinals=None, persistent_volume_clai if revision_history_limit is not None: self.revision_history_limit = revision_history_limit self.selector = selector - self.service_name = service_name + if service_name is not None: + self.service_name = service_name self.template = template if update_strategy is not None: self.update_strategy = update_strategy @@ -276,8 +277,6 @@ def service_name(self, service_name): :param service_name: The service_name of this V1StatefulSetSpec. # noqa: E501 :type: str """ - if self.local_vars_configuration.client_side_validation and service_name is None: # noqa: E501 - raise ValueError("Invalid value for `service_name`, must not be `None`") # noqa: E501 self._service_name = service_name diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_status.py index 41a1369a9b95..3205dee0afd1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_update_strategy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_update_strategy.py index 95b5da9515af..db132f05aad9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_update_strategy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_stateful_set_update_strategy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_status.py index dfc77ff4c672..e104125ca85a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_status_cause.py b/contrib/python/kubernetes/kubernetes/client/models/v1_status_cause.py index a983eda18fcc..de703a904fd5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_status_cause.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_status_cause.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_status_details.py b/contrib/python/kubernetes/kubernetes/client/models/v1_status_details.py index 954b04ca38a2..40485d182f23 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_status_details.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_status_details.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class.py index d78087e8f570..de6fb95c7d64 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class_list.py index f6e4ba7ee586..da36cc85dcc9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_class_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_persistent_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_persistent_volume_source.py index c808b0f3f58e..fdb948675507 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_persistent_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_persistent_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_volume_source.py index 887450844740..43587db08a39 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_storage_os_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review.py index 2830388bf7ed..428f326928b9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_spec.py index be8d46dcb9c6..57979f45607c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_status.py index a7387117963a..e022606ebda0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_access_review_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_rules_review_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_rules_review_status.py index 0b81c497782d..dbcd7ab52d41 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_subject_rules_review_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_subject_rules_review_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy.py index 1a53aa2fa7d9..7d46ca8ea09b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy_rule.py index b3faea76302e..fe97c440dd44 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_success_policy_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_sysctl.py b/contrib/python/kubernetes/kubernetes/client/models/v1_sysctl.py index 4ebed3d7df79..4520255a6e7a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_sysctl.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_sysctl.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_taint.py b/contrib/python/kubernetes/kubernetes/client/models/v1_taint.py index 5f0d5599f3ff..045a9a2a2ef2 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_taint.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_taint.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_tcp_socket_action.py b/contrib/python/kubernetes/kubernetes/client/models/v1_tcp_socket_action.py index 4de689742ec3..e942960f8ee9 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_tcp_socket_action.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_tcp_socket_action.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_spec.py index 55da4893fc46..dc4e68a0c98d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_status.py index 01eefcb1d1c5..645f2836f208 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_token_request_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_token_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1_token_review.py index 9384085a92c7..1f935320d084 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_token_review.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_token_review.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_spec.py index a73ac03f056f..419077dc7067 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_status.py index 5da2280d81a6..03fb4f2e9a06 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_token_review_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_toleration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_toleration.py index 1569ebc424b2..c525665085d5 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_toleration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_toleration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_label_requirement.py b/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_label_requirement.py index 1343a9e6dce9..cdc10d4b65fd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_label_requirement.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_label_requirement.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_term.py b/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_term.py index 0f780bd19e33..9b7c90b9abd6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_term.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_topology_selector_term.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_topology_spread_constraint.py b/contrib/python/kubernetes/kubernetes/client/models/v1_topology_spread_constraint.py index 046c1e252c0e..ab2e21d05ff8 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_topology_spread_constraint.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_topology_spread_constraint.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -180,7 +180,7 @@ def min_domains(self, min_domains): def node_affinity_policy(self): """Gets the node_affinity_policy of this V1TopologySpreadConstraint. # noqa: E501 - NodeAffinityPolicy indicates how we will treat Pod's nodeAffinity/nodeSelector when calculating pod topology spread skew. Options are: - Honor: only nodes matching nodeAffinity/nodeSelector are included in the calculations. - Ignore: nodeAffinity/nodeSelector are ignored. All nodes are included in the calculations. If this value is nil, the behavior is equivalent to the Honor policy. This is a beta-level feature default enabled by the NodeInclusionPolicyInPodTopologySpread feature flag. # noqa: E501 + NodeAffinityPolicy indicates how we will treat Pod's nodeAffinity/nodeSelector when calculating pod topology spread skew. Options are: - Honor: only nodes matching nodeAffinity/nodeSelector are included in the calculations. - Ignore: nodeAffinity/nodeSelector are ignored. All nodes are included in the calculations. If this value is nil, the behavior is equivalent to the Honor policy. # noqa: E501 :return: The node_affinity_policy of this V1TopologySpreadConstraint. # noqa: E501 :rtype: str @@ -191,7 +191,7 @@ def node_affinity_policy(self): def node_affinity_policy(self, node_affinity_policy): """Sets the node_affinity_policy of this V1TopologySpreadConstraint. - NodeAffinityPolicy indicates how we will treat Pod's nodeAffinity/nodeSelector when calculating pod topology spread skew. Options are: - Honor: only nodes matching nodeAffinity/nodeSelector are included in the calculations. - Ignore: nodeAffinity/nodeSelector are ignored. All nodes are included in the calculations. If this value is nil, the behavior is equivalent to the Honor policy. This is a beta-level feature default enabled by the NodeInclusionPolicyInPodTopologySpread feature flag. # noqa: E501 + NodeAffinityPolicy indicates how we will treat Pod's nodeAffinity/nodeSelector when calculating pod topology spread skew. Options are: - Honor: only nodes matching nodeAffinity/nodeSelector are included in the calculations. - Ignore: nodeAffinity/nodeSelector are ignored. All nodes are included in the calculations. If this value is nil, the behavior is equivalent to the Honor policy. # noqa: E501 :param node_affinity_policy: The node_affinity_policy of this V1TopologySpreadConstraint. # noqa: E501 :type: str @@ -203,7 +203,7 @@ def node_affinity_policy(self, node_affinity_policy): def node_taints_policy(self): """Gets the node_taints_policy of this V1TopologySpreadConstraint. # noqa: E501 - NodeTaintsPolicy indicates how we will treat node taints when calculating pod topology spread skew. Options are: - Honor: nodes without taints, along with tainted nodes for which the incoming pod has a toleration, are included. - Ignore: node taints are ignored. All nodes are included. If this value is nil, the behavior is equivalent to the Ignore policy. This is a beta-level feature default enabled by the NodeInclusionPolicyInPodTopologySpread feature flag. # noqa: E501 + NodeTaintsPolicy indicates how we will treat node taints when calculating pod topology spread skew. Options are: - Honor: nodes without taints, along with tainted nodes for which the incoming pod has a toleration, are included. - Ignore: node taints are ignored. All nodes are included. If this value is nil, the behavior is equivalent to the Ignore policy. # noqa: E501 :return: The node_taints_policy of this V1TopologySpreadConstraint. # noqa: E501 :rtype: str @@ -214,7 +214,7 @@ def node_taints_policy(self): def node_taints_policy(self, node_taints_policy): """Sets the node_taints_policy of this V1TopologySpreadConstraint. - NodeTaintsPolicy indicates how we will treat node taints when calculating pod topology spread skew. Options are: - Honor: nodes without taints, along with tainted nodes for which the incoming pod has a toleration, are included. - Ignore: node taints are ignored. All nodes are included. If this value is nil, the behavior is equivalent to the Ignore policy. This is a beta-level feature default enabled by the NodeInclusionPolicyInPodTopologySpread feature flag. # noqa: E501 + NodeTaintsPolicy indicates how we will treat node taints when calculating pod topology spread skew. Options are: - Honor: nodes without taints, along with tainted nodes for which the incoming pod has a toleration, are included. - Ignore: node taints are ignored. All nodes are included. If this value is nil, the behavior is equivalent to the Ignore policy. # noqa: E501 :param node_taints_policy: The node_taints_policy of this V1TopologySpreadConstraint. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_type_checking.py b/contrib/python/kubernetes/kubernetes/client/models/v1_type_checking.py index dd4b2494775c..ddae6e9656a7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_type_checking.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_type_checking.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_typed_local_object_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_typed_local_object_reference.py index e98a374b61b7..5cf0772b26bc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_typed_local_object_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_typed_local_object_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_typed_object_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1_typed_object_reference.py index e1a7af0e0ef0..268c50461ece 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_typed_object_reference.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_typed_object_reference.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_uncounted_terminated_pods.py b/contrib/python/kubernetes/kubernetes/client/models/v1_uncounted_terminated_pods.py index 834b85c0e88d..40d30c4e9039 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_uncounted_terminated_pods.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_uncounted_terminated_pods.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_user_info.py b/contrib/python/kubernetes/kubernetes/client/models/v1_user_info.py index 5530725e6376..51ffc67c7102 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_user_info.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_user_info.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_user_subject.py b/contrib/python/kubernetes/kubernetes/client/models/v1_user_subject.py index 9427e78fa4a2..5b8a1db6e447 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_user_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_user_subject.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy.py index 9928030867c2..3248ed48470b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding.py index 2f7b333b7b4e..36dff9d10b57 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_list.py index b66e289ac213..7edb7529ac44 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_spec.py index 35550eebe8c9..41809006ad81 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_binding_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_list.py index 9ea1f20ff213..aed3447f4c68 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_spec.py index 95eebcbaeec6..ce35a624d892 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_status.py index 86e9d6610853..adc2387325d7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_admission_policy_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook.py index 76408f322ad2..30327af82b5e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration.py index d59c21f3e832..2af76083d9b0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration_list.py index 63f2bceb4d7f..58c047a618a6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validating_webhook_configuration_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validation.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validation.py index 368934925430..297ffa8017a0 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validation.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validation.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_validation_rule.py b/contrib/python/kubernetes/kubernetes/client/models/v1_validation_rule.py index 9ee34fa33865..792d08393e18 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_validation_rule.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_validation_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_variable.py b/contrib/python/kubernetes/kubernetes/client/models/v1_variable.py index f76f6f868e5e..3954428c63de 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_variable.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_variable.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume.py index 1604a25ac7ae..31fe775dd2af 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment.py index 48fa20da2647..f88eb3a676ad 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_list.py index b4eb4658f343..73a722c43964 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_source.py index 1e38f5037db5..70efbb96241c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_spec.py index 85b4afbd57b0..a4753abe1404 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_status.py index ada030d769ef..e9ddb15424bb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_attachment_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_device.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_device.py index 0e109dc642cb..91c1bb628f23 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_device.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_device.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_error.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_error.py index d9bc406e8092..0d833c8c7a2a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_error.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_error.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -33,30 +33,58 @@ class V1VolumeError(object): and the value is json key in definition. """ openapi_types = { + 'error_code': 'int', 'message': 'str', 'time': 'datetime' } attribute_map = { + 'error_code': 'errorCode', 'message': 'message', 'time': 'time' } - def __init__(self, message=None, time=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, error_code=None, message=None, time=None, local_vars_configuration=None): # noqa: E501 """V1VolumeError - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration + self._error_code = None self._message = None self._time = None self.discriminator = None + if error_code is not None: + self.error_code = error_code if message is not None: self.message = message if time is not None: self.time = time + @property + def error_code(self): + """Gets the error_code of this V1VolumeError. # noqa: E501 + + errorCode is a numeric gRPC code representing the error encountered during Attach or Detach operations. This is an optional, alpha field that requires the MutableCSINodeAllocatableCount feature gate being enabled to be set. # noqa: E501 + + :return: The error_code of this V1VolumeError. # noqa: E501 + :rtype: int + """ + return self._error_code + + @error_code.setter + def error_code(self, error_code): + """Sets the error_code of this V1VolumeError. + + errorCode is a numeric gRPC code representing the error encountered during Attach or Detach operations. This is an optional, alpha field that requires the MutableCSINodeAllocatableCount feature gate being enabled to be set. # noqa: E501 + + :param error_code: The error_code of this V1VolumeError. # noqa: E501 + :type: int + """ + + self._error_code = error_code + @property def message(self): """Gets the message of this V1VolumeError. # noqa: E501 diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount.py index bac7750cf79e..8c02b6027d47 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount_status.py index bedcd0120626..a9917e8f86b6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_mount_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_affinity.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_affinity.py index 21cf92a84505..1eac2380ec75 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_affinity.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_affinity.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_resources.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_resources.py index 3e38e54c4c2d..c6ea9abcceb6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_resources.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_node_resources.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_projection.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_projection.py index 90eb0b4743c0..ddd3bb99a031 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_projection.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_projection.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_resource_requirements.py b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_resource_requirements.py index f680bf9ac359..22927caa6a55 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_volume_resource_requirements.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_volume_resource_requirements.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_vsphere_virtual_disk_volume_source.py b/contrib/python/kubernetes/kubernetes/client/models/v1_vsphere_virtual_disk_volume_source.py index 4b26ea1201ec..f823e2369ced 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_vsphere_virtual_disk_volume_source.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_vsphere_virtual_disk_volume_source.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_watch_event.py b/contrib/python/kubernetes/kubernetes/client/models/v1_watch_event.py index 6f089610f0be..3eebaebc8efa 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_watch_event.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_watch_event.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_webhook_conversion.py b/contrib/python/kubernetes/kubernetes/client/models/v1_webhook_conversion.py index f7b6761e241f..451498c0a7fb 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_webhook_conversion.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_webhook_conversion.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_weighted_pod_affinity_term.py b/contrib/python/kubernetes/kubernetes/client/models/v1_weighted_pod_affinity_term.py index 7c6d4599f67b..ff4142bacc41 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_weighted_pod_affinity_term.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_weighted_pod_affinity_term.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1_windows_security_context_options.py b/contrib/python/kubernetes/kubernetes/client/models/v1_windows_security_context_options.py index 7ee6a2e39a36..3369b024ac3d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1_windows_security_context_options.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1_windows_security_context_options.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_apply_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_apply_configuration.py index 3fb3e70a462c..58a618c2aad6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_apply_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_apply_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_audit_annotation.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_audit_annotation.py deleted file mode 100644 index 43ff564dfc52..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_audit_annotation.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1AuditAnnotation(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'key': 'str', - 'value_expression': 'str' - } - - attribute_map = { - 'key': 'key', - 'value_expression': 'valueExpression' - } - - def __init__(self, key=None, value_expression=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1AuditAnnotation - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._key = None - self._value_expression = None - self.discriminator = None - - self.key = key - self.value_expression = value_expression - - @property - def key(self): - """Gets the key of this V1alpha1AuditAnnotation. # noqa: E501 - - key specifies the audit annotation key. The audit annotation keys of a ValidatingAdmissionPolicy must be unique. The key must be a qualified name ([A-Za-z0-9][-A-Za-z0-9_.]*) no more than 63 bytes in length. The key is combined with the resource name of the ValidatingAdmissionPolicy to construct an audit annotation key: \"{ValidatingAdmissionPolicy name}/{key}\". If an admission webhook uses the same resource name as this ValidatingAdmissionPolicy and the same audit annotation key, the annotation key will be identical. In this case, the first annotation written with the key will be included in the audit event and all subsequent annotations with the same key will be discarded. Required. # noqa: E501 - - :return: The key of this V1alpha1AuditAnnotation. # noqa: E501 - :rtype: str - """ - return self._key - - @key.setter - def key(self, key): - """Sets the key of this V1alpha1AuditAnnotation. - - key specifies the audit annotation key. The audit annotation keys of a ValidatingAdmissionPolicy must be unique. The key must be a qualified name ([A-Za-z0-9][-A-Za-z0-9_.]*) no more than 63 bytes in length. The key is combined with the resource name of the ValidatingAdmissionPolicy to construct an audit annotation key: \"{ValidatingAdmissionPolicy name}/{key}\". If an admission webhook uses the same resource name as this ValidatingAdmissionPolicy and the same audit annotation key, the annotation key will be identical. In this case, the first annotation written with the key will be included in the audit event and all subsequent annotations with the same key will be discarded. Required. # noqa: E501 - - :param key: The key of this V1alpha1AuditAnnotation. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and key is None: # noqa: E501 - raise ValueError("Invalid value for `key`, must not be `None`") # noqa: E501 - - self._key = key - - @property - def value_expression(self): - """Gets the value_expression of this V1alpha1AuditAnnotation. # noqa: E501 - - valueExpression represents the expression which is evaluated by CEL to produce an audit annotation value. The expression must evaluate to either a string or null value. If the expression evaluates to a string, the audit annotation is included with the string value. If the expression evaluates to null or empty string the audit annotation will be omitted. The valueExpression may be no longer than 5kb in length. If the result of the valueExpression is more than 10kb in length, it will be truncated to 10kb. If multiple ValidatingAdmissionPolicyBinding resources match an API request, then the valueExpression will be evaluated for each binding. All unique values produced by the valueExpressions will be joined together in a comma-separated list. Required. # noqa: E501 - - :return: The value_expression of this V1alpha1AuditAnnotation. # noqa: E501 - :rtype: str - """ - return self._value_expression - - @value_expression.setter - def value_expression(self, value_expression): - """Sets the value_expression of this V1alpha1AuditAnnotation. - - valueExpression represents the expression which is evaluated by CEL to produce an audit annotation value. The expression must evaluate to either a string or null value. If the expression evaluates to a string, the audit annotation is included with the string value. If the expression evaluates to null or empty string the audit annotation will be omitted. The valueExpression may be no longer than 5kb in length. If the result of the valueExpression is more than 10kb in length, it will be truncated to 10kb. If multiple ValidatingAdmissionPolicyBinding resources match an API request, then the valueExpression will be evaluated for each binding. All unique values produced by the valueExpressions will be joined together in a comma-separated list. Required. # noqa: E501 - - :param value_expression: The value_expression of this V1alpha1AuditAnnotation. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and value_expression is None: # noqa: E501 - raise ValueError("Invalid value for `value_expression`, must not be `None`") # noqa: E501 - - self._value_expression = value_expression - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1AuditAnnotation): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1AuditAnnotation): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle.py index d43b83500734..04edba9fb65f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_list.py index e43589e95199..53eeebc1e3d4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_spec.py index d1a566d3ae16..0be936810a8f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_cluster_trust_bundle_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_expression_warning.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_expression_warning.py deleted file mode 100644 index f7befde1e718..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_expression_warning.py +++ /dev/null @@ -1,152 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ExpressionWarning(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'field_ref': 'str', - 'warning': 'str' - } - - attribute_map = { - 'field_ref': 'fieldRef', - 'warning': 'warning' - } - - def __init__(self, field_ref=None, warning=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ExpressionWarning - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._field_ref = None - self._warning = None - self.discriminator = None - - self.field_ref = field_ref - self.warning = warning - - @property - def field_ref(self): - """Gets the field_ref of this V1alpha1ExpressionWarning. # noqa: E501 - - The path to the field that refers the expression. For example, the reference to the expression of the first item of validations is \"spec.validations[0].expression\" # noqa: E501 - - :return: The field_ref of this V1alpha1ExpressionWarning. # noqa: E501 - :rtype: str - """ - return self._field_ref - - @field_ref.setter - def field_ref(self, field_ref): - """Sets the field_ref of this V1alpha1ExpressionWarning. - - The path to the field that refers the expression. For example, the reference to the expression of the first item of validations is \"spec.validations[0].expression\" # noqa: E501 - - :param field_ref: The field_ref of this V1alpha1ExpressionWarning. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and field_ref is None: # noqa: E501 - raise ValueError("Invalid value for `field_ref`, must not be `None`") # noqa: E501 - - self._field_ref = field_ref - - @property - def warning(self): - """Gets the warning of this V1alpha1ExpressionWarning. # noqa: E501 - - The content of type checking information in a human-readable form. Each line of the warning contains the type that the expression is checked against, followed by the type check error from the compiler. # noqa: E501 - - :return: The warning of this V1alpha1ExpressionWarning. # noqa: E501 - :rtype: str - """ - return self._warning - - @warning.setter - def warning(self, warning): - """Sets the warning of this V1alpha1ExpressionWarning. - - The content of type checking information in a human-readable form. Each line of the warning contains the type that the expression is checked against, followed by the type check error from the compiler. # noqa: E501 - - :param warning: The warning of this V1alpha1ExpressionWarning. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and warning is None: # noqa: E501 - raise ValueError("Invalid value for `warning`, must not be `None`") # noqa: E501 - - self._warning = warning - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ExpressionWarning): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ExpressionWarning): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_group_version_resource.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_group_version_resource.py index 58dce2466453..05e085e4ed02 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_group_version_resource.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_group_version_resource.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_json_patch.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_json_patch.py index 7dddc59499d4..990a092caa0e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_json_patch.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_json_patch.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_condition.py index 1a1b0a4531d6..06ee19ef8b38 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_resources.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_resources.py index bb24367c9cd9..b07f2cb6b39d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_resources.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_match_resources.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -76,7 +76,7 @@ def __init__(self, exclude_resource_rules=None, match_policy=None, namespace_sel def exclude_resource_rules(self): """Gets the exclude_resource_rules of this V1alpha1MatchResources. # noqa: E501 - ExcludeResourceRules describes what operations on what resources/subresources the ValidatingAdmissionPolicy should not care about. The exclude rules take precedence over include rules (if a resource matches both, it is excluded) # noqa: E501 + ExcludeResourceRules describes what operations on what resources/subresources the policy should not care about. The exclude rules take precedence over include rules (if a resource matches both, it is excluded) # noqa: E501 :return: The exclude_resource_rules of this V1alpha1MatchResources. # noqa: E501 :rtype: list[V1alpha1NamedRuleWithOperations] @@ -87,7 +87,7 @@ def exclude_resource_rules(self): def exclude_resource_rules(self, exclude_resource_rules): """Sets the exclude_resource_rules of this V1alpha1MatchResources. - ExcludeResourceRules describes what operations on what resources/subresources the ValidatingAdmissionPolicy should not care about. The exclude rules take precedence over include rules (if a resource matches both, it is excluded) # noqa: E501 + ExcludeResourceRules describes what operations on what resources/subresources the policy should not care about. The exclude rules take precedence over include rules (if a resource matches both, it is excluded) # noqa: E501 :param exclude_resource_rules: The exclude_resource_rules of this V1alpha1MatchResources. # noqa: E501 :type: list[V1alpha1NamedRuleWithOperations] @@ -99,7 +99,7 @@ def exclude_resource_rules(self, exclude_resource_rules): def match_policy(self): """Gets the match_policy of this V1alpha1MatchResources. # noqa: E501 - matchPolicy defines how the \"MatchResources\" list is used to match incoming requests. Allowed values are \"Exact\" or \"Equivalent\". - Exact: match a request only if it exactly matches a specified rule. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, but \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, a request to apps/v1beta1 or extensions/v1beta1 would not be sent to the ValidatingAdmissionPolicy. - Equivalent: match a request if modifies a resource listed in rules, even via another API group or version. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, and \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, a request to apps/v1beta1 or extensions/v1beta1 would be converted to apps/v1 and sent to the ValidatingAdmissionPolicy. Defaults to \"Equivalent\" # noqa: E501 + matchPolicy defines how the \"MatchResources\" list is used to match incoming requests. Allowed values are \"Exact\" or \"Equivalent\". - Exact: match a request only if it exactly matches a specified rule. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, but \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, the admission policy does not consider requests to apps/v1beta1 or extensions/v1beta1 API groups. - Equivalent: match a request if modifies a resource listed in rules, even via another API group or version. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, and \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, the admission policy **does** consider requests made to apps/v1beta1 or extensions/v1beta1 API groups. The API server translates the request to a matched resource API if necessary. Defaults to \"Equivalent\" # noqa: E501 :return: The match_policy of this V1alpha1MatchResources. # noqa: E501 :rtype: str @@ -110,7 +110,7 @@ def match_policy(self): def match_policy(self, match_policy): """Sets the match_policy of this V1alpha1MatchResources. - matchPolicy defines how the \"MatchResources\" list is used to match incoming requests. Allowed values are \"Exact\" or \"Equivalent\". - Exact: match a request only if it exactly matches a specified rule. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, but \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, a request to apps/v1beta1 or extensions/v1beta1 would not be sent to the ValidatingAdmissionPolicy. - Equivalent: match a request if modifies a resource listed in rules, even via another API group or version. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, and \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, a request to apps/v1beta1 or extensions/v1beta1 would be converted to apps/v1 and sent to the ValidatingAdmissionPolicy. Defaults to \"Equivalent\" # noqa: E501 + matchPolicy defines how the \"MatchResources\" list is used to match incoming requests. Allowed values are \"Exact\" or \"Equivalent\". - Exact: match a request only if it exactly matches a specified rule. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, but \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, the admission policy does not consider requests to apps/v1beta1 or extensions/v1beta1 API groups. - Equivalent: match a request if modifies a resource listed in rules, even via another API group or version. For example, if deployments can be modified via apps/v1, apps/v1beta1, and extensions/v1beta1, and \"rules\" only included `apiGroups:[\"apps\"], apiVersions:[\"v1\"], resources: [\"deployments\"]`, the admission policy **does** consider requests made to apps/v1beta1 or extensions/v1beta1 API groups. The API server translates the request to a matched resource API if necessary. Defaults to \"Equivalent\" # noqa: E501 :param match_policy: The match_policy of this V1alpha1MatchResources. # noqa: E501 :type: str @@ -164,7 +164,7 @@ def object_selector(self, object_selector): def resource_rules(self): """Gets the resource_rules of this V1alpha1MatchResources. # noqa: E501 - ResourceRules describes what operations on what resources/subresources the ValidatingAdmissionPolicy matches. The policy cares about an operation if it matches _any_ Rule. # noqa: E501 + ResourceRules describes what operations on what resources/subresources the admission policy matches. The policy cares about an operation if it matches _any_ Rule. # noqa: E501 :return: The resource_rules of this V1alpha1MatchResources. # noqa: E501 :rtype: list[V1alpha1NamedRuleWithOperations] @@ -175,7 +175,7 @@ def resource_rules(self): def resource_rules(self, resource_rules): """Sets the resource_rules of this V1alpha1MatchResources. - ResourceRules describes what operations on what resources/subresources the ValidatingAdmissionPolicy matches. The policy cares about an operation if it matches _any_ Rule. # noqa: E501 + ResourceRules describes what operations on what resources/subresources the admission policy matches. The policy cares about an operation if it matches _any_ Rule. # noqa: E501 :param resource_rules: The resource_rules of this V1alpha1MatchResources. # noqa: E501 :type: list[V1alpha1NamedRuleWithOperations] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_migration_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_migration_condition.py index 7250637f78de..12d6d128212b 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_migration_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_migration_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy.py index ef8d272f8dfa..43e520d50b96 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding.py index f6e0873c7ad9..ab6fb798126f 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_list.py index 2db163862239..c522709b8f77 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_spec.py index af70354501cd..d455d243b1bc 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_binding_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_list.py index 0a6b81620420..81a3a7759695 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_spec.py index 075f2b6cda22..70a83f2da644 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutating_admission_policy_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutation.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutation.py index d15d0d317fcb..ff80b7ee6e11 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutation.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_mutation.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_named_rule_with_operations.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_named_rule_with_operations.py index 47878c48ddcc..28c5c3c16a9d 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_named_rule_with_operations.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_named_rule_with_operations.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_kind.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_kind.py index e92ec54924f6..32cd6f2fffc4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_kind.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_kind.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_ref.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_ref.py index dfd9520d59fe..80dfe0f7d35e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_ref.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_param_ref.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_self_subject_review.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_self_subject_review.py deleted file mode 100644 index 80e50d552597..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_self_subject_review.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1SelfSubjectReview(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'status': 'V1alpha1SelfSubjectReviewStatus' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'kind': 'kind', - 'metadata': 'metadata', - 'status': 'status' - } - - def __init__(self, api_version=None, kind=None, metadata=None, status=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1SelfSubjectReview - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._kind = None - self._metadata = None - self._status = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if status is not None: - self.status = status - - @property - def api_version(self): - """Gets the api_version of this V1alpha1SelfSubjectReview. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha1SelfSubjectReview. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha1SelfSubjectReview. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha1SelfSubjectReview. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def kind(self): - """Gets the kind of this V1alpha1SelfSubjectReview. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha1SelfSubjectReview. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha1SelfSubjectReview. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha1SelfSubjectReview. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha1SelfSubjectReview. # noqa: E501 - - - :return: The metadata of this V1alpha1SelfSubjectReview. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha1SelfSubjectReview. - - - :param metadata: The metadata of this V1alpha1SelfSubjectReview. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def status(self): - """Gets the status of this V1alpha1SelfSubjectReview. # noqa: E501 - - - :return: The status of this V1alpha1SelfSubjectReview. # noqa: E501 - :rtype: V1alpha1SelfSubjectReviewStatus - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this V1alpha1SelfSubjectReview. - - - :param status: The status of this V1alpha1SelfSubjectReview. # noqa: E501 - :type: V1alpha1SelfSubjectReviewStatus - """ - - self._status = status - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1SelfSubjectReview): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1SelfSubjectReview): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_server_storage_version.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_server_storage_version.py index 90bdeb1f9020..c0aaf232d11e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_server_storage_version.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_server_storage_version.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr.py deleted file mode 100644 index 632090a41a44..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_service_cidr.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ServiceCIDR(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'spec': 'V1alpha1ServiceCIDRSpec', - 'status': 'V1alpha1ServiceCIDRStatus' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'kind': 'kind', - 'metadata': 'metadata', - 'spec': 'spec', - 'status': 'status' - } - - def __init__(self, api_version=None, kind=None, metadata=None, spec=None, status=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ServiceCIDR - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._kind = None - self._metadata = None - self._spec = None - self._status = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if spec is not None: - self.spec = spec - if status is not None: - self.status = status - - @property - def api_version(self): - """Gets the api_version of this V1alpha1ServiceCIDR. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha1ServiceCIDR. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha1ServiceCIDR. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha1ServiceCIDR. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def kind(self): - """Gets the kind of this V1alpha1ServiceCIDR. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha1ServiceCIDR. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha1ServiceCIDR. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha1ServiceCIDR. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha1ServiceCIDR. # noqa: E501 - - - :return: The metadata of this V1alpha1ServiceCIDR. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha1ServiceCIDR. - - - :param metadata: The metadata of this V1alpha1ServiceCIDR. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def spec(self): - """Gets the spec of this V1alpha1ServiceCIDR. # noqa: E501 - - - :return: The spec of this V1alpha1ServiceCIDR. # noqa: E501 - :rtype: V1alpha1ServiceCIDRSpec - """ - return self._spec - - @spec.setter - def spec(self, spec): - """Sets the spec of this V1alpha1ServiceCIDR. - - - :param spec: The spec of this V1alpha1ServiceCIDR. # noqa: E501 - :type: V1alpha1ServiceCIDRSpec - """ - - self._spec = spec - - @property - def status(self): - """Gets the status of this V1alpha1ServiceCIDR. # noqa: E501 - - - :return: The status of this V1alpha1ServiceCIDR. # noqa: E501 - :rtype: V1alpha1ServiceCIDRStatus - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this V1alpha1ServiceCIDR. - - - :param status: The status of this V1alpha1ServiceCIDR. # noqa: E501 - :type: V1alpha1ServiceCIDRStatus - """ - - self._status = status - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ServiceCIDR): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ServiceCIDR): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version.py index 0aeae6e43946..f3f4e1bcf175 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_condition.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_condition.py index 22f4017a57ce..82e01786fe05 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_condition.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_condition.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_list.py index cb151ba96c1e..2452a51fc99c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration.py index 221b06ab3cb4..39bf0b47cd48 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_list.py index 027c6107226a..2033cf1fd4a4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_spec.py index d1f52bb8b4cf..8b5ea9b2938a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_status.py index 22b7bbd12bba..33da35a63439 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_migration_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_status.py index f3d0ee9e34d8..8dbf7e1a96f6 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_storage_version_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_type_checking.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_type_checking.py deleted file mode 100644 index 18fdff4ceca7..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_type_checking.py +++ /dev/null @@ -1,122 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1TypeChecking(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'expression_warnings': 'list[V1alpha1ExpressionWarning]' - } - - attribute_map = { - 'expression_warnings': 'expressionWarnings' - } - - def __init__(self, expression_warnings=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1TypeChecking - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._expression_warnings = None - self.discriminator = None - - if expression_warnings is not None: - self.expression_warnings = expression_warnings - - @property - def expression_warnings(self): - """Gets the expression_warnings of this V1alpha1TypeChecking. # noqa: E501 - - The type checking warnings for each expression. # noqa: E501 - - :return: The expression_warnings of this V1alpha1TypeChecking. # noqa: E501 - :rtype: list[V1alpha1ExpressionWarning] - """ - return self._expression_warnings - - @expression_warnings.setter - def expression_warnings(self, expression_warnings): - """Sets the expression_warnings of this V1alpha1TypeChecking. - - The type checking warnings for each expression. # noqa: E501 - - :param expression_warnings: The expression_warnings of this V1alpha1TypeChecking. # noqa: E501 - :type: list[V1alpha1ExpressionWarning] - """ - - self._expression_warnings = expression_warnings - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1TypeChecking): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1TypeChecking): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy.py deleted file mode 100644 index 1c640ca1b2af..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy.py +++ /dev/null @@ -1,228 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ValidatingAdmissionPolicy(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'spec': 'V1alpha1ValidatingAdmissionPolicySpec', - 'status': 'V1alpha1ValidatingAdmissionPolicyStatus' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'kind': 'kind', - 'metadata': 'metadata', - 'spec': 'spec', - 'status': 'status' - } - - def __init__(self, api_version=None, kind=None, metadata=None, spec=None, status=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicy - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._kind = None - self._metadata = None - self._spec = None - self._status = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if spec is not None: - self.spec = spec - if status is not None: - self.status = status - - @property - def api_version(self): - """Gets the api_version of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha1ValidatingAdmissionPolicy. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def kind(self): - """Gets the kind of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha1ValidatingAdmissionPolicy. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - - - :return: The metadata of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha1ValidatingAdmissionPolicy. - - - :param metadata: The metadata of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def spec(self): - """Gets the spec of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - - - :return: The spec of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :rtype: V1alpha1ValidatingAdmissionPolicySpec - """ - return self._spec - - @spec.setter - def spec(self, spec): - """Sets the spec of this V1alpha1ValidatingAdmissionPolicy. - - - :param spec: The spec of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :type: V1alpha1ValidatingAdmissionPolicySpec - """ - - self._spec = spec - - @property - def status(self): - """Gets the status of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - - - :return: The status of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :rtype: V1alpha1ValidatingAdmissionPolicyStatus - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this V1alpha1ValidatingAdmissionPolicy. - - - :param status: The status of this V1alpha1ValidatingAdmissionPolicy. # noqa: E501 - :type: V1alpha1ValidatingAdmissionPolicyStatus - """ - - self._status = status - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicy): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicy): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding_list.py deleted file mode 100644 index b291d1d35a94..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding_list.py +++ /dev/null @@ -1,205 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ValidatingAdmissionPolicyBindingList(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'items': 'list[V1alpha1ValidatingAdmissionPolicyBinding]', - 'kind': 'str', - 'metadata': 'V1ListMeta' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'items': 'items', - 'kind': 'kind', - 'metadata': 'metadata' - } - - def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicyBindingList - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._items = None - self._kind = None - self._metadata = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.items = items - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - - @property - def api_version(self): - """Gets the api_version of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha1ValidatingAdmissionPolicyBindingList. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def items(self): - """Gets the items of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - - List of PolicyBinding. # noqa: E501 - - :return: The items of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :rtype: list[V1alpha1ValidatingAdmissionPolicyBinding] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this V1alpha1ValidatingAdmissionPolicyBindingList. - - List of PolicyBinding. # noqa: E501 - - :param items: The items of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :type: list[V1alpha1ValidatingAdmissionPolicyBinding] - """ - if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 - raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 - - self._items = items - - @property - def kind(self): - """Gets the kind of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha1ValidatingAdmissionPolicyBindingList. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - - - :return: The metadata of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :rtype: V1ListMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha1ValidatingAdmissionPolicyBindingList. - - - :param metadata: The metadata of this V1alpha1ValidatingAdmissionPolicyBindingList. # noqa: E501 - :type: V1ListMeta - """ - - self._metadata = metadata - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyBindingList): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyBindingList): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding_spec.py deleted file mode 100644 index f8a3bec1a929..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding_spec.py +++ /dev/null @@ -1,202 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ValidatingAdmissionPolicyBindingSpec(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'match_resources': 'V1alpha1MatchResources', - 'param_ref': 'V1alpha1ParamRef', - 'policy_name': 'str', - 'validation_actions': 'list[str]' - } - - attribute_map = { - 'match_resources': 'matchResources', - 'param_ref': 'paramRef', - 'policy_name': 'policyName', - 'validation_actions': 'validationActions' - } - - def __init__(self, match_resources=None, param_ref=None, policy_name=None, validation_actions=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicyBindingSpec - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._match_resources = None - self._param_ref = None - self._policy_name = None - self._validation_actions = None - self.discriminator = None - - if match_resources is not None: - self.match_resources = match_resources - if param_ref is not None: - self.param_ref = param_ref - if policy_name is not None: - self.policy_name = policy_name - if validation_actions is not None: - self.validation_actions = validation_actions - - @property - def match_resources(self): - """Gets the match_resources of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - - - :return: The match_resources of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :rtype: V1alpha1MatchResources - """ - return self._match_resources - - @match_resources.setter - def match_resources(self, match_resources): - """Sets the match_resources of this V1alpha1ValidatingAdmissionPolicyBindingSpec. - - - :param match_resources: The match_resources of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :type: V1alpha1MatchResources - """ - - self._match_resources = match_resources - - @property - def param_ref(self): - """Gets the param_ref of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - - - :return: The param_ref of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :rtype: V1alpha1ParamRef - """ - return self._param_ref - - @param_ref.setter - def param_ref(self, param_ref): - """Sets the param_ref of this V1alpha1ValidatingAdmissionPolicyBindingSpec. - - - :param param_ref: The param_ref of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :type: V1alpha1ParamRef - """ - - self._param_ref = param_ref - - @property - def policy_name(self): - """Gets the policy_name of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - - PolicyName references a ValidatingAdmissionPolicy name which the ValidatingAdmissionPolicyBinding binds to. If the referenced resource does not exist, this binding is considered invalid and will be ignored Required. # noqa: E501 - - :return: The policy_name of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :rtype: str - """ - return self._policy_name - - @policy_name.setter - def policy_name(self, policy_name): - """Sets the policy_name of this V1alpha1ValidatingAdmissionPolicyBindingSpec. - - PolicyName references a ValidatingAdmissionPolicy name which the ValidatingAdmissionPolicyBinding binds to. If the referenced resource does not exist, this binding is considered invalid and will be ignored Required. # noqa: E501 - - :param policy_name: The policy_name of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :type: str - """ - - self._policy_name = policy_name - - @property - def validation_actions(self): - """Gets the validation_actions of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - - validationActions declares how Validations of the referenced ValidatingAdmissionPolicy are enforced. If a validation evaluates to false it is always enforced according to these actions. Failures defined by the ValidatingAdmissionPolicy's FailurePolicy are enforced according to these actions only if the FailurePolicy is set to Fail, otherwise the failures are ignored. This includes compilation errors, runtime errors and misconfigurations of the policy. validationActions is declared as a set of action values. Order does not matter. validationActions may not contain duplicates of the same action. The supported actions values are: \"Deny\" specifies that a validation failure results in a denied request. \"Warn\" specifies that a validation failure is reported to the request client in HTTP Warning headers, with a warning code of 299. Warnings can be sent both for allowed or denied admission responses. \"Audit\" specifies that a validation failure is included in the published audit event for the request. The audit event will contain a `validation.policy.admission.k8s.io/validation_failure` audit annotation with a value containing the details of the validation failures, formatted as a JSON list of objects, each with the following fields: - message: The validation failure message string - policy: The resource name of the ValidatingAdmissionPolicy - binding: The resource name of the ValidatingAdmissionPolicyBinding - expressionIndex: The index of the failed validations in the ValidatingAdmissionPolicy - validationActions: The enforcement actions enacted for the validation failure Example audit annotation: `\"validation.policy.admission.k8s.io/validation_failure\": \"[{\"message\": \"Invalid value\", {\"policy\": \"policy.example.com\", {\"binding\": \"policybinding.example.com\", {\"expressionIndex\": \"1\", {\"validationActions\": [\"Audit\"]}]\"` Clients should expect to handle additional values by ignoring any values not recognized. \"Deny\" and \"Warn\" may not be used together since this combination needlessly duplicates the validation failure both in the API response body and the HTTP warning headers. Required. # noqa: E501 - - :return: The validation_actions of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :rtype: list[str] - """ - return self._validation_actions - - @validation_actions.setter - def validation_actions(self, validation_actions): - """Sets the validation_actions of this V1alpha1ValidatingAdmissionPolicyBindingSpec. - - validationActions declares how Validations of the referenced ValidatingAdmissionPolicy are enforced. If a validation evaluates to false it is always enforced according to these actions. Failures defined by the ValidatingAdmissionPolicy's FailurePolicy are enforced according to these actions only if the FailurePolicy is set to Fail, otherwise the failures are ignored. This includes compilation errors, runtime errors and misconfigurations of the policy. validationActions is declared as a set of action values. Order does not matter. validationActions may not contain duplicates of the same action. The supported actions values are: \"Deny\" specifies that a validation failure results in a denied request. \"Warn\" specifies that a validation failure is reported to the request client in HTTP Warning headers, with a warning code of 299. Warnings can be sent both for allowed or denied admission responses. \"Audit\" specifies that a validation failure is included in the published audit event for the request. The audit event will contain a `validation.policy.admission.k8s.io/validation_failure` audit annotation with a value containing the details of the validation failures, formatted as a JSON list of objects, each with the following fields: - message: The validation failure message string - policy: The resource name of the ValidatingAdmissionPolicy - binding: The resource name of the ValidatingAdmissionPolicyBinding - expressionIndex: The index of the failed validations in the ValidatingAdmissionPolicy - validationActions: The enforcement actions enacted for the validation failure Example audit annotation: `\"validation.policy.admission.k8s.io/validation_failure\": \"[{\"message\": \"Invalid value\", {\"policy\": \"policy.example.com\", {\"binding\": \"policybinding.example.com\", {\"expressionIndex\": \"1\", {\"validationActions\": [\"Audit\"]}]\"` Clients should expect to handle additional values by ignoring any values not recognized. \"Deny\" and \"Warn\" may not be used together since this combination needlessly duplicates the validation failure both in the API response body and the HTTP warning headers. Required. # noqa: E501 - - :param validation_actions: The validation_actions of this V1alpha1ValidatingAdmissionPolicyBindingSpec. # noqa: E501 - :type: list[str] - """ - - self._validation_actions = validation_actions - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyBindingSpec): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyBindingSpec): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_list.py deleted file mode 100644 index 8d22f6c4c851..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_list.py +++ /dev/null @@ -1,205 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ValidatingAdmissionPolicyList(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'items': 'list[V1alpha1ValidatingAdmissionPolicy]', - 'kind': 'str', - 'metadata': 'V1ListMeta' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'items': 'items', - 'kind': 'kind', - 'metadata': 'metadata' - } - - def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicyList - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._items = None - self._kind = None - self._metadata = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.items = items - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - - @property - def api_version(self): - """Gets the api_version of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha1ValidatingAdmissionPolicyList. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def items(self): - """Gets the items of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - - List of ValidatingAdmissionPolicy. # noqa: E501 - - :return: The items of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :rtype: list[V1alpha1ValidatingAdmissionPolicy] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this V1alpha1ValidatingAdmissionPolicyList. - - List of ValidatingAdmissionPolicy. # noqa: E501 - - :param items: The items of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :type: list[V1alpha1ValidatingAdmissionPolicy] - """ - if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 - raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 - - self._items = items - - @property - def kind(self): - """Gets the kind of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha1ValidatingAdmissionPolicyList. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - - - :return: The metadata of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :rtype: V1ListMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha1ValidatingAdmissionPolicyList. - - - :param metadata: The metadata of this V1alpha1ValidatingAdmissionPolicyList. # noqa: E501 - :type: V1ListMeta - """ - - self._metadata = metadata - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyList): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyList): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_spec.py deleted file mode 100644 index e254ebe9f0af..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_spec.py +++ /dev/null @@ -1,286 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ValidatingAdmissionPolicySpec(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'audit_annotations': 'list[V1alpha1AuditAnnotation]', - 'failure_policy': 'str', - 'match_conditions': 'list[V1alpha1MatchCondition]', - 'match_constraints': 'V1alpha1MatchResources', - 'param_kind': 'V1alpha1ParamKind', - 'validations': 'list[V1alpha1Validation]', - 'variables': 'list[V1alpha1Variable]' - } - - attribute_map = { - 'audit_annotations': 'auditAnnotations', - 'failure_policy': 'failurePolicy', - 'match_conditions': 'matchConditions', - 'match_constraints': 'matchConstraints', - 'param_kind': 'paramKind', - 'validations': 'validations', - 'variables': 'variables' - } - - def __init__(self, audit_annotations=None, failure_policy=None, match_conditions=None, match_constraints=None, param_kind=None, validations=None, variables=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicySpec - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._audit_annotations = None - self._failure_policy = None - self._match_conditions = None - self._match_constraints = None - self._param_kind = None - self._validations = None - self._variables = None - self.discriminator = None - - if audit_annotations is not None: - self.audit_annotations = audit_annotations - if failure_policy is not None: - self.failure_policy = failure_policy - if match_conditions is not None: - self.match_conditions = match_conditions - if match_constraints is not None: - self.match_constraints = match_constraints - if param_kind is not None: - self.param_kind = param_kind - if validations is not None: - self.validations = validations - if variables is not None: - self.variables = variables - - @property - def audit_annotations(self): - """Gets the audit_annotations of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - auditAnnotations contains CEL expressions which are used to produce audit annotations for the audit event of the API request. validations and auditAnnotations may not both be empty; a least one of validations or auditAnnotations is required. # noqa: E501 - - :return: The audit_annotations of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: list[V1alpha1AuditAnnotation] - """ - return self._audit_annotations - - @audit_annotations.setter - def audit_annotations(self, audit_annotations): - """Sets the audit_annotations of this V1alpha1ValidatingAdmissionPolicySpec. - - auditAnnotations contains CEL expressions which are used to produce audit annotations for the audit event of the API request. validations and auditAnnotations may not both be empty; a least one of validations or auditAnnotations is required. # noqa: E501 - - :param audit_annotations: The audit_annotations of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: list[V1alpha1AuditAnnotation] - """ - - self._audit_annotations = audit_annotations - - @property - def failure_policy(self): - """Gets the failure_policy of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - failurePolicy defines how to handle failures for the admission policy. Failures can occur from CEL expression parse errors, type check errors, runtime errors and invalid or mis-configured policy definitions or bindings. A policy is invalid if spec.paramKind refers to a non-existent Kind. A binding is invalid if spec.paramRef.name refers to a non-existent resource. failurePolicy does not define how validations that evaluate to false are handled. When failurePolicy is set to Fail, ValidatingAdmissionPolicyBinding validationActions define how failures are enforced. Allowed values are Ignore or Fail. Defaults to Fail. # noqa: E501 - - :return: The failure_policy of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: str - """ - return self._failure_policy - - @failure_policy.setter - def failure_policy(self, failure_policy): - """Sets the failure_policy of this V1alpha1ValidatingAdmissionPolicySpec. - - failurePolicy defines how to handle failures for the admission policy. Failures can occur from CEL expression parse errors, type check errors, runtime errors and invalid or mis-configured policy definitions or bindings. A policy is invalid if spec.paramKind refers to a non-existent Kind. A binding is invalid if spec.paramRef.name refers to a non-existent resource. failurePolicy does not define how validations that evaluate to false are handled. When failurePolicy is set to Fail, ValidatingAdmissionPolicyBinding validationActions define how failures are enforced. Allowed values are Ignore or Fail. Defaults to Fail. # noqa: E501 - - :param failure_policy: The failure_policy of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: str - """ - - self._failure_policy = failure_policy - - @property - def match_conditions(self): - """Gets the match_conditions of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - MatchConditions is a list of conditions that must be met for a request to be validated. Match conditions filter requests that have already been matched by the rules, namespaceSelector, and objectSelector. An empty list of matchConditions matches all requests. There are a maximum of 64 match conditions allowed. If a parameter object is provided, it can be accessed via the `params` handle in the same manner as validation expressions. The exact matching logic is (in order): 1. If ANY matchCondition evaluates to FALSE, the policy is skipped. 2. If ALL matchConditions evaluate to TRUE, the policy is evaluated. 3. If any matchCondition evaluates to an error (but none are FALSE): - If failurePolicy=Fail, reject the request - If failurePolicy=Ignore, the policy is skipped # noqa: E501 - - :return: The match_conditions of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: list[V1alpha1MatchCondition] - """ - return self._match_conditions - - @match_conditions.setter - def match_conditions(self, match_conditions): - """Sets the match_conditions of this V1alpha1ValidatingAdmissionPolicySpec. - - MatchConditions is a list of conditions that must be met for a request to be validated. Match conditions filter requests that have already been matched by the rules, namespaceSelector, and objectSelector. An empty list of matchConditions matches all requests. There are a maximum of 64 match conditions allowed. If a parameter object is provided, it can be accessed via the `params` handle in the same manner as validation expressions. The exact matching logic is (in order): 1. If ANY matchCondition evaluates to FALSE, the policy is skipped. 2. If ALL matchConditions evaluate to TRUE, the policy is evaluated. 3. If any matchCondition evaluates to an error (but none are FALSE): - If failurePolicy=Fail, reject the request - If failurePolicy=Ignore, the policy is skipped # noqa: E501 - - :param match_conditions: The match_conditions of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: list[V1alpha1MatchCondition] - """ - - self._match_conditions = match_conditions - - @property - def match_constraints(self): - """Gets the match_constraints of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - - :return: The match_constraints of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: V1alpha1MatchResources - """ - return self._match_constraints - - @match_constraints.setter - def match_constraints(self, match_constraints): - """Sets the match_constraints of this V1alpha1ValidatingAdmissionPolicySpec. - - - :param match_constraints: The match_constraints of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: V1alpha1MatchResources - """ - - self._match_constraints = match_constraints - - @property - def param_kind(self): - """Gets the param_kind of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - - :return: The param_kind of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: V1alpha1ParamKind - """ - return self._param_kind - - @param_kind.setter - def param_kind(self, param_kind): - """Sets the param_kind of this V1alpha1ValidatingAdmissionPolicySpec. - - - :param param_kind: The param_kind of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: V1alpha1ParamKind - """ - - self._param_kind = param_kind - - @property - def validations(self): - """Gets the validations of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - Validations contain CEL expressions which is used to apply the validation. Validations and AuditAnnotations may not both be empty; a minimum of one Validations or AuditAnnotations is required. # noqa: E501 - - :return: The validations of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: list[V1alpha1Validation] - """ - return self._validations - - @validations.setter - def validations(self, validations): - """Sets the validations of this V1alpha1ValidatingAdmissionPolicySpec. - - Validations contain CEL expressions which is used to apply the validation. Validations and AuditAnnotations may not both be empty; a minimum of one Validations or AuditAnnotations is required. # noqa: E501 - - :param validations: The validations of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: list[V1alpha1Validation] - """ - - self._validations = validations - - @property - def variables(self): - """Gets the variables of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - - Variables contain definitions of variables that can be used in composition of other expressions. Each variable is defined as a named CEL expression. The variables defined here will be available under `variables` in other expressions of the policy except MatchConditions because MatchConditions are evaluated before the rest of the policy. The expression of a variable can refer to other variables defined earlier in the list but not those after. Thus, Variables must be sorted by the order of first appearance and acyclic. # noqa: E501 - - :return: The variables of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :rtype: list[V1alpha1Variable] - """ - return self._variables - - @variables.setter - def variables(self, variables): - """Sets the variables of this V1alpha1ValidatingAdmissionPolicySpec. - - Variables contain definitions of variables that can be used in composition of other expressions. Each variable is defined as a named CEL expression. The variables defined here will be available under `variables` in other expressions of the policy except MatchConditions because MatchConditions are evaluated before the rest of the policy. The expression of a variable can refer to other variables defined earlier in the list but not those after. Thus, Variables must be sorted by the order of first appearance and acyclic. # noqa: E501 - - :param variables: The variables of this V1alpha1ValidatingAdmissionPolicySpec. # noqa: E501 - :type: list[V1alpha1Variable] - """ - - self._variables = variables - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicySpec): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicySpec): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_status.py deleted file mode 100644 index d6f8fb7ff525..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_status.py +++ /dev/null @@ -1,176 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1ValidatingAdmissionPolicyStatus(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'conditions': 'list[V1Condition]', - 'observed_generation': 'int', - 'type_checking': 'V1alpha1TypeChecking' - } - - attribute_map = { - 'conditions': 'conditions', - 'observed_generation': 'observedGeneration', - 'type_checking': 'typeChecking' - } - - def __init__(self, conditions=None, observed_generation=None, type_checking=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicyStatus - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._conditions = None - self._observed_generation = None - self._type_checking = None - self.discriminator = None - - if conditions is not None: - self.conditions = conditions - if observed_generation is not None: - self.observed_generation = observed_generation - if type_checking is not None: - self.type_checking = type_checking - - @property - def conditions(self): - """Gets the conditions of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - - The conditions represent the latest available observations of a policy's current state. # noqa: E501 - - :return: The conditions of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - :rtype: list[V1Condition] - """ - return self._conditions - - @conditions.setter - def conditions(self, conditions): - """Sets the conditions of this V1alpha1ValidatingAdmissionPolicyStatus. - - The conditions represent the latest available observations of a policy's current state. # noqa: E501 - - :param conditions: The conditions of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - :type: list[V1Condition] - """ - - self._conditions = conditions - - @property - def observed_generation(self): - """Gets the observed_generation of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - - The generation observed by the controller. # noqa: E501 - - :return: The observed_generation of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - :rtype: int - """ - return self._observed_generation - - @observed_generation.setter - def observed_generation(self, observed_generation): - """Sets the observed_generation of this V1alpha1ValidatingAdmissionPolicyStatus. - - The generation observed by the controller. # noqa: E501 - - :param observed_generation: The observed_generation of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - :type: int - """ - - self._observed_generation = observed_generation - - @property - def type_checking(self): - """Gets the type_checking of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - - - :return: The type_checking of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - :rtype: V1alpha1TypeChecking - """ - return self._type_checking - - @type_checking.setter - def type_checking(self, type_checking): - """Sets the type_checking of this V1alpha1ValidatingAdmissionPolicyStatus. - - - :param type_checking: The type_checking of this V1alpha1ValidatingAdmissionPolicyStatus. # noqa: E501 - :type: V1alpha1TypeChecking - """ - - self._type_checking = type_checking - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyStatus): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyStatus): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validation.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validation.py deleted file mode 100644 index 505a2a04755b..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validation.py +++ /dev/null @@ -1,207 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.31 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha1Validation(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'expression': 'str', - 'message': 'str', - 'message_expression': 'str', - 'reason': 'str' - } - - attribute_map = { - 'expression': 'expression', - 'message': 'message', - 'message_expression': 'messageExpression', - 'reason': 'reason' - } - - def __init__(self, expression=None, message=None, message_expression=None, reason=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1Validation - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._expression = None - self._message = None - self._message_expression = None - self._reason = None - self.discriminator = None - - self.expression = expression - if message is not None: - self.message = message - if message_expression is not None: - self.message_expression = message_expression - if reason is not None: - self.reason = reason - - @property - def expression(self): - """Gets the expression of this V1alpha1Validation. # noqa: E501 - - Expression represents the expression which will be evaluated by CEL. ref: https://github.com/google/cel-spec CEL expressions have access to the contents of the API request/response, organized into CEL variables as well as some other useful variables: - 'object' - The object from the incoming request. The value is null for DELETE requests. - 'oldObject' - The existing object. The value is null for CREATE requests. - 'request' - Attributes of the API request([ref](/pkg/apis/admission/types.go#AdmissionRequest)). - 'params' - Parameter resource referred to by the policy binding being evaluated. Only populated if the policy has a ParamKind. - 'namespaceObject' - The namespace object that the incoming object belongs to. The value is null for cluster-scoped resources. - 'variables' - Map of composited variables, from its name to its lazily evaluated value. For example, a variable named 'foo' can be accessed as 'variables.foo'. - 'authorizer' - A CEL Authorizer. May be used to perform authorization checks for the principal (user or service account) of the request. See https://pkg.go.dev/k8s.io/apiserver/pkg/cel/library#Authz - 'authorizer.requestResource' - A CEL ResourceCheck constructed from the 'authorizer' and configured with the request resource. The `apiVersion`, `kind`, `metadata.name` and `metadata.generateName` are always accessible from the root of the object. No other metadata properties are accessible. Only property names of the form `[a-zA-Z_.-/][a-zA-Z0-9_.-/]*` are accessible. Accessible property names are escaped according to the following rules when accessed in the expression: - '__' escapes to '__underscores__' - '.' escapes to '__dot__' - '-' escapes to '__dash__' - '/' escapes to '__slash__' - Property names that exactly match a CEL RESERVED keyword escape to '__{keyword}__'. The keywords are: \"true\", \"false\", \"null\", \"in\", \"as\", \"break\", \"const\", \"continue\", \"else\", \"for\", \"function\", \"if\", \"import\", \"let\", \"loop\", \"package\", \"namespace\", \"return\". Examples: - Expression accessing a property named \"namespace\": {\"Expression\": \"object.__namespace__ > 0\"} - Expression accessing a property named \"x-prop\": {\"Expression\": \"object.x__dash__prop > 0\"} - Expression accessing a property named \"redact__d\": {\"Expression\": \"object.redact__underscores__d > 0\"} Equality on arrays with list type of 'set' or 'map' ignores element order, i.e. [1, 2] == [2, 1]. Concatenation on arrays with x-kubernetes-list-type use the semantics of the list type: - 'set': `X + Y` performs a union where the array positions of all elements in `X` are preserved and non-intersecting elements in `Y` are appended, retaining their partial order. - 'map': `X + Y` performs a merge where the array positions of all keys in `X` are preserved but the values are overwritten by values in `Y` when the key sets of `X` and `Y` intersect. Elements in `Y` with non-intersecting keys are appended, retaining their partial order. Required. # noqa: E501 - - :return: The expression of this V1alpha1Validation. # noqa: E501 - :rtype: str - """ - return self._expression - - @expression.setter - def expression(self, expression): - """Sets the expression of this V1alpha1Validation. - - Expression represents the expression which will be evaluated by CEL. ref: https://github.com/google/cel-spec CEL expressions have access to the contents of the API request/response, organized into CEL variables as well as some other useful variables: - 'object' - The object from the incoming request. The value is null for DELETE requests. - 'oldObject' - The existing object. The value is null for CREATE requests. - 'request' - Attributes of the API request([ref](/pkg/apis/admission/types.go#AdmissionRequest)). - 'params' - Parameter resource referred to by the policy binding being evaluated. Only populated if the policy has a ParamKind. - 'namespaceObject' - The namespace object that the incoming object belongs to. The value is null for cluster-scoped resources. - 'variables' - Map of composited variables, from its name to its lazily evaluated value. For example, a variable named 'foo' can be accessed as 'variables.foo'. - 'authorizer' - A CEL Authorizer. May be used to perform authorization checks for the principal (user or service account) of the request. See https://pkg.go.dev/k8s.io/apiserver/pkg/cel/library#Authz - 'authorizer.requestResource' - A CEL ResourceCheck constructed from the 'authorizer' and configured with the request resource. The `apiVersion`, `kind`, `metadata.name` and `metadata.generateName` are always accessible from the root of the object. No other metadata properties are accessible. Only property names of the form `[a-zA-Z_.-/][a-zA-Z0-9_.-/]*` are accessible. Accessible property names are escaped according to the following rules when accessed in the expression: - '__' escapes to '__underscores__' - '.' escapes to '__dot__' - '-' escapes to '__dash__' - '/' escapes to '__slash__' - Property names that exactly match a CEL RESERVED keyword escape to '__{keyword}__'. The keywords are: \"true\", \"false\", \"null\", \"in\", \"as\", \"break\", \"const\", \"continue\", \"else\", \"for\", \"function\", \"if\", \"import\", \"let\", \"loop\", \"package\", \"namespace\", \"return\". Examples: - Expression accessing a property named \"namespace\": {\"Expression\": \"object.__namespace__ > 0\"} - Expression accessing a property named \"x-prop\": {\"Expression\": \"object.x__dash__prop > 0\"} - Expression accessing a property named \"redact__d\": {\"Expression\": \"object.redact__underscores__d > 0\"} Equality on arrays with list type of 'set' or 'map' ignores element order, i.e. [1, 2] == [2, 1]. Concatenation on arrays with x-kubernetes-list-type use the semantics of the list type: - 'set': `X + Y` performs a union where the array positions of all elements in `X` are preserved and non-intersecting elements in `Y` are appended, retaining their partial order. - 'map': `X + Y` performs a merge where the array positions of all keys in `X` are preserved but the values are overwritten by values in `Y` when the key sets of `X` and `Y` intersect. Elements in `Y` with non-intersecting keys are appended, retaining their partial order. Required. # noqa: E501 - - :param expression: The expression of this V1alpha1Validation. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and expression is None: # noqa: E501 - raise ValueError("Invalid value for `expression`, must not be `None`") # noqa: E501 - - self._expression = expression - - @property - def message(self): - """Gets the message of this V1alpha1Validation. # noqa: E501 - - Message represents the message displayed when validation fails. The message is required if the Expression contains line breaks. The message must not contain line breaks. If unset, the message is \"failed rule: {Rule}\". e.g. \"must be a URL with the host matching spec.host\" If the Expression contains line breaks. Message is required. The message must not contain line breaks. If unset, the message is \"failed Expression: {Expression}\". # noqa: E501 - - :return: The message of this V1alpha1Validation. # noqa: E501 - :rtype: str - """ - return self._message - - @message.setter - def message(self, message): - """Sets the message of this V1alpha1Validation. - - Message represents the message displayed when validation fails. The message is required if the Expression contains line breaks. The message must not contain line breaks. If unset, the message is \"failed rule: {Rule}\". e.g. \"must be a URL with the host matching spec.host\" If the Expression contains line breaks. Message is required. The message must not contain line breaks. If unset, the message is \"failed Expression: {Expression}\". # noqa: E501 - - :param message: The message of this V1alpha1Validation. # noqa: E501 - :type: str - """ - - self._message = message - - @property - def message_expression(self): - """Gets the message_expression of this V1alpha1Validation. # noqa: E501 - - messageExpression declares a CEL expression that evaluates to the validation failure message that is returned when this rule fails. Since messageExpression is used as a failure message, it must evaluate to a string. If both message and messageExpression are present on a validation, then messageExpression will be used if validation fails. If messageExpression results in a runtime error, the runtime error is logged, and the validation failure message is produced as if the messageExpression field were unset. If messageExpression evaluates to an empty string, a string with only spaces, or a string that contains line breaks, then the validation failure message will also be produced as if the messageExpression field were unset, and the fact that messageExpression produced an empty string/string with only spaces/string with line breaks will be logged. messageExpression has access to all the same variables as the `expression` except for 'authorizer' and 'authorizer.requestResource'. Example: \"object.x must be less than max (\"+string(params.max)+\")\" # noqa: E501 - - :return: The message_expression of this V1alpha1Validation. # noqa: E501 - :rtype: str - """ - return self._message_expression - - @message_expression.setter - def message_expression(self, message_expression): - """Sets the message_expression of this V1alpha1Validation. - - messageExpression declares a CEL expression that evaluates to the validation failure message that is returned when this rule fails. Since messageExpression is used as a failure message, it must evaluate to a string. If both message and messageExpression are present on a validation, then messageExpression will be used if validation fails. If messageExpression results in a runtime error, the runtime error is logged, and the validation failure message is produced as if the messageExpression field were unset. If messageExpression evaluates to an empty string, a string with only spaces, or a string that contains line breaks, then the validation failure message will also be produced as if the messageExpression field were unset, and the fact that messageExpression produced an empty string/string with only spaces/string with line breaks will be logged. messageExpression has access to all the same variables as the `expression` except for 'authorizer' and 'authorizer.requestResource'. Example: \"object.x must be less than max (\"+string(params.max)+\")\" # noqa: E501 - - :param message_expression: The message_expression of this V1alpha1Validation. # noqa: E501 - :type: str - """ - - self._message_expression = message_expression - - @property - def reason(self): - """Gets the reason of this V1alpha1Validation. # noqa: E501 - - Reason represents a machine-readable description of why this validation failed. If this is the first validation in the list to fail, this reason, as well as the corresponding HTTP response code, are used in the HTTP response to the client. The currently supported reasons are: \"Unauthorized\", \"Forbidden\", \"Invalid\", \"RequestEntityTooLarge\". If not set, StatusReasonInvalid is used in the response to the client. # noqa: E501 - - :return: The reason of this V1alpha1Validation. # noqa: E501 - :rtype: str - """ - return self._reason - - @reason.setter - def reason(self, reason): - """Sets the reason of this V1alpha1Validation. - - Reason represents a machine-readable description of why this validation failed. If this is the first validation in the list to fail, this reason, as well as the corresponding HTTP response code, are used in the HTTP response to the client. The currently supported reasons are: \"Unauthorized\", \"Forbidden\", \"Invalid\", \"RequestEntityTooLarge\". If not set, StatusReasonInvalid is used in the response to the client. # noqa: E501 - - :param reason: The reason of this V1alpha1Validation. # noqa: E501 - :type: str - """ - - self._reason = reason - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1Validation): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1Validation): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_variable.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_variable.py index 1dd8c32273a3..561167c4747c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_variable.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_variable.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class.py index 109815fccf6e..0b91d46af41c 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class_list.py index bdb00ffce941..80c5366a2ba7 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_volume_attributes_class_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_allocation_result.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_allocation_result.py deleted file mode 100644 index 4be9a639f876..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_allocation_result.py +++ /dev/null @@ -1,176 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2AllocationResult(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'available_on_nodes': 'V1NodeSelector', - 'resource_handles': 'list[V1alpha2ResourceHandle]', - 'shareable': 'bool' - } - - attribute_map = { - 'available_on_nodes': 'availableOnNodes', - 'resource_handles': 'resourceHandles', - 'shareable': 'shareable' - } - - def __init__(self, available_on_nodes=None, resource_handles=None, shareable=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2AllocationResult - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._available_on_nodes = None - self._resource_handles = None - self._shareable = None - self.discriminator = None - - if available_on_nodes is not None: - self.available_on_nodes = available_on_nodes - if resource_handles is not None: - self.resource_handles = resource_handles - if shareable is not None: - self.shareable = shareable - - @property - def available_on_nodes(self): - """Gets the available_on_nodes of this V1alpha2AllocationResult. # noqa: E501 - - - :return: The available_on_nodes of this V1alpha2AllocationResult. # noqa: E501 - :rtype: V1NodeSelector - """ - return self._available_on_nodes - - @available_on_nodes.setter - def available_on_nodes(self, available_on_nodes): - """Sets the available_on_nodes of this V1alpha2AllocationResult. - - - :param available_on_nodes: The available_on_nodes of this V1alpha2AllocationResult. # noqa: E501 - :type: V1NodeSelector - """ - - self._available_on_nodes = available_on_nodes - - @property - def resource_handles(self): - """Gets the resource_handles of this V1alpha2AllocationResult. # noqa: E501 - - ResourceHandles contain the state associated with an allocation that should be maintained throughout the lifetime of a claim. Each ResourceHandle contains data that should be passed to a specific kubelet plugin once it lands on a node. This data is returned by the driver after a successful allocation and is opaque to Kubernetes. Driver documentation may explain to users how to interpret this data if needed. Setting this field is optional. It has a maximum size of 32 entries. If null (or empty), it is assumed this allocation will be processed by a single kubelet plugin with no ResourceHandle data attached. The name of the kubelet plugin invoked will match the DriverName set in the ResourceClaimStatus this AllocationResult is embedded in. # noqa: E501 - - :return: The resource_handles of this V1alpha2AllocationResult. # noqa: E501 - :rtype: list[V1alpha2ResourceHandle] - """ - return self._resource_handles - - @resource_handles.setter - def resource_handles(self, resource_handles): - """Sets the resource_handles of this V1alpha2AllocationResult. - - ResourceHandles contain the state associated with an allocation that should be maintained throughout the lifetime of a claim. Each ResourceHandle contains data that should be passed to a specific kubelet plugin once it lands on a node. This data is returned by the driver after a successful allocation and is opaque to Kubernetes. Driver documentation may explain to users how to interpret this data if needed. Setting this field is optional. It has a maximum size of 32 entries. If null (or empty), it is assumed this allocation will be processed by a single kubelet plugin with no ResourceHandle data attached. The name of the kubelet plugin invoked will match the DriverName set in the ResourceClaimStatus this AllocationResult is embedded in. # noqa: E501 - - :param resource_handles: The resource_handles of this V1alpha2AllocationResult. # noqa: E501 - :type: list[V1alpha2ResourceHandle] - """ - - self._resource_handles = resource_handles - - @property - def shareable(self): - """Gets the shareable of this V1alpha2AllocationResult. # noqa: E501 - - Shareable determines whether the resource supports more than one consumer at a time. # noqa: E501 - - :return: The shareable of this V1alpha2AllocationResult. # noqa: E501 - :rtype: bool - """ - return self._shareable - - @shareable.setter - def shareable(self, shareable): - """Sets the shareable of this V1alpha2AllocationResult. - - Shareable determines whether the resource supports more than one consumer at a time. # noqa: E501 - - :param shareable: The shareable of this V1alpha2AllocationResult. # noqa: E501 - :type: bool - """ - - self._shareable = shareable - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2AllocationResult): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2AllocationResult): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_driver_allocation_result.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_driver_allocation_result.py deleted file mode 100644 index 9db8c8b4ba3e..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_driver_allocation_result.py +++ /dev/null @@ -1,148 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2DriverAllocationResult(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'named_resources': 'V1alpha2NamedResourcesAllocationResult', - 'vendor_request_parameters': 'object' - } - - attribute_map = { - 'named_resources': 'namedResources', - 'vendor_request_parameters': 'vendorRequestParameters' - } - - def __init__(self, named_resources=None, vendor_request_parameters=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2DriverAllocationResult - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._named_resources = None - self._vendor_request_parameters = None - self.discriminator = None - - if named_resources is not None: - self.named_resources = named_resources - if vendor_request_parameters is not None: - self.vendor_request_parameters = vendor_request_parameters - - @property - def named_resources(self): - """Gets the named_resources of this V1alpha2DriverAllocationResult. # noqa: E501 - - - :return: The named_resources of this V1alpha2DriverAllocationResult. # noqa: E501 - :rtype: V1alpha2NamedResourcesAllocationResult - """ - return self._named_resources - - @named_resources.setter - def named_resources(self, named_resources): - """Sets the named_resources of this V1alpha2DriverAllocationResult. - - - :param named_resources: The named_resources of this V1alpha2DriverAllocationResult. # noqa: E501 - :type: V1alpha2NamedResourcesAllocationResult - """ - - self._named_resources = named_resources - - @property - def vendor_request_parameters(self): - """Gets the vendor_request_parameters of this V1alpha2DriverAllocationResult. # noqa: E501 - - VendorRequestParameters are the per-request configuration parameters from the time that the claim was allocated. # noqa: E501 - - :return: The vendor_request_parameters of this V1alpha2DriverAllocationResult. # noqa: E501 - :rtype: object - """ - return self._vendor_request_parameters - - @vendor_request_parameters.setter - def vendor_request_parameters(self, vendor_request_parameters): - """Sets the vendor_request_parameters of this V1alpha2DriverAllocationResult. - - VendorRequestParameters are the per-request configuration parameters from the time that the claim was allocated. # noqa: E501 - - :param vendor_request_parameters: The vendor_request_parameters of this V1alpha2DriverAllocationResult. # noqa: E501 - :type: object - """ - - self._vendor_request_parameters = vendor_request_parameters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2DriverAllocationResult): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2DriverAllocationResult): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_driver_requests.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_driver_requests.py deleted file mode 100644 index f6ee724b4b0e..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_driver_requests.py +++ /dev/null @@ -1,178 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2DriverRequests(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'driver_name': 'str', - 'requests': 'list[V1alpha2ResourceRequest]', - 'vendor_parameters': 'object' - } - - attribute_map = { - 'driver_name': 'driverName', - 'requests': 'requests', - 'vendor_parameters': 'vendorParameters' - } - - def __init__(self, driver_name=None, requests=None, vendor_parameters=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2DriverRequests - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._driver_name = None - self._requests = None - self._vendor_parameters = None - self.discriminator = None - - if driver_name is not None: - self.driver_name = driver_name - if requests is not None: - self.requests = requests - if vendor_parameters is not None: - self.vendor_parameters = vendor_parameters - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2DriverRequests. # noqa: E501 - - DriverName is the name used by the DRA driver kubelet plugin. # noqa: E501 - - :return: The driver_name of this V1alpha2DriverRequests. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2DriverRequests. - - DriverName is the name used by the DRA driver kubelet plugin. # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2DriverRequests. # noqa: E501 - :type: str - """ - - self._driver_name = driver_name - - @property - def requests(self): - """Gets the requests of this V1alpha2DriverRequests. # noqa: E501 - - Requests describes all resources that are needed from the driver. # noqa: E501 - - :return: The requests of this V1alpha2DriverRequests. # noqa: E501 - :rtype: list[V1alpha2ResourceRequest] - """ - return self._requests - - @requests.setter - def requests(self, requests): - """Sets the requests of this V1alpha2DriverRequests. - - Requests describes all resources that are needed from the driver. # noqa: E501 - - :param requests: The requests of this V1alpha2DriverRequests. # noqa: E501 - :type: list[V1alpha2ResourceRequest] - """ - - self._requests = requests - - @property - def vendor_parameters(self): - """Gets the vendor_parameters of this V1alpha2DriverRequests. # noqa: E501 - - VendorParameters are arbitrary setup parameters for all requests of the claim. They are ignored while allocating the claim. # noqa: E501 - - :return: The vendor_parameters of this V1alpha2DriverRequests. # noqa: E501 - :rtype: object - """ - return self._vendor_parameters - - @vendor_parameters.setter - def vendor_parameters(self, vendor_parameters): - """Sets the vendor_parameters of this V1alpha2DriverRequests. - - VendorParameters are arbitrary setup parameters for all requests of the claim. They are ignored while allocating the claim. # noqa: E501 - - :param vendor_parameters: The vendor_parameters of this V1alpha2DriverRequests. # noqa: E501 - :type: object - """ - - self._vendor_parameters = vendor_parameters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2DriverRequests): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2DriverRequests): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate.py index 432f63d46989..d66d7cfa44fe 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_list.py index 0108d85e04b2..4e40bdbe2917 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_spec.py index e31393d678e6..af1fcfde0950 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_lease_candidate_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -197,7 +197,7 @@ def renew_time(self, renew_time): def strategy(self): """Gets the strategy of this V1alpha2LeaseCandidateSpec. # noqa: E501 - Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved. (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled. # noqa: E501 + Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved. # noqa: E501 :return: The strategy of this V1alpha2LeaseCandidateSpec. # noqa: E501 :rtype: str @@ -208,7 +208,7 @@ def strategy(self): def strategy(self, strategy): """Sets the strategy of this V1alpha2LeaseCandidateSpec. - Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved. (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled. # noqa: E501 + Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved. # noqa: E501 :param strategy: The strategy of this V1alpha2LeaseCandidateSpec. # noqa: E501 :type: str diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_allocation_result.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_allocation_result.py deleted file mode 100644 index ec5b2d8904b6..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_allocation_result.py +++ /dev/null @@ -1,123 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2NamedResourcesAllocationResult(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'name': 'str' - } - - attribute_map = { - 'name': 'name' - } - - def __init__(self, name=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2NamedResourcesAllocationResult - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._name = None - self.discriminator = None - - self.name = name - - @property - def name(self): - """Gets the name of this V1alpha2NamedResourcesAllocationResult. # noqa: E501 - - Name is the name of the selected resource instance. # noqa: E501 - - :return: The name of this V1alpha2NamedResourcesAllocationResult. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this V1alpha2NamedResourcesAllocationResult. - - Name is the name of the selected resource instance. # noqa: E501 - - :param name: The name of this V1alpha2NamedResourcesAllocationResult. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2NamedResourcesAllocationResult): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2NamedResourcesAllocationResult): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_attribute.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_attribute.py deleted file mode 100644 index b13b16f151b2..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_attribute.py +++ /dev/null @@ -1,315 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2NamedResourcesAttribute(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'bool': 'bool', - 'int': 'int', - 'int_slice': 'V1alpha2NamedResourcesIntSlice', - 'name': 'str', - 'quantity': 'str', - 'string': 'str', - 'string_slice': 'V1alpha2NamedResourcesStringSlice', - 'version': 'str' - } - - attribute_map = { - 'bool': 'bool', - 'int': 'int', - 'int_slice': 'intSlice', - 'name': 'name', - 'quantity': 'quantity', - 'string': 'string', - 'string_slice': 'stringSlice', - 'version': 'version' - } - - def __init__(self, bool=None, int=None, int_slice=None, name=None, quantity=None, string=None, string_slice=None, version=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2NamedResourcesAttribute - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._bool = None - self._int = None - self._int_slice = None - self._name = None - self._quantity = None - self._string = None - self._string_slice = None - self._version = None - self.discriminator = None - - if bool is not None: - self.bool = bool - if int is not None: - self.int = int - if int_slice is not None: - self.int_slice = int_slice - self.name = name - if quantity is not None: - self.quantity = quantity - if string is not None: - self.string = string - if string_slice is not None: - self.string_slice = string_slice - if version is not None: - self.version = version - - @property - def bool(self): - """Gets the bool of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - BoolValue is a true/false value. # noqa: E501 - - :return: The bool of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: bool - """ - return self._bool - - @bool.setter - def bool(self, bool): - """Sets the bool of this V1alpha2NamedResourcesAttribute. - - BoolValue is a true/false value. # noqa: E501 - - :param bool: The bool of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: bool - """ - - self._bool = bool - - @property - def int(self): - """Gets the int of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - IntValue is a 64-bit integer. # noqa: E501 - - :return: The int of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: int - """ - return self._int - - @int.setter - def int(self, int): - """Sets the int of this V1alpha2NamedResourcesAttribute. - - IntValue is a 64-bit integer. # noqa: E501 - - :param int: The int of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: int - """ - - self._int = int - - @property - def int_slice(self): - """Gets the int_slice of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - - :return: The int_slice of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: V1alpha2NamedResourcesIntSlice - """ - return self._int_slice - - @int_slice.setter - def int_slice(self, int_slice): - """Sets the int_slice of this V1alpha2NamedResourcesAttribute. - - - :param int_slice: The int_slice of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: V1alpha2NamedResourcesIntSlice - """ - - self._int_slice = int_slice - - @property - def name(self): - """Gets the name of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - Name is unique identifier among all resource instances managed by the driver on the node. It must be a DNS subdomain. # noqa: E501 - - :return: The name of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this V1alpha2NamedResourcesAttribute. - - Name is unique identifier among all resource instances managed by the driver on the node. It must be a DNS subdomain. # noqa: E501 - - :param name: The name of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - @property - def quantity(self): - """Gets the quantity of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - QuantityValue is a quantity. # noqa: E501 - - :return: The quantity of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: str - """ - return self._quantity - - @quantity.setter - def quantity(self, quantity): - """Sets the quantity of this V1alpha2NamedResourcesAttribute. - - QuantityValue is a quantity. # noqa: E501 - - :param quantity: The quantity of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: str - """ - - self._quantity = quantity - - @property - def string(self): - """Gets the string of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - StringValue is a string. # noqa: E501 - - :return: The string of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: str - """ - return self._string - - @string.setter - def string(self, string): - """Sets the string of this V1alpha2NamedResourcesAttribute. - - StringValue is a string. # noqa: E501 - - :param string: The string of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: str - """ - - self._string = string - - @property - def string_slice(self): - """Gets the string_slice of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - - :return: The string_slice of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: V1alpha2NamedResourcesStringSlice - """ - return self._string_slice - - @string_slice.setter - def string_slice(self, string_slice): - """Sets the string_slice of this V1alpha2NamedResourcesAttribute. - - - :param string_slice: The string_slice of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: V1alpha2NamedResourcesStringSlice - """ - - self._string_slice = string_slice - - @property - def version(self): - """Gets the version of this V1alpha2NamedResourcesAttribute. # noqa: E501 - - VersionValue is a semantic version according to semver.org spec 2.0.0. # noqa: E501 - - :return: The version of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :rtype: str - """ - return self._version - - @version.setter - def version(self, version): - """Sets the version of this V1alpha2NamedResourcesAttribute. - - VersionValue is a semantic version according to semver.org spec 2.0.0. # noqa: E501 - - :param version: The version of this V1alpha2NamedResourcesAttribute. # noqa: E501 - :type: str - """ - - self._version = version - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2NamedResourcesAttribute): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2NamedResourcesAttribute): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_filter.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_filter.py deleted file mode 100644 index 8645d15efaed..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_filter.py +++ /dev/null @@ -1,123 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2NamedResourcesFilter(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'selector': 'str' - } - - attribute_map = { - 'selector': 'selector' - } - - def __init__(self, selector=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2NamedResourcesFilter - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._selector = None - self.discriminator = None - - self.selector = selector - - @property - def selector(self): - """Gets the selector of this V1alpha2NamedResourcesFilter. # noqa: E501 - - Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/ In addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example: attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) && attributes.stringslice[\"b\"].isSorted() # noqa: E501 - - :return: The selector of this V1alpha2NamedResourcesFilter. # noqa: E501 - :rtype: str - """ - return self._selector - - @selector.setter - def selector(self, selector): - """Sets the selector of this V1alpha2NamedResourcesFilter. - - Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/ In addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example: attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) && attributes.stringslice[\"b\"].isSorted() # noqa: E501 - - :param selector: The selector of this V1alpha2NamedResourcesFilter. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and selector is None: # noqa: E501 - raise ValueError("Invalid value for `selector`, must not be `None`") # noqa: E501 - - self._selector = selector - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2NamedResourcesFilter): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2NamedResourcesFilter): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_request.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_request.py deleted file mode 100644 index 5fae29a9fe8d..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_request.py +++ /dev/null @@ -1,123 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2NamedResourcesRequest(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'selector': 'str' - } - - attribute_map = { - 'selector': 'selector' - } - - def __init__(self, selector=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2NamedResourcesRequest - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._selector = None - self.discriminator = None - - self.selector = selector - - @property - def selector(self): - """Gets the selector of this V1alpha2NamedResourcesRequest. # noqa: E501 - - Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/ In addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example: attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) && attributes.stringslice[\"b\"].isSorted() # noqa: E501 - - :return: The selector of this V1alpha2NamedResourcesRequest. # noqa: E501 - :rtype: str - """ - return self._selector - - @selector.setter - def selector(self, selector): - """Sets the selector of this V1alpha2NamedResourcesRequest. - - Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/ In addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example: attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) && attributes.stringslice[\"b\"].isSorted() # noqa: E501 - - :param selector: The selector of this V1alpha2NamedResourcesRequest. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and selector is None: # noqa: E501 - raise ValueError("Invalid value for `selector`, must not be `None`") # noqa: E501 - - self._selector = selector - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2NamedResourcesRequest): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2NamedResourcesRequest): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_resources.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_resources.py deleted file mode 100644 index 2d2b7cdebb7c..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_resources.py +++ /dev/null @@ -1,123 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2NamedResourcesResources(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'instances': 'list[V1alpha2NamedResourcesInstance]' - } - - attribute_map = { - 'instances': 'instances' - } - - def __init__(self, instances=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2NamedResourcesResources - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._instances = None - self.discriminator = None - - self.instances = instances - - @property - def instances(self): - """Gets the instances of this V1alpha2NamedResourcesResources. # noqa: E501 - - The list of all individual resources instances currently available. # noqa: E501 - - :return: The instances of this V1alpha2NamedResourcesResources. # noqa: E501 - :rtype: list[V1alpha2NamedResourcesInstance] - """ - return self._instances - - @instances.setter - def instances(self, instances): - """Sets the instances of this V1alpha2NamedResourcesResources. - - The list of all individual resources instances currently available. # noqa: E501 - - :param instances: The instances of this V1alpha2NamedResourcesResources. # noqa: E501 - :type: list[V1alpha2NamedResourcesInstance] - """ - if self.local_vars_configuration.client_side_validation and instances is None: # noqa: E501 - raise ValueError("Invalid value for `instances`, must not be `None`") # noqa: E501 - - self._instances = instances - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2NamedResourcesResources): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2NamedResourcesResources): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_string_slice.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_string_slice.py deleted file mode 100644 index a2bb34fe37fa..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_named_resources_string_slice.py +++ /dev/null @@ -1,123 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2NamedResourcesStringSlice(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'strings': 'list[str]' - } - - attribute_map = { - 'strings': 'strings' - } - - def __init__(self, strings=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2NamedResourcesStringSlice - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._strings = None - self.discriminator = None - - self.strings = strings - - @property - def strings(self): - """Gets the strings of this V1alpha2NamedResourcesStringSlice. # noqa: E501 - - Strings is the slice of strings. # noqa: E501 - - :return: The strings of this V1alpha2NamedResourcesStringSlice. # noqa: E501 - :rtype: list[str] - """ - return self._strings - - @strings.setter - def strings(self, strings): - """Sets the strings of this V1alpha2NamedResourcesStringSlice. - - Strings is the slice of strings. # noqa: E501 - - :param strings: The strings of this V1alpha2NamedResourcesStringSlice. # noqa: E501 - :type: list[str] - """ - if self.local_vars_configuration.client_side_validation and strings is None: # noqa: E501 - raise ValueError("Invalid value for `strings`, must not be `None`") # noqa: E501 - - self._strings = strings - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2NamedResourcesStringSlice): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2NamedResourcesStringSlice): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context.py deleted file mode 100644 index 3a3110311d09..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context.py +++ /dev/null @@ -1,229 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2PodSchedulingContext(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'spec': 'V1alpha2PodSchedulingContextSpec', - 'status': 'V1alpha2PodSchedulingContextStatus' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'kind': 'kind', - 'metadata': 'metadata', - 'spec': 'spec', - 'status': 'status' - } - - def __init__(self, api_version=None, kind=None, metadata=None, spec=None, status=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2PodSchedulingContext - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._kind = None - self._metadata = None - self._spec = None - self._status = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - self.spec = spec - if status is not None: - self.status = status - - @property - def api_version(self): - """Gets the api_version of this V1alpha2PodSchedulingContext. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2PodSchedulingContext. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2PodSchedulingContext. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2PodSchedulingContext. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def kind(self): - """Gets the kind of this V1alpha2PodSchedulingContext. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2PodSchedulingContext. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2PodSchedulingContext. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2PodSchedulingContext. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2PodSchedulingContext. # noqa: E501 - - - :return: The metadata of this V1alpha2PodSchedulingContext. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2PodSchedulingContext. - - - :param metadata: The metadata of this V1alpha2PodSchedulingContext. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def spec(self): - """Gets the spec of this V1alpha2PodSchedulingContext. # noqa: E501 - - - :return: The spec of this V1alpha2PodSchedulingContext. # noqa: E501 - :rtype: V1alpha2PodSchedulingContextSpec - """ - return self._spec - - @spec.setter - def spec(self, spec): - """Sets the spec of this V1alpha2PodSchedulingContext. - - - :param spec: The spec of this V1alpha2PodSchedulingContext. # noqa: E501 - :type: V1alpha2PodSchedulingContextSpec - """ - if self.local_vars_configuration.client_side_validation and spec is None: # noqa: E501 - raise ValueError("Invalid value for `spec`, must not be `None`") # noqa: E501 - - self._spec = spec - - @property - def status(self): - """Gets the status of this V1alpha2PodSchedulingContext. # noqa: E501 - - - :return: The status of this V1alpha2PodSchedulingContext. # noqa: E501 - :rtype: V1alpha2PodSchedulingContextStatus - """ - return self._status - - @status.setter - def status(self, status): - """Sets the status of this V1alpha2PodSchedulingContext. - - - :param status: The status of this V1alpha2PodSchedulingContext. # noqa: E501 - :type: V1alpha2PodSchedulingContextStatus - """ - - self._status = status - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2PodSchedulingContext): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2PodSchedulingContext): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_list.py deleted file mode 100644 index 547fca7905ab..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_list.py +++ /dev/null @@ -1,205 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2PodSchedulingContextList(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'items': 'list[V1alpha2PodSchedulingContext]', - 'kind': 'str', - 'metadata': 'V1ListMeta' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'items': 'items', - 'kind': 'kind', - 'metadata': 'metadata' - } - - def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2PodSchedulingContextList - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._items = None - self._kind = None - self._metadata = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.items = items - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - - @property - def api_version(self): - """Gets the api_version of this V1alpha2PodSchedulingContextList. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2PodSchedulingContextList. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2PodSchedulingContextList. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2PodSchedulingContextList. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def items(self): - """Gets the items of this V1alpha2PodSchedulingContextList. # noqa: E501 - - Items is the list of PodSchedulingContext objects. # noqa: E501 - - :return: The items of this V1alpha2PodSchedulingContextList. # noqa: E501 - :rtype: list[V1alpha2PodSchedulingContext] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this V1alpha2PodSchedulingContextList. - - Items is the list of PodSchedulingContext objects. # noqa: E501 - - :param items: The items of this V1alpha2PodSchedulingContextList. # noqa: E501 - :type: list[V1alpha2PodSchedulingContext] - """ - if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 - raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 - - self._items = items - - @property - def kind(self): - """Gets the kind of this V1alpha2PodSchedulingContextList. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2PodSchedulingContextList. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2PodSchedulingContextList. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2PodSchedulingContextList. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2PodSchedulingContextList. # noqa: E501 - - - :return: The metadata of this V1alpha2PodSchedulingContextList. # noqa: E501 - :rtype: V1ListMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2PodSchedulingContextList. - - - :param metadata: The metadata of this V1alpha2PodSchedulingContextList. # noqa: E501 - :type: V1ListMeta - """ - - self._metadata = metadata - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2PodSchedulingContextList): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2PodSchedulingContextList): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_spec.py deleted file mode 100644 index eb0ffc75e0d7..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_spec.py +++ /dev/null @@ -1,150 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2PodSchedulingContextSpec(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'potential_nodes': 'list[str]', - 'selected_node': 'str' - } - - attribute_map = { - 'potential_nodes': 'potentialNodes', - 'selected_node': 'selectedNode' - } - - def __init__(self, potential_nodes=None, selected_node=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2PodSchedulingContextSpec - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._potential_nodes = None - self._selected_node = None - self.discriminator = None - - if potential_nodes is not None: - self.potential_nodes = potential_nodes - if selected_node is not None: - self.selected_node = selected_node - - @property - def potential_nodes(self): - """Gets the potential_nodes of this V1alpha2PodSchedulingContextSpec. # noqa: E501 - - PotentialNodes lists nodes where the Pod might be able to run. The size of this field is limited to 128. This is large enough for many clusters. Larger clusters may need more attempts to find a node that suits all pending resources. This may get increased in the future, but not reduced. # noqa: E501 - - :return: The potential_nodes of this V1alpha2PodSchedulingContextSpec. # noqa: E501 - :rtype: list[str] - """ - return self._potential_nodes - - @potential_nodes.setter - def potential_nodes(self, potential_nodes): - """Sets the potential_nodes of this V1alpha2PodSchedulingContextSpec. - - PotentialNodes lists nodes where the Pod might be able to run. The size of this field is limited to 128. This is large enough for many clusters. Larger clusters may need more attempts to find a node that suits all pending resources. This may get increased in the future, but not reduced. # noqa: E501 - - :param potential_nodes: The potential_nodes of this V1alpha2PodSchedulingContextSpec. # noqa: E501 - :type: list[str] - """ - - self._potential_nodes = potential_nodes - - @property - def selected_node(self): - """Gets the selected_node of this V1alpha2PodSchedulingContextSpec. # noqa: E501 - - SelectedNode is the node for which allocation of ResourceClaims that are referenced by the Pod and that use \"WaitForFirstConsumer\" allocation is to be attempted. # noqa: E501 - - :return: The selected_node of this V1alpha2PodSchedulingContextSpec. # noqa: E501 - :rtype: str - """ - return self._selected_node - - @selected_node.setter - def selected_node(self, selected_node): - """Sets the selected_node of this V1alpha2PodSchedulingContextSpec. - - SelectedNode is the node for which allocation of ResourceClaims that are referenced by the Pod and that use \"WaitForFirstConsumer\" allocation is to be attempted. # noqa: E501 - - :param selected_node: The selected_node of this V1alpha2PodSchedulingContextSpec. # noqa: E501 - :type: str - """ - - self._selected_node = selected_node - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2PodSchedulingContextSpec): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2PodSchedulingContextSpec): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_status.py deleted file mode 100644 index f1ba64820aa9..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_pod_scheduling_context_status.py +++ /dev/null @@ -1,122 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2PodSchedulingContextStatus(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'resource_claims': 'list[V1alpha2ResourceClaimSchedulingStatus]' - } - - attribute_map = { - 'resource_claims': 'resourceClaims' - } - - def __init__(self, resource_claims=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2PodSchedulingContextStatus - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._resource_claims = None - self.discriminator = None - - if resource_claims is not None: - self.resource_claims = resource_claims - - @property - def resource_claims(self): - """Gets the resource_claims of this V1alpha2PodSchedulingContextStatus. # noqa: E501 - - ResourceClaims describes resource availability for each pod.spec.resourceClaim entry where the corresponding ResourceClaim uses \"WaitForFirstConsumer\" allocation mode. # noqa: E501 - - :return: The resource_claims of this V1alpha2PodSchedulingContextStatus. # noqa: E501 - :rtype: list[V1alpha2ResourceClaimSchedulingStatus] - """ - return self._resource_claims - - @resource_claims.setter - def resource_claims(self, resource_claims): - """Sets the resource_claims of this V1alpha2PodSchedulingContextStatus. - - ResourceClaims describes resource availability for each pod.spec.resourceClaim entry where the corresponding ResourceClaim uses \"WaitForFirstConsumer\" allocation mode. # noqa: E501 - - :param resource_claims: The resource_claims of this V1alpha2PodSchedulingContextStatus. # noqa: E501 - :type: list[V1alpha2ResourceClaimSchedulingStatus] - """ - - self._resource_claims = resource_claims - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2PodSchedulingContextStatus): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2PodSchedulingContextStatus): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters.py deleted file mode 100644 index de334a4ece76..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClaimParameters(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'driver_requests': 'list[V1alpha2DriverRequests]', - 'generated_from': 'V1alpha2ResourceClaimParametersReference', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'shareable': 'bool' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'driver_requests': 'driverRequests', - 'generated_from': 'generatedFrom', - 'kind': 'kind', - 'metadata': 'metadata', - 'shareable': 'shareable' - } - - def __init__(self, api_version=None, driver_requests=None, generated_from=None, kind=None, metadata=None, shareable=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClaimParameters - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._driver_requests = None - self._generated_from = None - self._kind = None - self._metadata = None - self._shareable = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - if driver_requests is not None: - self.driver_requests = driver_requests - if generated_from is not None: - self.generated_from = generated_from - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if shareable is not None: - self.shareable = shareable - - @property - def api_version(self): - """Gets the api_version of this V1alpha2ResourceClaimParameters. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2ResourceClaimParameters. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceClaimParameters. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2ResourceClaimParameters. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def driver_requests(self): - """Gets the driver_requests of this V1alpha2ResourceClaimParameters. # noqa: E501 - - DriverRequests describes all resources that are needed for the allocated claim. A single claim may use resources coming from different drivers. For each driver, this array has at most one entry which then may have one or more per-driver requests. May be empty, in which case the claim can always be allocated. # noqa: E501 - - :return: The driver_requests of this V1alpha2ResourceClaimParameters. # noqa: E501 - :rtype: list[V1alpha2DriverRequests] - """ - return self._driver_requests - - @driver_requests.setter - def driver_requests(self, driver_requests): - """Sets the driver_requests of this V1alpha2ResourceClaimParameters. - - DriverRequests describes all resources that are needed for the allocated claim. A single claim may use resources coming from different drivers. For each driver, this array has at most one entry which then may have one or more per-driver requests. May be empty, in which case the claim can always be allocated. # noqa: E501 - - :param driver_requests: The driver_requests of this V1alpha2ResourceClaimParameters. # noqa: E501 - :type: list[V1alpha2DriverRequests] - """ - - self._driver_requests = driver_requests - - @property - def generated_from(self): - """Gets the generated_from of this V1alpha2ResourceClaimParameters. # noqa: E501 - - - :return: The generated_from of this V1alpha2ResourceClaimParameters. # noqa: E501 - :rtype: V1alpha2ResourceClaimParametersReference - """ - return self._generated_from - - @generated_from.setter - def generated_from(self, generated_from): - """Sets the generated_from of this V1alpha2ResourceClaimParameters. - - - :param generated_from: The generated_from of this V1alpha2ResourceClaimParameters. # noqa: E501 - :type: V1alpha2ResourceClaimParametersReference - """ - - self._generated_from = generated_from - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClaimParameters. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2ResourceClaimParameters. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClaimParameters. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClaimParameters. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2ResourceClaimParameters. # noqa: E501 - - - :return: The metadata of this V1alpha2ResourceClaimParameters. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceClaimParameters. - - - :param metadata: The metadata of this V1alpha2ResourceClaimParameters. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def shareable(self): - """Gets the shareable of this V1alpha2ResourceClaimParameters. # noqa: E501 - - Shareable indicates whether the allocated claim is meant to be shareable by multiple consumers at the same time. # noqa: E501 - - :return: The shareable of this V1alpha2ResourceClaimParameters. # noqa: E501 - :rtype: bool - """ - return self._shareable - - @shareable.setter - def shareable(self, shareable): - """Sets the shareable of this V1alpha2ResourceClaimParameters. - - Shareable indicates whether the allocated claim is meant to be shareable by multiple consumers at the same time. # noqa: E501 - - :param shareable: The shareable of this V1alpha2ResourceClaimParameters. # noqa: E501 - :type: bool - """ - - self._shareable = shareable - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClaimParameters): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClaimParameters): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters_list.py deleted file mode 100644 index 5321190dddb4..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters_list.py +++ /dev/null @@ -1,205 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClaimParametersList(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'items': 'list[V1alpha2ResourceClaimParameters]', - 'kind': 'str', - 'metadata': 'V1ListMeta' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'items': 'items', - 'kind': 'kind', - 'metadata': 'metadata' - } - - def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClaimParametersList - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._items = None - self._kind = None - self._metadata = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.items = items - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - - @property - def api_version(self): - """Gets the api_version of this V1alpha2ResourceClaimParametersList. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceClaimParametersList. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def items(self): - """Gets the items of this V1alpha2ResourceClaimParametersList. # noqa: E501 - - Items is the list of node resource capacity objects. # noqa: E501 - - :return: The items of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :rtype: list[V1alpha2ResourceClaimParameters] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this V1alpha2ResourceClaimParametersList. - - Items is the list of node resource capacity objects. # noqa: E501 - - :param items: The items of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :type: list[V1alpha2ResourceClaimParameters] - """ - if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 - raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 - - self._items = items - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClaimParametersList. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClaimParametersList. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2ResourceClaimParametersList. # noqa: E501 - - - :return: The metadata of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :rtype: V1ListMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceClaimParametersList. - - - :param metadata: The metadata of this V1alpha2ResourceClaimParametersList. # noqa: E501 - :type: V1ListMeta - """ - - self._metadata = metadata - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClaimParametersList): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClaimParametersList): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters_reference.py deleted file mode 100644 index 13bb6948b7ce..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_parameters_reference.py +++ /dev/null @@ -1,180 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClaimParametersReference(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_group': 'str', - 'kind': 'str', - 'name': 'str' - } - - attribute_map = { - 'api_group': 'apiGroup', - 'kind': 'kind', - 'name': 'name' - } - - def __init__(self, api_group=None, kind=None, name=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClaimParametersReference - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_group = None - self._kind = None - self._name = None - self.discriminator = None - - if api_group is not None: - self.api_group = api_group - self.kind = kind - self.name = name - - @property - def api_group(self): - """Gets the api_group of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - - APIGroup is the group for the resource being referenced. It is empty for the core API. This matches the group in the APIVersion that is used when creating the resources. # noqa: E501 - - :return: The api_group of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - :rtype: str - """ - return self._api_group - - @api_group.setter - def api_group(self, api_group): - """Sets the api_group of this V1alpha2ResourceClaimParametersReference. - - APIGroup is the group for the resource being referenced. It is empty for the core API. This matches the group in the APIVersion that is used when creating the resources. # noqa: E501 - - :param api_group: The api_group of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - :type: str - """ - - self._api_group = api_group - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - - Kind is the type of resource being referenced. This is the same value as in the parameter object's metadata, for example \"ConfigMap\". # noqa: E501 - - :return: The kind of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClaimParametersReference. - - Kind is the type of resource being referenced. This is the same value as in the parameter object's metadata, for example \"ConfigMap\". # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and kind is None: # noqa: E501 - raise ValueError("Invalid value for `kind`, must not be `None`") # noqa: E501 - - self._kind = kind - - @property - def name(self): - """Gets the name of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - - Name is the name of resource being referenced. # noqa: E501 - - :return: The name of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this V1alpha2ResourceClaimParametersReference. - - Name is the name of resource being referenced. # noqa: E501 - - :param name: The name of this V1alpha2ResourceClaimParametersReference. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClaimParametersReference): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClaimParametersReference): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_scheduling_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_scheduling_status.py deleted file mode 100644 index 52ab2d426b01..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_scheduling_status.py +++ /dev/null @@ -1,150 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClaimSchedulingStatus(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'name': 'str', - 'unsuitable_nodes': 'list[str]' - } - - attribute_map = { - 'name': 'name', - 'unsuitable_nodes': 'unsuitableNodes' - } - - def __init__(self, name=None, unsuitable_nodes=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClaimSchedulingStatus - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._name = None - self._unsuitable_nodes = None - self.discriminator = None - - if name is not None: - self.name = name - if unsuitable_nodes is not None: - self.unsuitable_nodes = unsuitable_nodes - - @property - def name(self): - """Gets the name of this V1alpha2ResourceClaimSchedulingStatus. # noqa: E501 - - Name matches the pod.spec.resourceClaims[*].Name field. # noqa: E501 - - :return: The name of this V1alpha2ResourceClaimSchedulingStatus. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this V1alpha2ResourceClaimSchedulingStatus. - - Name matches the pod.spec.resourceClaims[*].Name field. # noqa: E501 - - :param name: The name of this V1alpha2ResourceClaimSchedulingStatus. # noqa: E501 - :type: str - """ - - self._name = name - - @property - def unsuitable_nodes(self): - """Gets the unsuitable_nodes of this V1alpha2ResourceClaimSchedulingStatus. # noqa: E501 - - UnsuitableNodes lists nodes that the ResourceClaim cannot be allocated for. The size of this field is limited to 128, the same as for PodSchedulingSpec.PotentialNodes. This may get increased in the future, but not reduced. # noqa: E501 - - :return: The unsuitable_nodes of this V1alpha2ResourceClaimSchedulingStatus. # noqa: E501 - :rtype: list[str] - """ - return self._unsuitable_nodes - - @unsuitable_nodes.setter - def unsuitable_nodes(self, unsuitable_nodes): - """Sets the unsuitable_nodes of this V1alpha2ResourceClaimSchedulingStatus. - - UnsuitableNodes lists nodes that the ResourceClaim cannot be allocated for. The size of this field is limited to 128, the same as for PodSchedulingSpec.PotentialNodes. This may get increased in the future, but not reduced. # noqa: E501 - - :param unsuitable_nodes: The unsuitable_nodes of this V1alpha2ResourceClaimSchedulingStatus. # noqa: E501 - :type: list[str] - """ - - self._unsuitable_nodes = unsuitable_nodes - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClaimSchedulingStatus): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClaimSchedulingStatus): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_spec.py deleted file mode 100644 index 8bfb21045060..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_spec.py +++ /dev/null @@ -1,177 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClaimSpec(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'allocation_mode': 'str', - 'parameters_ref': 'V1alpha2ResourceClaimParametersReference', - 'resource_class_name': 'str' - } - - attribute_map = { - 'allocation_mode': 'allocationMode', - 'parameters_ref': 'parametersRef', - 'resource_class_name': 'resourceClassName' - } - - def __init__(self, allocation_mode=None, parameters_ref=None, resource_class_name=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClaimSpec - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._allocation_mode = None - self._parameters_ref = None - self._resource_class_name = None - self.discriminator = None - - if allocation_mode is not None: - self.allocation_mode = allocation_mode - if parameters_ref is not None: - self.parameters_ref = parameters_ref - self.resource_class_name = resource_class_name - - @property - def allocation_mode(self): - """Gets the allocation_mode of this V1alpha2ResourceClaimSpec. # noqa: E501 - - Allocation can start immediately or when a Pod wants to use the resource. \"WaitForFirstConsumer\" is the default. # noqa: E501 - - :return: The allocation_mode of this V1alpha2ResourceClaimSpec. # noqa: E501 - :rtype: str - """ - return self._allocation_mode - - @allocation_mode.setter - def allocation_mode(self, allocation_mode): - """Sets the allocation_mode of this V1alpha2ResourceClaimSpec. - - Allocation can start immediately or when a Pod wants to use the resource. \"WaitForFirstConsumer\" is the default. # noqa: E501 - - :param allocation_mode: The allocation_mode of this V1alpha2ResourceClaimSpec. # noqa: E501 - :type: str - """ - - self._allocation_mode = allocation_mode - - @property - def parameters_ref(self): - """Gets the parameters_ref of this V1alpha2ResourceClaimSpec. # noqa: E501 - - - :return: The parameters_ref of this V1alpha2ResourceClaimSpec. # noqa: E501 - :rtype: V1alpha2ResourceClaimParametersReference - """ - return self._parameters_ref - - @parameters_ref.setter - def parameters_ref(self, parameters_ref): - """Sets the parameters_ref of this V1alpha2ResourceClaimSpec. - - - :param parameters_ref: The parameters_ref of this V1alpha2ResourceClaimSpec. # noqa: E501 - :type: V1alpha2ResourceClaimParametersReference - """ - - self._parameters_ref = parameters_ref - - @property - def resource_class_name(self): - """Gets the resource_class_name of this V1alpha2ResourceClaimSpec. # noqa: E501 - - ResourceClassName references the driver and additional parameters via the name of a ResourceClass that was created as part of the driver deployment. # noqa: E501 - - :return: The resource_class_name of this V1alpha2ResourceClaimSpec. # noqa: E501 - :rtype: str - """ - return self._resource_class_name - - @resource_class_name.setter - def resource_class_name(self, resource_class_name): - """Sets the resource_class_name of this V1alpha2ResourceClaimSpec. - - ResourceClassName references the driver and additional parameters via the name of a ResourceClass that was created as part of the driver deployment. # noqa: E501 - - :param resource_class_name: The resource_class_name of this V1alpha2ResourceClaimSpec. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and resource_class_name is None: # noqa: E501 - raise ValueError("Invalid value for `resource_class_name`, must not be `None`") # noqa: E501 - - self._resource_class_name = resource_class_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClaimSpec): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClaimSpec): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_status.py deleted file mode 100644 index 624405c61c61..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_claim_status.py +++ /dev/null @@ -1,204 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClaimStatus(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'allocation': 'V1alpha2AllocationResult', - 'deallocation_requested': 'bool', - 'driver_name': 'str', - 'reserved_for': 'list[V1alpha2ResourceClaimConsumerReference]' - } - - attribute_map = { - 'allocation': 'allocation', - 'deallocation_requested': 'deallocationRequested', - 'driver_name': 'driverName', - 'reserved_for': 'reservedFor' - } - - def __init__(self, allocation=None, deallocation_requested=None, driver_name=None, reserved_for=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClaimStatus - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._allocation = None - self._deallocation_requested = None - self._driver_name = None - self._reserved_for = None - self.discriminator = None - - if allocation is not None: - self.allocation = allocation - if deallocation_requested is not None: - self.deallocation_requested = deallocation_requested - if driver_name is not None: - self.driver_name = driver_name - if reserved_for is not None: - self.reserved_for = reserved_for - - @property - def allocation(self): - """Gets the allocation of this V1alpha2ResourceClaimStatus. # noqa: E501 - - - :return: The allocation of this V1alpha2ResourceClaimStatus. # noqa: E501 - :rtype: V1alpha2AllocationResult - """ - return self._allocation - - @allocation.setter - def allocation(self, allocation): - """Sets the allocation of this V1alpha2ResourceClaimStatus. - - - :param allocation: The allocation of this V1alpha2ResourceClaimStatus. # noqa: E501 - :type: V1alpha2AllocationResult - """ - - self._allocation = allocation - - @property - def deallocation_requested(self): - """Gets the deallocation_requested of this V1alpha2ResourceClaimStatus. # noqa: E501 - - DeallocationRequested indicates that a ResourceClaim is to be deallocated. The driver then must deallocate this claim and reset the field together with clearing the Allocation field. While DeallocationRequested is set, no new consumers may be added to ReservedFor. # noqa: E501 - - :return: The deallocation_requested of this V1alpha2ResourceClaimStatus. # noqa: E501 - :rtype: bool - """ - return self._deallocation_requested - - @deallocation_requested.setter - def deallocation_requested(self, deallocation_requested): - """Sets the deallocation_requested of this V1alpha2ResourceClaimStatus. - - DeallocationRequested indicates that a ResourceClaim is to be deallocated. The driver then must deallocate this claim and reset the field together with clearing the Allocation field. While DeallocationRequested is set, no new consumers may be added to ReservedFor. # noqa: E501 - - :param deallocation_requested: The deallocation_requested of this V1alpha2ResourceClaimStatus. # noqa: E501 - :type: bool - """ - - self._deallocation_requested = deallocation_requested - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2ResourceClaimStatus. # noqa: E501 - - DriverName is a copy of the driver name from the ResourceClass at the time when allocation started. # noqa: E501 - - :return: The driver_name of this V1alpha2ResourceClaimStatus. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2ResourceClaimStatus. - - DriverName is a copy of the driver name from the ResourceClass at the time when allocation started. # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2ResourceClaimStatus. # noqa: E501 - :type: str - """ - - self._driver_name = driver_name - - @property - def reserved_for(self): - """Gets the reserved_for of this V1alpha2ResourceClaimStatus. # noqa: E501 - - ReservedFor indicates which entities are currently allowed to use the claim. A Pod which references a ResourceClaim which is not reserved for that Pod will not be started. There can be at most 32 such reservations. This may get increased in the future, but not reduced. # noqa: E501 - - :return: The reserved_for of this V1alpha2ResourceClaimStatus. # noqa: E501 - :rtype: list[V1alpha2ResourceClaimConsumerReference] - """ - return self._reserved_for - - @reserved_for.setter - def reserved_for(self, reserved_for): - """Sets the reserved_for of this V1alpha2ResourceClaimStatus. - - ReservedFor indicates which entities are currently allowed to use the claim. A Pod which references a ResourceClaim which is not reserved for that Pod will not be started. There can be at most 32 such reservations. This may get increased in the future, but not reduced. # noqa: E501 - - :param reserved_for: The reserved_for of this V1alpha2ResourceClaimStatus. # noqa: E501 - :type: list[V1alpha2ResourceClaimConsumerReference] - """ - - self._reserved_for = reserved_for - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClaimStatus): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClaimStatus): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class.py deleted file mode 100644 index 0f9d3e0534cd..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class.py +++ /dev/null @@ -1,285 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClass(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'driver_name': 'str', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'parameters_ref': 'V1alpha2ResourceClassParametersReference', - 'structured_parameters': 'bool', - 'suitable_nodes': 'V1NodeSelector' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'driver_name': 'driverName', - 'kind': 'kind', - 'metadata': 'metadata', - 'parameters_ref': 'parametersRef', - 'structured_parameters': 'structuredParameters', - 'suitable_nodes': 'suitableNodes' - } - - def __init__(self, api_version=None, driver_name=None, kind=None, metadata=None, parameters_ref=None, structured_parameters=None, suitable_nodes=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClass - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._driver_name = None - self._kind = None - self._metadata = None - self._parameters_ref = None - self._structured_parameters = None - self._suitable_nodes = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.driver_name = driver_name - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if parameters_ref is not None: - self.parameters_ref = parameters_ref - if structured_parameters is not None: - self.structured_parameters = structured_parameters - if suitable_nodes is not None: - self.suitable_nodes = suitable_nodes - - @property - def api_version(self): - """Gets the api_version of this V1alpha2ResourceClass. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2ResourceClass. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceClass. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2ResourceClass. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2ResourceClass. # noqa: E501 - - DriverName defines the name of the dynamic resource driver that is used for allocation of a ResourceClaim that uses this class. Resource drivers have a unique name in forward domain order (acme.example.com). # noqa: E501 - - :return: The driver_name of this V1alpha2ResourceClass. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2ResourceClass. - - DriverName defines the name of the dynamic resource driver that is used for allocation of a ResourceClaim that uses this class. Resource drivers have a unique name in forward domain order (acme.example.com). # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2ResourceClass. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and driver_name is None: # noqa: E501 - raise ValueError("Invalid value for `driver_name`, must not be `None`") # noqa: E501 - - self._driver_name = driver_name - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClass. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2ResourceClass. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClass. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClass. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2ResourceClass. # noqa: E501 - - - :return: The metadata of this V1alpha2ResourceClass. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceClass. - - - :param metadata: The metadata of this V1alpha2ResourceClass. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def parameters_ref(self): - """Gets the parameters_ref of this V1alpha2ResourceClass. # noqa: E501 - - - :return: The parameters_ref of this V1alpha2ResourceClass. # noqa: E501 - :rtype: V1alpha2ResourceClassParametersReference - """ - return self._parameters_ref - - @parameters_ref.setter - def parameters_ref(self, parameters_ref): - """Sets the parameters_ref of this V1alpha2ResourceClass. - - - :param parameters_ref: The parameters_ref of this V1alpha2ResourceClass. # noqa: E501 - :type: V1alpha2ResourceClassParametersReference - """ - - self._parameters_ref = parameters_ref - - @property - def structured_parameters(self): - """Gets the structured_parameters of this V1alpha2ResourceClass. # noqa: E501 - - If and only if allocation of claims using this class is handled via structured parameters, then StructuredParameters must be set to true. # noqa: E501 - - :return: The structured_parameters of this V1alpha2ResourceClass. # noqa: E501 - :rtype: bool - """ - return self._structured_parameters - - @structured_parameters.setter - def structured_parameters(self, structured_parameters): - """Sets the structured_parameters of this V1alpha2ResourceClass. - - If and only if allocation of claims using this class is handled via structured parameters, then StructuredParameters must be set to true. # noqa: E501 - - :param structured_parameters: The structured_parameters of this V1alpha2ResourceClass. # noqa: E501 - :type: bool - """ - - self._structured_parameters = structured_parameters - - @property - def suitable_nodes(self): - """Gets the suitable_nodes of this V1alpha2ResourceClass. # noqa: E501 - - - :return: The suitable_nodes of this V1alpha2ResourceClass. # noqa: E501 - :rtype: V1NodeSelector - """ - return self._suitable_nodes - - @suitable_nodes.setter - def suitable_nodes(self, suitable_nodes): - """Sets the suitable_nodes of this V1alpha2ResourceClass. - - - :param suitable_nodes: The suitable_nodes of this V1alpha2ResourceClass. # noqa: E501 - :type: V1NodeSelector - """ - - self._suitable_nodes = suitable_nodes - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClass): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClass): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters.py deleted file mode 100644 index 3b3843f506e5..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters.py +++ /dev/null @@ -1,258 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClassParameters(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'filters': 'list[V1alpha2ResourceFilter]', - 'generated_from': 'V1alpha2ResourceClassParametersReference', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'vendor_parameters': 'list[V1alpha2VendorParameters]' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'filters': 'filters', - 'generated_from': 'generatedFrom', - 'kind': 'kind', - 'metadata': 'metadata', - 'vendor_parameters': 'vendorParameters' - } - - def __init__(self, api_version=None, filters=None, generated_from=None, kind=None, metadata=None, vendor_parameters=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClassParameters - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._filters = None - self._generated_from = None - self._kind = None - self._metadata = None - self._vendor_parameters = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - if filters is not None: - self.filters = filters - if generated_from is not None: - self.generated_from = generated_from - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if vendor_parameters is not None: - self.vendor_parameters = vendor_parameters - - @property - def api_version(self): - """Gets the api_version of this V1alpha2ResourceClassParameters. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2ResourceClassParameters. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceClassParameters. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2ResourceClassParameters. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def filters(self): - """Gets the filters of this V1alpha2ResourceClassParameters. # noqa: E501 - - Filters describes additional contraints that must be met when using the class. # noqa: E501 - - :return: The filters of this V1alpha2ResourceClassParameters. # noqa: E501 - :rtype: list[V1alpha2ResourceFilter] - """ - return self._filters - - @filters.setter - def filters(self, filters): - """Sets the filters of this V1alpha2ResourceClassParameters. - - Filters describes additional contraints that must be met when using the class. # noqa: E501 - - :param filters: The filters of this V1alpha2ResourceClassParameters. # noqa: E501 - :type: list[V1alpha2ResourceFilter] - """ - - self._filters = filters - - @property - def generated_from(self): - """Gets the generated_from of this V1alpha2ResourceClassParameters. # noqa: E501 - - - :return: The generated_from of this V1alpha2ResourceClassParameters. # noqa: E501 - :rtype: V1alpha2ResourceClassParametersReference - """ - return self._generated_from - - @generated_from.setter - def generated_from(self, generated_from): - """Sets the generated_from of this V1alpha2ResourceClassParameters. - - - :param generated_from: The generated_from of this V1alpha2ResourceClassParameters. # noqa: E501 - :type: V1alpha2ResourceClassParametersReference - """ - - self._generated_from = generated_from - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClassParameters. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2ResourceClassParameters. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClassParameters. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClassParameters. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2ResourceClassParameters. # noqa: E501 - - - :return: The metadata of this V1alpha2ResourceClassParameters. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceClassParameters. - - - :param metadata: The metadata of this V1alpha2ResourceClassParameters. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def vendor_parameters(self): - """Gets the vendor_parameters of this V1alpha2ResourceClassParameters. # noqa: E501 - - VendorParameters are arbitrary setup parameters for all claims using this class. They are ignored while allocating the claim. There must not be more than one entry per driver. # noqa: E501 - - :return: The vendor_parameters of this V1alpha2ResourceClassParameters. # noqa: E501 - :rtype: list[V1alpha2VendorParameters] - """ - return self._vendor_parameters - - @vendor_parameters.setter - def vendor_parameters(self, vendor_parameters): - """Sets the vendor_parameters of this V1alpha2ResourceClassParameters. - - VendorParameters are arbitrary setup parameters for all claims using this class. They are ignored while allocating the claim. There must not be more than one entry per driver. # noqa: E501 - - :param vendor_parameters: The vendor_parameters of this V1alpha2ResourceClassParameters. # noqa: E501 - :type: list[V1alpha2VendorParameters] - """ - - self._vendor_parameters = vendor_parameters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClassParameters): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClassParameters): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters_list.py deleted file mode 100644 index 4030c51e78c0..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters_list.py +++ /dev/null @@ -1,205 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClassParametersList(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'items': 'list[V1alpha2ResourceClassParameters]', - 'kind': 'str', - 'metadata': 'V1ListMeta' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'items': 'items', - 'kind': 'kind', - 'metadata': 'metadata' - } - - def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClassParametersList - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._items = None - self._kind = None - self._metadata = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.items = items - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - - @property - def api_version(self): - """Gets the api_version of this V1alpha2ResourceClassParametersList. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2ResourceClassParametersList. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceClassParametersList. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2ResourceClassParametersList. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def items(self): - """Gets the items of this V1alpha2ResourceClassParametersList. # noqa: E501 - - Items is the list of node resource capacity objects. # noqa: E501 - - :return: The items of this V1alpha2ResourceClassParametersList. # noqa: E501 - :rtype: list[V1alpha2ResourceClassParameters] - """ - return self._items - - @items.setter - def items(self, items): - """Sets the items of this V1alpha2ResourceClassParametersList. - - Items is the list of node resource capacity objects. # noqa: E501 - - :param items: The items of this V1alpha2ResourceClassParametersList. # noqa: E501 - :type: list[V1alpha2ResourceClassParameters] - """ - if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 - raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 - - self._items = items - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClassParametersList. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2ResourceClassParametersList. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClassParametersList. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClassParametersList. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2ResourceClassParametersList. # noqa: E501 - - - :return: The metadata of this V1alpha2ResourceClassParametersList. # noqa: E501 - :rtype: V1ListMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceClassParametersList. - - - :param metadata: The metadata of this V1alpha2ResourceClassParametersList. # noqa: E501 - :type: V1ListMeta - """ - - self._metadata = metadata - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClassParametersList): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClassParametersList): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters_reference.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters_reference.py deleted file mode 100644 index c5d193c2486c..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_class_parameters_reference.py +++ /dev/null @@ -1,208 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceClassParametersReference(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_group': 'str', - 'kind': 'str', - 'name': 'str', - 'namespace': 'str' - } - - attribute_map = { - 'api_group': 'apiGroup', - 'kind': 'kind', - 'name': 'name', - 'namespace': 'namespace' - } - - def __init__(self, api_group=None, kind=None, name=None, namespace=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceClassParametersReference - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_group = None - self._kind = None - self._name = None - self._namespace = None - self.discriminator = None - - if api_group is not None: - self.api_group = api_group - self.kind = kind - self.name = name - if namespace is not None: - self.namespace = namespace - - @property - def api_group(self): - """Gets the api_group of this V1alpha2ResourceClassParametersReference. # noqa: E501 - - APIGroup is the group for the resource being referenced. It is empty for the core API. This matches the group in the APIVersion that is used when creating the resources. # noqa: E501 - - :return: The api_group of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :rtype: str - """ - return self._api_group - - @api_group.setter - def api_group(self, api_group): - """Sets the api_group of this V1alpha2ResourceClassParametersReference. - - APIGroup is the group for the resource being referenced. It is empty for the core API. This matches the group in the APIVersion that is used when creating the resources. # noqa: E501 - - :param api_group: The api_group of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :type: str - """ - - self._api_group = api_group - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceClassParametersReference. # noqa: E501 - - Kind is the type of resource being referenced. This is the same value as in the parameter object's metadata. # noqa: E501 - - :return: The kind of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceClassParametersReference. - - Kind is the type of resource being referenced. This is the same value as in the parameter object's metadata. # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and kind is None: # noqa: E501 - raise ValueError("Invalid value for `kind`, must not be `None`") # noqa: E501 - - self._kind = kind - - @property - def name(self): - """Gets the name of this V1alpha2ResourceClassParametersReference. # noqa: E501 - - Name is the name of resource being referenced. # noqa: E501 - - :return: The name of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :rtype: str - """ - return self._name - - @name.setter - def name(self, name): - """Sets the name of this V1alpha2ResourceClassParametersReference. - - Name is the name of resource being referenced. # noqa: E501 - - :param name: The name of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - - self._name = name - - @property - def namespace(self): - """Gets the namespace of this V1alpha2ResourceClassParametersReference. # noqa: E501 - - Namespace that contains the referenced resource. Must be empty for cluster-scoped resources and non-empty for namespaced resources. # noqa: E501 - - :return: The namespace of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :rtype: str - """ - return self._namespace - - @namespace.setter - def namespace(self, namespace): - """Sets the namespace of this V1alpha2ResourceClassParametersReference. - - Namespace that contains the referenced resource. Must be empty for cluster-scoped resources and non-empty for namespaced resources. # noqa: E501 - - :param namespace: The namespace of this V1alpha2ResourceClassParametersReference. # noqa: E501 - :type: str - """ - - self._namespace = namespace - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceClassParametersReference): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceClassParametersReference): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_filter.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_filter.py deleted file mode 100644 index fae4ca545fd3..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_filter.py +++ /dev/null @@ -1,148 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceFilter(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'driver_name': 'str', - 'named_resources': 'V1alpha2NamedResourcesFilter' - } - - attribute_map = { - 'driver_name': 'driverName', - 'named_resources': 'namedResources' - } - - def __init__(self, driver_name=None, named_resources=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceFilter - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._driver_name = None - self._named_resources = None - self.discriminator = None - - if driver_name is not None: - self.driver_name = driver_name - if named_resources is not None: - self.named_resources = named_resources - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2ResourceFilter. # noqa: E501 - - DriverName is the name used by the DRA driver kubelet plugin. # noqa: E501 - - :return: The driver_name of this V1alpha2ResourceFilter. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2ResourceFilter. - - DriverName is the name used by the DRA driver kubelet plugin. # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2ResourceFilter. # noqa: E501 - :type: str - """ - - self._driver_name = driver_name - - @property - def named_resources(self): - """Gets the named_resources of this V1alpha2ResourceFilter. # noqa: E501 - - - :return: The named_resources of this V1alpha2ResourceFilter. # noqa: E501 - :rtype: V1alpha2NamedResourcesFilter - """ - return self._named_resources - - @named_resources.setter - def named_resources(self, named_resources): - """Sets the named_resources of this V1alpha2ResourceFilter. - - - :param named_resources: The named_resources of this V1alpha2ResourceFilter. # noqa: E501 - :type: V1alpha2NamedResourcesFilter - """ - - self._named_resources = named_resources - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceFilter): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceFilter): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_handle.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_handle.py deleted file mode 100644 index bbb343c40cf0..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_handle.py +++ /dev/null @@ -1,176 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceHandle(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'data': 'str', - 'driver_name': 'str', - 'structured_data': 'V1alpha2StructuredResourceHandle' - } - - attribute_map = { - 'data': 'data', - 'driver_name': 'driverName', - 'structured_data': 'structuredData' - } - - def __init__(self, data=None, driver_name=None, structured_data=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceHandle - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._data = None - self._driver_name = None - self._structured_data = None - self.discriminator = None - - if data is not None: - self.data = data - if driver_name is not None: - self.driver_name = driver_name - if structured_data is not None: - self.structured_data = structured_data - - @property - def data(self): - """Gets the data of this V1alpha2ResourceHandle. # noqa: E501 - - Data contains the opaque data associated with this ResourceHandle. It is set by the controller component of the resource driver whose name matches the DriverName set in the ResourceClaimStatus this ResourceHandle is embedded in. It is set at allocation time and is intended for processing by the kubelet plugin whose name matches the DriverName set in this ResourceHandle. The maximum size of this field is 16KiB. This may get increased in the future, but not reduced. # noqa: E501 - - :return: The data of this V1alpha2ResourceHandle. # noqa: E501 - :rtype: str - """ - return self._data - - @data.setter - def data(self, data): - """Sets the data of this V1alpha2ResourceHandle. - - Data contains the opaque data associated with this ResourceHandle. It is set by the controller component of the resource driver whose name matches the DriverName set in the ResourceClaimStatus this ResourceHandle is embedded in. It is set at allocation time and is intended for processing by the kubelet plugin whose name matches the DriverName set in this ResourceHandle. The maximum size of this field is 16KiB. This may get increased in the future, but not reduced. # noqa: E501 - - :param data: The data of this V1alpha2ResourceHandle. # noqa: E501 - :type: str - """ - - self._data = data - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2ResourceHandle. # noqa: E501 - - DriverName specifies the name of the resource driver whose kubelet plugin should be invoked to process this ResourceHandle's data once it lands on a node. This may differ from the DriverName set in ResourceClaimStatus this ResourceHandle is embedded in. # noqa: E501 - - :return: The driver_name of this V1alpha2ResourceHandle. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2ResourceHandle. - - DriverName specifies the name of the resource driver whose kubelet plugin should be invoked to process this ResourceHandle's data once it lands on a node. This may differ from the DriverName set in ResourceClaimStatus this ResourceHandle is embedded in. # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2ResourceHandle. # noqa: E501 - :type: str - """ - - self._driver_name = driver_name - - @property - def structured_data(self): - """Gets the structured_data of this V1alpha2ResourceHandle. # noqa: E501 - - - :return: The structured_data of this V1alpha2ResourceHandle. # noqa: E501 - :rtype: V1alpha2StructuredResourceHandle - """ - return self._structured_data - - @structured_data.setter - def structured_data(self, structured_data): - """Sets the structured_data of this V1alpha2ResourceHandle. - - - :param structured_data: The structured_data of this V1alpha2ResourceHandle. # noqa: E501 - :type: V1alpha2StructuredResourceHandle - """ - - self._structured_data = structured_data - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceHandle): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceHandle): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_request.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_request.py deleted file mode 100644 index d701fa1145bb..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_request.py +++ /dev/null @@ -1,148 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceRequest(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'named_resources': 'V1alpha2NamedResourcesRequest', - 'vendor_parameters': 'object' - } - - attribute_map = { - 'named_resources': 'namedResources', - 'vendor_parameters': 'vendorParameters' - } - - def __init__(self, named_resources=None, vendor_parameters=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceRequest - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._named_resources = None - self._vendor_parameters = None - self.discriminator = None - - if named_resources is not None: - self.named_resources = named_resources - if vendor_parameters is not None: - self.vendor_parameters = vendor_parameters - - @property - def named_resources(self): - """Gets the named_resources of this V1alpha2ResourceRequest. # noqa: E501 - - - :return: The named_resources of this V1alpha2ResourceRequest. # noqa: E501 - :rtype: V1alpha2NamedResourcesRequest - """ - return self._named_resources - - @named_resources.setter - def named_resources(self, named_resources): - """Sets the named_resources of this V1alpha2ResourceRequest. - - - :param named_resources: The named_resources of this V1alpha2ResourceRequest. # noqa: E501 - :type: V1alpha2NamedResourcesRequest - """ - - self._named_resources = named_resources - - @property - def vendor_parameters(self): - """Gets the vendor_parameters of this V1alpha2ResourceRequest. # noqa: E501 - - VendorParameters are arbitrary setup parameters for the requested resource. They are ignored while allocating a claim. # noqa: E501 - - :return: The vendor_parameters of this V1alpha2ResourceRequest. # noqa: E501 - :rtype: object - """ - return self._vendor_parameters - - @vendor_parameters.setter - def vendor_parameters(self, vendor_parameters): - """Sets the vendor_parameters of this V1alpha2ResourceRequest. - - VendorParameters are arbitrary setup parameters for the requested resource. They are ignored while allocating a claim. # noqa: E501 - - :param vendor_parameters: The vendor_parameters of this V1alpha2ResourceRequest. # noqa: E501 - :type: object - """ - - self._vendor_parameters = vendor_parameters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceRequest): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceRequest): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_slice.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_slice.py deleted file mode 100644 index ba8a23999fb4..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_slice.py +++ /dev/null @@ -1,259 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2ResourceSlice(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'api_version': 'str', - 'driver_name': 'str', - 'kind': 'str', - 'metadata': 'V1ObjectMeta', - 'named_resources': 'V1alpha2NamedResourcesResources', - 'node_name': 'str' - } - - attribute_map = { - 'api_version': 'apiVersion', - 'driver_name': 'driverName', - 'kind': 'kind', - 'metadata': 'metadata', - 'named_resources': 'namedResources', - 'node_name': 'nodeName' - } - - def __init__(self, api_version=None, driver_name=None, kind=None, metadata=None, named_resources=None, node_name=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceSlice - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._api_version = None - self._driver_name = None - self._kind = None - self._metadata = None - self._named_resources = None - self._node_name = None - self.discriminator = None - - if api_version is not None: - self.api_version = api_version - self.driver_name = driver_name - if kind is not None: - self.kind = kind - if metadata is not None: - self.metadata = metadata - if named_resources is not None: - self.named_resources = named_resources - if node_name is not None: - self.node_name = node_name - - @property - def api_version(self): - """Gets the api_version of this V1alpha2ResourceSlice. # noqa: E501 - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :return: The api_version of this V1alpha2ResourceSlice. # noqa: E501 - :rtype: str - """ - return self._api_version - - @api_version.setter - def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceSlice. - - APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - - :param api_version: The api_version of this V1alpha2ResourceSlice. # noqa: E501 - :type: str - """ - - self._api_version = api_version - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2ResourceSlice. # noqa: E501 - - DriverName identifies the DRA driver providing the capacity information. A field selector can be used to list only ResourceSlice objects with a certain driver name. # noqa: E501 - - :return: The driver_name of this V1alpha2ResourceSlice. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2ResourceSlice. - - DriverName identifies the DRA driver providing the capacity information. A field selector can be used to list only ResourceSlice objects with a certain driver name. # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2ResourceSlice. # noqa: E501 - :type: str - """ - if self.local_vars_configuration.client_side_validation and driver_name is None: # noqa: E501 - raise ValueError("Invalid value for `driver_name`, must not be `None`") # noqa: E501 - - self._driver_name = driver_name - - @property - def kind(self): - """Gets the kind of this V1alpha2ResourceSlice. # noqa: E501 - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :return: The kind of this V1alpha2ResourceSlice. # noqa: E501 - :rtype: str - """ - return self._kind - - @kind.setter - def kind(self, kind): - """Sets the kind of this V1alpha2ResourceSlice. - - Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - - :param kind: The kind of this V1alpha2ResourceSlice. # noqa: E501 - :type: str - """ - - self._kind = kind - - @property - def metadata(self): - """Gets the metadata of this V1alpha2ResourceSlice. # noqa: E501 - - - :return: The metadata of this V1alpha2ResourceSlice. # noqa: E501 - :rtype: V1ObjectMeta - """ - return self._metadata - - @metadata.setter - def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceSlice. - - - :param metadata: The metadata of this V1alpha2ResourceSlice. # noqa: E501 - :type: V1ObjectMeta - """ - - self._metadata = metadata - - @property - def named_resources(self): - """Gets the named_resources of this V1alpha2ResourceSlice. # noqa: E501 - - - :return: The named_resources of this V1alpha2ResourceSlice. # noqa: E501 - :rtype: V1alpha2NamedResourcesResources - """ - return self._named_resources - - @named_resources.setter - def named_resources(self, named_resources): - """Sets the named_resources of this V1alpha2ResourceSlice. - - - :param named_resources: The named_resources of this V1alpha2ResourceSlice. # noqa: E501 - :type: V1alpha2NamedResourcesResources - """ - - self._named_resources = named_resources - - @property - def node_name(self): - """Gets the node_name of this V1alpha2ResourceSlice. # noqa: E501 - - NodeName identifies the node which provides the resources if they are local to a node. A field selector can be used to list only ResourceSlice objects with a certain node name. # noqa: E501 - - :return: The node_name of this V1alpha2ResourceSlice. # noqa: E501 - :rtype: str - """ - return self._node_name - - @node_name.setter - def node_name(self, node_name): - """Sets the node_name of this V1alpha2ResourceSlice. - - NodeName identifies the node which provides the resources if they are local to a node. A field selector can be used to list only ResourceSlice objects with a certain node name. # noqa: E501 - - :param node_name: The node_name of this V1alpha2ResourceSlice. # noqa: E501 - :type: str - """ - - self._node_name = node_name - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceSlice): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceSlice): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_structured_resource_handle.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_structured_resource_handle.py deleted file mode 100644 index ffaa506c4a0a..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_structured_resource_handle.py +++ /dev/null @@ -1,207 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2StructuredResourceHandle(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'node_name': 'str', - 'results': 'list[V1alpha2DriverAllocationResult]', - 'vendor_claim_parameters': 'object', - 'vendor_class_parameters': 'object' - } - - attribute_map = { - 'node_name': 'nodeName', - 'results': 'results', - 'vendor_claim_parameters': 'vendorClaimParameters', - 'vendor_class_parameters': 'vendorClassParameters' - } - - def __init__(self, node_name=None, results=None, vendor_claim_parameters=None, vendor_class_parameters=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2StructuredResourceHandle - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._node_name = None - self._results = None - self._vendor_claim_parameters = None - self._vendor_class_parameters = None - self.discriminator = None - - if node_name is not None: - self.node_name = node_name - self.results = results - if vendor_claim_parameters is not None: - self.vendor_claim_parameters = vendor_claim_parameters - if vendor_class_parameters is not None: - self.vendor_class_parameters = vendor_class_parameters - - @property - def node_name(self): - """Gets the node_name of this V1alpha2StructuredResourceHandle. # noqa: E501 - - NodeName is the name of the node providing the necessary resources if the resources are local to a node. # noqa: E501 - - :return: The node_name of this V1alpha2StructuredResourceHandle. # noqa: E501 - :rtype: str - """ - return self._node_name - - @node_name.setter - def node_name(self, node_name): - """Sets the node_name of this V1alpha2StructuredResourceHandle. - - NodeName is the name of the node providing the necessary resources if the resources are local to a node. # noqa: E501 - - :param node_name: The node_name of this V1alpha2StructuredResourceHandle. # noqa: E501 - :type: str - """ - - self._node_name = node_name - - @property - def results(self): - """Gets the results of this V1alpha2StructuredResourceHandle. # noqa: E501 - - Results lists all allocated driver resources. # noqa: E501 - - :return: The results of this V1alpha2StructuredResourceHandle. # noqa: E501 - :rtype: list[V1alpha2DriverAllocationResult] - """ - return self._results - - @results.setter - def results(self, results): - """Sets the results of this V1alpha2StructuredResourceHandle. - - Results lists all allocated driver resources. # noqa: E501 - - :param results: The results of this V1alpha2StructuredResourceHandle. # noqa: E501 - :type: list[V1alpha2DriverAllocationResult] - """ - if self.local_vars_configuration.client_side_validation and results is None: # noqa: E501 - raise ValueError("Invalid value for `results`, must not be `None`") # noqa: E501 - - self._results = results - - @property - def vendor_claim_parameters(self): - """Gets the vendor_claim_parameters of this V1alpha2StructuredResourceHandle. # noqa: E501 - - VendorClaimParameters are the per-claim configuration parameters from the resource claim parameters at the time that the claim was allocated. # noqa: E501 - - :return: The vendor_claim_parameters of this V1alpha2StructuredResourceHandle. # noqa: E501 - :rtype: object - """ - return self._vendor_claim_parameters - - @vendor_claim_parameters.setter - def vendor_claim_parameters(self, vendor_claim_parameters): - """Sets the vendor_claim_parameters of this V1alpha2StructuredResourceHandle. - - VendorClaimParameters are the per-claim configuration parameters from the resource claim parameters at the time that the claim was allocated. # noqa: E501 - - :param vendor_claim_parameters: The vendor_claim_parameters of this V1alpha2StructuredResourceHandle. # noqa: E501 - :type: object - """ - - self._vendor_claim_parameters = vendor_claim_parameters - - @property - def vendor_class_parameters(self): - """Gets the vendor_class_parameters of this V1alpha2StructuredResourceHandle. # noqa: E501 - - VendorClassParameters are the per-claim configuration parameters from the resource class at the time that the claim was allocated. # noqa: E501 - - :return: The vendor_class_parameters of this V1alpha2StructuredResourceHandle. # noqa: E501 - :rtype: object - """ - return self._vendor_class_parameters - - @vendor_class_parameters.setter - def vendor_class_parameters(self, vendor_class_parameters): - """Sets the vendor_class_parameters of this V1alpha2StructuredResourceHandle. - - VendorClassParameters are the per-claim configuration parameters from the resource class at the time that the claim was allocated. # noqa: E501 - - :param vendor_class_parameters: The vendor_class_parameters of this V1alpha2StructuredResourceHandle. # noqa: E501 - :type: object - """ - - self._vendor_class_parameters = vendor_class_parameters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2StructuredResourceHandle): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2StructuredResourceHandle): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_vendor_parameters.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_vendor_parameters.py deleted file mode 100644 index b0bd91fe2aee..000000000000 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_vendor_parameters.py +++ /dev/null @@ -1,150 +0,0 @@ -# coding: utf-8 - -""" - Kubernetes - - No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - - The version of the OpenAPI document: release-1.30 - Generated by: https://openapi-generator.tech -""" - - -import pprint -import re # noqa: F401 - -import six - -from kubernetes.client.configuration import Configuration - - -class V1alpha2VendorParameters(object): - """NOTE: This class is auto generated by OpenAPI Generator. - Ref: https://openapi-generator.tech - - Do not edit the class manually. - """ - - """ - Attributes: - openapi_types (dict): The key is attribute name - and the value is attribute type. - attribute_map (dict): The key is attribute name - and the value is json key in definition. - """ - openapi_types = { - 'driver_name': 'str', - 'parameters': 'object' - } - - attribute_map = { - 'driver_name': 'driverName', - 'parameters': 'parameters' - } - - def __init__(self, driver_name=None, parameters=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2VendorParameters - a model defined in OpenAPI""" # noqa: E501 - if local_vars_configuration is None: - local_vars_configuration = Configuration() - self.local_vars_configuration = local_vars_configuration - - self._driver_name = None - self._parameters = None - self.discriminator = None - - if driver_name is not None: - self.driver_name = driver_name - if parameters is not None: - self.parameters = parameters - - @property - def driver_name(self): - """Gets the driver_name of this V1alpha2VendorParameters. # noqa: E501 - - DriverName is the name used by the DRA driver kubelet plugin. # noqa: E501 - - :return: The driver_name of this V1alpha2VendorParameters. # noqa: E501 - :rtype: str - """ - return self._driver_name - - @driver_name.setter - def driver_name(self, driver_name): - """Sets the driver_name of this V1alpha2VendorParameters. - - DriverName is the name used by the DRA driver kubelet plugin. # noqa: E501 - - :param driver_name: The driver_name of this V1alpha2VendorParameters. # noqa: E501 - :type: str - """ - - self._driver_name = driver_name - - @property - def parameters(self): - """Gets the parameters of this V1alpha2VendorParameters. # noqa: E501 - - Parameters can be arbitrary setup parameters. They are ignored while allocating a claim. # noqa: E501 - - :return: The parameters of this V1alpha2VendorParameters. # noqa: E501 - :rtype: object - """ - return self._parameters - - @parameters.setter - def parameters(self, parameters): - """Sets the parameters of this V1alpha2VendorParameters. - - Parameters can be arbitrary setup parameters. They are ignored while allocating a claim. # noqa: E501 - - :param parameters: The parameters of this V1alpha2VendorParameters. # noqa: E501 - :type: object - """ - - self._parameters = parameters - - def to_dict(self): - """Returns the model properties as a dict""" - result = {} - - for attr, _ in six.iteritems(self.openapi_types): - value = getattr(self, attr) - if isinstance(value, list): - result[attr] = list(map( - lambda x: x.to_dict() if hasattr(x, "to_dict") else x, - value - )) - elif hasattr(value, "to_dict"): - result[attr] = value.to_dict() - elif isinstance(value, dict): - result[attr] = dict(map( - lambda item: (item[0], item[1].to_dict()) - if hasattr(item[1], "to_dict") else item, - value.items() - )) - else: - result[attr] = value - - return result - - def to_str(self): - """Returns the string representation of the model""" - return pprint.pformat(self.to_dict()) - - def __repr__(self): - """For `print` and `pprint`""" - return self.to_str() - - def __eq__(self, other): - """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2VendorParameters): - return False - - return self.to_dict() == other.to_dict() - - def __ne__(self, other): - """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2VendorParameters): - return True - - return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocated_device_status.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocated_device_status.py index b798b8d32e52..d82eff917292 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocated_device_status.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocated_device_status.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -78,7 +78,7 @@ def __init__(self, conditions=None, data=None, device=None, driver=None, network def conditions(self): """Gets the conditions of this V1alpha3AllocatedDeviceStatus. # noqa: E501 - Conditions contains the latest observation of the device's state. If the device has been configured according to the class and claim config references, the `Ready` condition should be True. # noqa: E501 + Conditions contains the latest observation of the device's state. If the device has been configured according to the class and claim config references, the `Ready` condition should be True. Must not contain more than 8 entries. # noqa: E501 :return: The conditions of this V1alpha3AllocatedDeviceStatus. # noqa: E501 :rtype: list[V1Condition] @@ -89,7 +89,7 @@ def conditions(self): def conditions(self, conditions): """Sets the conditions of this V1alpha3AllocatedDeviceStatus. - Conditions contains the latest observation of the device's state. If the device has been configured according to the class and claim config references, the `Ready` condition should be True. # noqa: E501 + Conditions contains the latest observation of the device's state. If the device has been configured according to the class and claim config references, the `Ready` condition should be True. Must not contain more than 8 entries. # noqa: E501 :param conditions: The conditions of this V1alpha3AllocatedDeviceStatus. # noqa: E501 :type: list[V1Condition] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocation_result.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocation_result.py index eae28ab55ab7..68314a17d693 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocation_result.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_allocation_result.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_basic_device.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_basic_device.py index 58f561aca6b1..b5515cc8797a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_basic_device.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_basic_device.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -33,29 +33,77 @@ class V1alpha3BasicDevice(object): and the value is json key in definition. """ openapi_types = { + 'all_nodes': 'bool', 'attributes': 'dict(str, V1alpha3DeviceAttribute)', - 'capacity': 'dict(str, str)' + 'capacity': 'dict(str, str)', + 'consumes_counters': 'list[V1alpha3DeviceCounterConsumption]', + 'node_name': 'str', + 'node_selector': 'V1NodeSelector', + 'taints': 'list[V1alpha3DeviceTaint]' } attribute_map = { + 'all_nodes': 'allNodes', 'attributes': 'attributes', - 'capacity': 'capacity' + 'capacity': 'capacity', + 'consumes_counters': 'consumesCounters', + 'node_name': 'nodeName', + 'node_selector': 'nodeSelector', + 'taints': 'taints' } - def __init__(self, attributes=None, capacity=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, all_nodes=None, attributes=None, capacity=None, consumes_counters=None, node_name=None, node_selector=None, taints=None, local_vars_configuration=None): # noqa: E501 """V1alpha3BasicDevice - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration + self._all_nodes = None self._attributes = None self._capacity = None + self._consumes_counters = None + self._node_name = None + self._node_selector = None + self._taints = None self.discriminator = None + if all_nodes is not None: + self.all_nodes = all_nodes if attributes is not None: self.attributes = attributes if capacity is not None: self.capacity = capacity + if consumes_counters is not None: + self.consumes_counters = consumes_counters + if node_name is not None: + self.node_name = node_name + if node_selector is not None: + self.node_selector = node_selector + if taints is not None: + self.taints = taints + + @property + def all_nodes(self): + """Gets the all_nodes of this V1alpha3BasicDevice. # noqa: E501 + + AllNodes indicates that all nodes have access to the device. Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set. # noqa: E501 + + :return: The all_nodes of this V1alpha3BasicDevice. # noqa: E501 + :rtype: bool + """ + return self._all_nodes + + @all_nodes.setter + def all_nodes(self, all_nodes): + """Sets the all_nodes of this V1alpha3BasicDevice. + + AllNodes indicates that all nodes have access to the device. Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set. # noqa: E501 + + :param all_nodes: The all_nodes of this V1alpha3BasicDevice. # noqa: E501 + :type: bool + """ + + self._all_nodes = all_nodes @property def attributes(self): @@ -103,6 +151,96 @@ def capacity(self, capacity): self._capacity = capacity + @property + def consumes_counters(self): + """Gets the consumes_counters of this V1alpha3BasicDevice. # noqa: E501 + + ConsumesCounters defines a list of references to sharedCounters and the set of counters that the device will consume from those counter sets. There can only be a single entry per counterSet. The total number of device counter consumption entries must be <= 32. In addition, the total number in the entire ResourceSlice must be <= 1024 (for example, 64 devices with 16 counters each). # noqa: E501 + + :return: The consumes_counters of this V1alpha3BasicDevice. # noqa: E501 + :rtype: list[V1alpha3DeviceCounterConsumption] + """ + return self._consumes_counters + + @consumes_counters.setter + def consumes_counters(self, consumes_counters): + """Sets the consumes_counters of this V1alpha3BasicDevice. + + ConsumesCounters defines a list of references to sharedCounters and the set of counters that the device will consume from those counter sets. There can only be a single entry per counterSet. The total number of device counter consumption entries must be <= 32. In addition, the total number in the entire ResourceSlice must be <= 1024 (for example, 64 devices with 16 counters each). # noqa: E501 + + :param consumes_counters: The consumes_counters of this V1alpha3BasicDevice. # noqa: E501 + :type: list[V1alpha3DeviceCounterConsumption] + """ + + self._consumes_counters = consumes_counters + + @property + def node_name(self): + """Gets the node_name of this V1alpha3BasicDevice. # noqa: E501 + + NodeName identifies the node where the device is available. Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set. # noqa: E501 + + :return: The node_name of this V1alpha3BasicDevice. # noqa: E501 + :rtype: str + """ + return self._node_name + + @node_name.setter + def node_name(self, node_name): + """Sets the node_name of this V1alpha3BasicDevice. + + NodeName identifies the node where the device is available. Must only be set if Spec.PerDeviceNodeSelection is set to true. At most one of NodeName, NodeSelector and AllNodes can be set. # noqa: E501 + + :param node_name: The node_name of this V1alpha3BasicDevice. # noqa: E501 + :type: str + """ + + self._node_name = node_name + + @property + def node_selector(self): + """Gets the node_selector of this V1alpha3BasicDevice. # noqa: E501 + + + :return: The node_selector of this V1alpha3BasicDevice. # noqa: E501 + :rtype: V1NodeSelector + """ + return self._node_selector + + @node_selector.setter + def node_selector(self, node_selector): + """Sets the node_selector of this V1alpha3BasicDevice. + + + :param node_selector: The node_selector of this V1alpha3BasicDevice. # noqa: E501 + :type: V1NodeSelector + """ + + self._node_selector = node_selector + + @property + def taints(self): + """Gets the taints of this V1alpha3BasicDevice. # noqa: E501 + + If specified, these are the driver-defined taints. The maximum number of taints is 4. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :return: The taints of this V1alpha3BasicDevice. # noqa: E501 + :rtype: list[V1alpha3DeviceTaint] + """ + return self._taints + + @taints.setter + def taints(self, taints): + """Sets the taints of this V1alpha3BasicDevice. + + If specified, these are the driver-defined taints. The maximum number of taints is 4. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :param taints: The taints of this V1alpha3BasicDevice. # noqa: E501 + :type: list[V1alpha3DeviceTaint] + """ + + self._taints = taints + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_cel_device_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_cel_device_selector.py index 68b857cfbc95..5705a78d4dc1 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_cel_device_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_cel_device_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_counter.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_counter.py new file mode 100644 index 000000000000..4c4a1f03e181 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_counter.py @@ -0,0 +1,123 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3Counter(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'value': 'str' + } + + attribute_map = { + 'value': 'value' + } + + def __init__(self, value=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3Counter - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._value = None + self.discriminator = None + + self.value = value + + @property + def value(self): + """Gets the value of this V1alpha3Counter. # noqa: E501 + + Value defines how much of a certain device counter is available. # noqa: E501 + + :return: The value of this V1alpha3Counter. # noqa: E501 + :rtype: str + """ + return self._value + + @value.setter + def value(self, value): + """Sets the value of this V1alpha3Counter. + + Value defines how much of a certain device counter is available. # noqa: E501 + + :param value: The value of this V1alpha3Counter. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and value is None: # noqa: E501 + raise ValueError("Invalid value for `value`, must not be `None`") # noqa: E501 + + self._value = value + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, V1alpha3Counter): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, V1alpha3Counter): + return True + + return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_counter_set.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_counter_set.py new file mode 100644 index 000000000000..143a9b9c06fd --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_counter_set.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3CounterSet(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'counters': 'dict(str, V1alpha3Counter)', + 'name': 'str' + } + + attribute_map = { + 'counters': 'counters', + 'name': 'name' + } + + def __init__(self, counters=None, name=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3CounterSet - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._counters = None + self._name = None + self.discriminator = None + + self.counters = counters + self.name = name + + @property + def counters(self): + """Gets the counters of this V1alpha3CounterSet. # noqa: E501 + + Counters defines the counters that will be consumed by the device. The name of each counter must be unique in that set and must be a DNS label. To ensure this uniqueness, capacities defined by the vendor must be listed without the driver name as domain prefix in their name. All others must be listed with their domain prefix. The maximum number of counters is 32. # noqa: E501 + + :return: The counters of this V1alpha3CounterSet. # noqa: E501 + :rtype: dict(str, V1alpha3Counter) + """ + return self._counters + + @counters.setter + def counters(self, counters): + """Sets the counters of this V1alpha3CounterSet. + + Counters defines the counters that will be consumed by the device. The name of each counter must be unique in that set and must be a DNS label. To ensure this uniqueness, capacities defined by the vendor must be listed without the driver name as domain prefix in their name. All others must be listed with their domain prefix. The maximum number of counters is 32. # noqa: E501 + + :param counters: The counters of this V1alpha3CounterSet. # noqa: E501 + :type: dict(str, V1alpha3Counter) + """ + if self.local_vars_configuration.client_side_validation and counters is None: # noqa: E501 + raise ValueError("Invalid value for `counters`, must not be `None`") # noqa: E501 + + self._counters = counters + + @property + def name(self): + """Gets the name of this V1alpha3CounterSet. # noqa: E501 + + CounterSet is the name of the set from which the counters defined will be consumed. # noqa: E501 + + :return: The name of this V1alpha3CounterSet. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this V1alpha3CounterSet. + + CounterSet is the name of the set from which the counters defined will be consumed. # noqa: E501 + + :param name: The name of this V1alpha3CounterSet. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 + + self._name = name + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, V1alpha3CounterSet): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, V1alpha3CounterSet): + return True + + return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device.py index fe72302d924b..15d0c8300cda 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_configuration.py index f4f847c4a72b..4fa7345fe2d3 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -86,7 +86,7 @@ def opaque(self, opaque): def requests(self): """Gets the requests of this V1alpha3DeviceAllocationConfiguration. # noqa: E501 - Requests lists the names of requests where the configuration applies. If empty, its applies to all requests. # noqa: E501 + Requests lists the names of requests where the configuration applies. If empty, its applies to all requests. References to subrequests must include the name of the main request and may include the subrequest using the format
      [/]. If just the main request is given, the configuration applies to all subrequests. # noqa: E501 :return: The requests of this V1alpha3DeviceAllocationConfiguration. # noqa: E501 :rtype: list[str] @@ -97,7 +97,7 @@ def requests(self): def requests(self, requests): """Sets the requests of this V1alpha3DeviceAllocationConfiguration. - Requests lists the names of requests where the configuration applies. If empty, its applies to all requests. # noqa: E501 + Requests lists the names of requests where the configuration applies. If empty, its applies to all requests. References to subrequests must include the name of the main request and may include the subrequest using the format
      [/]. If just the main request is given, the configuration applies to all subrequests. # noqa: E501 :param requests: The requests of this V1alpha3DeviceAllocationConfiguration. # noqa: E501 :type: list[str] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_result.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_result.py index 60df796fa4b7..77d98ed200bd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_result.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_allocation_result.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_attribute.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_attribute.py index 13dc6573b710..7551a8219545 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_attribute.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_attribute.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim.py index 1fff2d45ba7c..81f5dac16f76 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim_configuration.py index a634523dc149..d8e81d282e14 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_claim_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -82,7 +82,7 @@ def opaque(self, opaque): def requests(self): """Gets the requests of this V1alpha3DeviceClaimConfiguration. # noqa: E501 - Requests lists the names of requests where the configuration applies. If empty, it applies to all requests. # noqa: E501 + Requests lists the names of requests where the configuration applies. If empty, it applies to all requests. References to subrequests must include the name of the main request and may include the subrequest using the format
      [/]. If just the main request is given, the configuration applies to all subrequests. # noqa: E501 :return: The requests of this V1alpha3DeviceClaimConfiguration. # noqa: E501 :rtype: list[str] @@ -93,7 +93,7 @@ def requests(self): def requests(self, requests): """Sets the requests of this V1alpha3DeviceClaimConfiguration. - Requests lists the names of requests where the configuration applies. If empty, it applies to all requests. # noqa: E501 + Requests lists the names of requests where the configuration applies. If empty, it applies to all requests. References to subrequests must include the name of the main request and may include the subrequest using the format
      [/]. If just the main request is given, the configuration applies to all subrequests. # noqa: E501 :param requests: The requests of this V1alpha3DeviceClaimConfiguration. # noqa: E501 :type: list[str] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class.py index 6d291dcfc5ff..41560e229233 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_configuration.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_configuration.py index bf547b0c5736..221e0a8ba8f4 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_configuration.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_configuration.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_list.py index d582b6bf712d..6b0b98483b9e 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_spec.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_spec.py index 4655604235b5..fb3709462924 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_spec.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_class_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_constraint.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_constraint.py index 67b9d9bb1c12..46fd71a00e45 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_constraint.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_constraint.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -84,7 +84,7 @@ def match_attribute(self, match_attribute): def requests(self): """Gets the requests of this V1alpha3DeviceConstraint. # noqa: E501 - Requests is a list of the one or more requests in this claim which must co-satisfy this constraint. If a request is fulfilled by multiple devices, then all of the devices must satisfy the constraint. If this is not specified, this constraint applies to all requests in this claim. # noqa: E501 + Requests is a list of the one or more requests in this claim which must co-satisfy this constraint. If a request is fulfilled by multiple devices, then all of the devices must satisfy the constraint. If this is not specified, this constraint applies to all requests in this claim. References to subrequests must include the name of the main request and may include the subrequest using the format
      [/]. If just the main request is given, the constraint applies to all subrequests. # noqa: E501 :return: The requests of this V1alpha3DeviceConstraint. # noqa: E501 :rtype: list[str] @@ -95,7 +95,7 @@ def requests(self): def requests(self, requests): """Sets the requests of this V1alpha3DeviceConstraint. - Requests is a list of the one or more requests in this claim which must co-satisfy this constraint. If a request is fulfilled by multiple devices, then all of the devices must satisfy the constraint. If this is not specified, this constraint applies to all requests in this claim. # noqa: E501 + Requests is a list of the one or more requests in this claim which must co-satisfy this constraint. If a request is fulfilled by multiple devices, then all of the devices must satisfy the constraint. If this is not specified, this constraint applies to all requests in this claim. References to subrequests must include the name of the main request and may include the subrequest using the format
      [/]. If just the main request is given, the constraint applies to all subrequests. # noqa: E501 :param requests: The requests of this V1alpha3DeviceConstraint. # noqa: E501 :type: list[str] diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_counter_consumption.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_counter_consumption.py new file mode 100644 index 000000000000..4ee5c2b80054 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_counter_consumption.py @@ -0,0 +1,152 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3DeviceCounterConsumption(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'counter_set': 'str', + 'counters': 'dict(str, V1alpha3Counter)' + } + + attribute_map = { + 'counter_set': 'counterSet', + 'counters': 'counters' + } + + def __init__(self, counter_set=None, counters=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3DeviceCounterConsumption - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._counter_set = None + self._counters = None + self.discriminator = None + + self.counter_set = counter_set + self.counters = counters + + @property + def counter_set(self): + """Gets the counter_set of this V1alpha3DeviceCounterConsumption. # noqa: E501 + + CounterSet defines the set from which the counters defined will be consumed. # noqa: E501 + + :return: The counter_set of this V1alpha3DeviceCounterConsumption. # noqa: E501 + :rtype: str + """ + return self._counter_set + + @counter_set.setter + def counter_set(self, counter_set): + """Sets the counter_set of this V1alpha3DeviceCounterConsumption. + + CounterSet defines the set from which the counters defined will be consumed. # noqa: E501 + + :param counter_set: The counter_set of this V1alpha3DeviceCounterConsumption. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and counter_set is None: # noqa: E501 + raise ValueError("Invalid value for `counter_set`, must not be `None`") # noqa: E501 + + self._counter_set = counter_set + + @property + def counters(self): + """Gets the counters of this V1alpha3DeviceCounterConsumption. # noqa: E501 + + Counters defines the Counter that will be consumed by the device. The maximum number counters in a device is 32. In addition, the maximum number of all counters in all devices is 1024 (for example, 64 devices with 16 counters each). # noqa: E501 + + :return: The counters of this V1alpha3DeviceCounterConsumption. # noqa: E501 + :rtype: dict(str, V1alpha3Counter) + """ + return self._counters + + @counters.setter + def counters(self, counters): + """Sets the counters of this V1alpha3DeviceCounterConsumption. + + Counters defines the Counter that will be consumed by the device. The maximum number counters in a device is 32. In addition, the maximum number of all counters in all devices is 1024 (for example, 64 devices with 16 counters each). # noqa: E501 + + :param counters: The counters of this V1alpha3DeviceCounterConsumption. # noqa: E501 + :type: dict(str, V1alpha3Counter) + """ + if self.local_vars_configuration.client_side_validation and counters is None: # noqa: E501 + raise ValueError("Invalid value for `counters`, must not be `None`") # noqa: E501 + + self._counters = counters + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, V1alpha3DeviceCounterConsumption): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, V1alpha3DeviceCounterConsumption): + return True + + return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request.py index 5c958b3ea6cb..1702a840d432 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -37,8 +37,10 @@ class V1alpha3DeviceRequest(object): 'allocation_mode': 'str', 'count': 'int', 'device_class_name': 'str', + 'first_available': 'list[V1alpha3DeviceSubRequest]', 'name': 'str', - 'selectors': 'list[V1alpha3DeviceSelector]' + 'selectors': 'list[V1alpha3DeviceSelector]', + 'tolerations': 'list[V1alpha3DeviceToleration]' } attribute_map = { @@ -46,11 +48,13 @@ class V1alpha3DeviceRequest(object): 'allocation_mode': 'allocationMode', 'count': 'count', 'device_class_name': 'deviceClassName', + 'first_available': 'firstAvailable', 'name': 'name', - 'selectors': 'selectors' + 'selectors': 'selectors', + 'tolerations': 'tolerations' } - def __init__(self, admin_access=None, allocation_mode=None, count=None, device_class_name=None, name=None, selectors=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, admin_access=None, allocation_mode=None, count=None, device_class_name=None, first_available=None, name=None, selectors=None, tolerations=None, local_vars_configuration=None): # noqa: E501 """V1alpha3DeviceRequest - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -60,8 +64,10 @@ def __init__(self, admin_access=None, allocation_mode=None, count=None, device_c self._allocation_mode = None self._count = None self._device_class_name = None + self._first_available = None self._name = None self._selectors = None + self._tolerations = None self.discriminator = None if admin_access is not None: @@ -70,16 +76,21 @@ def __init__(self, admin_access=None, allocation_mode=None, count=None, device_c self.allocation_mode = allocation_mode if count is not None: self.count = count - self.device_class_name = device_class_name + if device_class_name is not None: + self.device_class_name = device_class_name + if first_available is not None: + self.first_available = first_available self.name = name if selectors is not None: self.selectors = selectors + if tolerations is not None: + self.tolerations = tolerations @property def admin_access(self): """Gets the admin_access of this V1alpha3DeviceRequest. # noqa: E501 - AdminAccess indicates that this is a claim for administrative access to the device(s). Claims with AdminAccess are expected to be used for monitoring or other management services for a device. They ignore all ordinary claims to the device with respect to access modes and any resource allocations. This is an alpha field and requires enabling the DRAAdminAccess feature gate. Admin access is disabled if this field is unset or set to false, otherwise it is enabled. # noqa: E501 + AdminAccess indicates that this is a claim for administrative access to the device(s). Claims with AdminAccess are expected to be used for monitoring or other management services for a device. They ignore all ordinary claims to the device with respect to access modes and any resource allocations. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. This is an alpha field and requires enabling the DRAAdminAccess feature gate. Admin access is disabled if this field is unset or set to false, otherwise it is enabled. # noqa: E501 :return: The admin_access of this V1alpha3DeviceRequest. # noqa: E501 :rtype: bool @@ -90,7 +101,7 @@ def admin_access(self): def admin_access(self, admin_access): """Sets the admin_access of this V1alpha3DeviceRequest. - AdminAccess indicates that this is a claim for administrative access to the device(s). Claims with AdminAccess are expected to be used for monitoring or other management services for a device. They ignore all ordinary claims to the device with respect to access modes and any resource allocations. This is an alpha field and requires enabling the DRAAdminAccess feature gate. Admin access is disabled if this field is unset or set to false, otherwise it is enabled. # noqa: E501 + AdminAccess indicates that this is a claim for administrative access to the device(s). Claims with AdminAccess are expected to be used for monitoring or other management services for a device. They ignore all ordinary claims to the device with respect to access modes and any resource allocations. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. This is an alpha field and requires enabling the DRAAdminAccess feature gate. Admin access is disabled if this field is unset or set to false, otherwise it is enabled. # noqa: E501 :param admin_access: The admin_access of this V1alpha3DeviceRequest. # noqa: E501 :type: bool @@ -102,7 +113,7 @@ def admin_access(self, admin_access): def allocation_mode(self): """Gets the allocation_mode of this V1alpha3DeviceRequest. # noqa: E501 - AllocationMode and its related fields define how devices are allocated to satisfy this request. Supported values are: - ExactCount: This request is for a specific number of devices. This is the default. The exact number is provided in the count field. - All: This request is for all of the matching devices in a pool. Allocation will fail if some devices are already allocated, unless adminAccess is requested. If AlloctionMode is not specified, the default mode is ExactCount. If the mode is ExactCount and count is not specified, the default count is one. Any other requests must specify this field. More modes may get added in the future. Clients must refuse to handle requests with unknown modes. # noqa: E501 + AllocationMode and its related fields define how devices are allocated to satisfy this request. Supported values are: - ExactCount: This request is for a specific number of devices. This is the default. The exact number is provided in the count field. - All: This request is for all of the matching devices in a pool. At least one device must exist on the node for the allocation to succeed. Allocation will fail if some devices are already allocated, unless adminAccess is requested. If AllocationMode is not specified, the default mode is ExactCount. If the mode is ExactCount and count is not specified, the default count is one. Any other requests must specify this field. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. More modes may get added in the future. Clients must refuse to handle requests with unknown modes. # noqa: E501 :return: The allocation_mode of this V1alpha3DeviceRequest. # noqa: E501 :rtype: str @@ -113,7 +124,7 @@ def allocation_mode(self): def allocation_mode(self, allocation_mode): """Sets the allocation_mode of this V1alpha3DeviceRequest. - AllocationMode and its related fields define how devices are allocated to satisfy this request. Supported values are: - ExactCount: This request is for a specific number of devices. This is the default. The exact number is provided in the count field. - All: This request is for all of the matching devices in a pool. Allocation will fail if some devices are already allocated, unless adminAccess is requested. If AlloctionMode is not specified, the default mode is ExactCount. If the mode is ExactCount and count is not specified, the default count is one. Any other requests must specify this field. More modes may get added in the future. Clients must refuse to handle requests with unknown modes. # noqa: E501 + AllocationMode and its related fields define how devices are allocated to satisfy this request. Supported values are: - ExactCount: This request is for a specific number of devices. This is the default. The exact number is provided in the count field. - All: This request is for all of the matching devices in a pool. At least one device must exist on the node for the allocation to succeed. Allocation will fail if some devices are already allocated, unless adminAccess is requested. If AllocationMode is not specified, the default mode is ExactCount. If the mode is ExactCount and count is not specified, the default count is one. Any other requests must specify this field. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. More modes may get added in the future. Clients must refuse to handle requests with unknown modes. # noqa: E501 :param allocation_mode: The allocation_mode of this V1alpha3DeviceRequest. # noqa: E501 :type: str @@ -125,7 +136,7 @@ def allocation_mode(self, allocation_mode): def count(self): """Gets the count of this V1alpha3DeviceRequest. # noqa: E501 - Count is used only when the count mode is \"ExactCount\". Must be greater than zero. If AllocationMode is ExactCount and this field is not specified, the default is one. # noqa: E501 + Count is used only when the count mode is \"ExactCount\". Must be greater than zero. If AllocationMode is ExactCount and this field is not specified, the default is one. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. # noqa: E501 :return: The count of this V1alpha3DeviceRequest. # noqa: E501 :rtype: int @@ -136,7 +147,7 @@ def count(self): def count(self, count): """Sets the count of this V1alpha3DeviceRequest. - Count is used only when the count mode is \"ExactCount\". Must be greater than zero. If AllocationMode is ExactCount and this field is not specified, the default is one. # noqa: E501 + Count is used only when the count mode is \"ExactCount\". Must be greater than zero. If AllocationMode is ExactCount and this field is not specified, the default is one. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. # noqa: E501 :param count: The count of this V1alpha3DeviceRequest. # noqa: E501 :type: int @@ -148,7 +159,7 @@ def count(self, count): def device_class_name(self): """Gets the device_class_name of this V1alpha3DeviceRequest. # noqa: E501 - DeviceClassName references a specific DeviceClass, which can define additional configuration and selectors to be inherited by this request. A class is required. Which classes are available depends on the cluster. Administrators may use this to restrict which devices may get requested by only installing classes with selectors for permitted devices. If users are free to request anything without restrictions, then administrators can create an empty DeviceClass for users to reference. # noqa: E501 + DeviceClassName references a specific DeviceClass, which can define additional configuration and selectors to be inherited by this request. A class is required if no subrequests are specified in the firstAvailable list and no class can be set if subrequests are specified in the firstAvailable list. Which classes are available depends on the cluster. Administrators may use this to restrict which devices may get requested by only installing classes with selectors for permitted devices. If users are free to request anything without restrictions, then administrators can create an empty DeviceClass for users to reference. # noqa: E501 :return: The device_class_name of this V1alpha3DeviceRequest. # noqa: E501 :rtype: str @@ -159,16 +170,37 @@ def device_class_name(self): def device_class_name(self, device_class_name): """Sets the device_class_name of this V1alpha3DeviceRequest. - DeviceClassName references a specific DeviceClass, which can define additional configuration and selectors to be inherited by this request. A class is required. Which classes are available depends on the cluster. Administrators may use this to restrict which devices may get requested by only installing classes with selectors for permitted devices. If users are free to request anything without restrictions, then administrators can create an empty DeviceClass for users to reference. # noqa: E501 + DeviceClassName references a specific DeviceClass, which can define additional configuration and selectors to be inherited by this request. A class is required if no subrequests are specified in the firstAvailable list and no class can be set if subrequests are specified in the firstAvailable list. Which classes are available depends on the cluster. Administrators may use this to restrict which devices may get requested by only installing classes with selectors for permitted devices. If users are free to request anything without restrictions, then administrators can create an empty DeviceClass for users to reference. # noqa: E501 :param device_class_name: The device_class_name of this V1alpha3DeviceRequest. # noqa: E501 :type: str """ - if self.local_vars_configuration.client_side_validation and device_class_name is None: # noqa: E501 - raise ValueError("Invalid value for `device_class_name`, must not be `None`") # noqa: E501 self._device_class_name = device_class_name + @property + def first_available(self): + """Gets the first_available of this V1alpha3DeviceRequest. # noqa: E501 + + FirstAvailable contains subrequests, of which exactly one will be satisfied by the scheduler to satisfy this request. It tries to satisfy them in the order in which they are listed here. So if there are two entries in the list, the scheduler will only check the second one if it determines that the first one cannot be used. This field may only be set in the entries of DeviceClaim.Requests. DRA does not yet implement scoring, so the scheduler will select the first set of devices that satisfies all the requests in the claim. And if the requirements can be satisfied on more than one node, other scheduling features will determine which node is chosen. This means that the set of devices allocated to a claim might not be the optimal set available to the cluster. Scoring will be implemented later. # noqa: E501 + + :return: The first_available of this V1alpha3DeviceRequest. # noqa: E501 + :rtype: list[V1alpha3DeviceSubRequest] + """ + return self._first_available + + @first_available.setter + def first_available(self, first_available): + """Sets the first_available of this V1alpha3DeviceRequest. + + FirstAvailable contains subrequests, of which exactly one will be satisfied by the scheduler to satisfy this request. It tries to satisfy them in the order in which they are listed here. So if there are two entries in the list, the scheduler will only check the second one if it determines that the first one cannot be used. This field may only be set in the entries of DeviceClaim.Requests. DRA does not yet implement scoring, so the scheduler will select the first set of devices that satisfies all the requests in the claim. And if the requirements can be satisfied on more than one node, other scheduling features will determine which node is chosen. This means that the set of devices allocated to a claim might not be the optimal set available to the cluster. Scoring will be implemented later. # noqa: E501 + + :param first_available: The first_available of this V1alpha3DeviceRequest. # noqa: E501 + :type: list[V1alpha3DeviceSubRequest] + """ + + self._first_available = first_available + @property def name(self): """Gets the name of this V1alpha3DeviceRequest. # noqa: E501 @@ -198,7 +230,7 @@ def name(self, name): def selectors(self): """Gets the selectors of this V1alpha3DeviceRequest. # noqa: E501 - Selectors define criteria which must be satisfied by a specific device in order for that device to be considered for this request. All selectors must be satisfied for a device to be considered. # noqa: E501 + Selectors define criteria which must be satisfied by a specific device in order for that device to be considered for this request. All selectors must be satisfied for a device to be considered. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. # noqa: E501 :return: The selectors of this V1alpha3DeviceRequest. # noqa: E501 :rtype: list[V1alpha3DeviceSelector] @@ -209,7 +241,7 @@ def selectors(self): def selectors(self, selectors): """Sets the selectors of this V1alpha3DeviceRequest. - Selectors define criteria which must be satisfied by a specific device in order for that device to be considered for this request. All selectors must be satisfied for a device to be considered. # noqa: E501 + Selectors define criteria which must be satisfied by a specific device in order for that device to be considered for this request. All selectors must be satisfied for a device to be considered. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. # noqa: E501 :param selectors: The selectors of this V1alpha3DeviceRequest. # noqa: E501 :type: list[V1alpha3DeviceSelector] @@ -217,6 +249,29 @@ def selectors(self, selectors): self._selectors = selectors + @property + def tolerations(self): + """Gets the tolerations of this V1alpha3DeviceRequest. # noqa: E501 + + If specified, the request's tolerations. Tolerations for NoSchedule are required to allocate a device which has a taint with that effect. The same applies to NoExecute. In addition, should any of the allocated devices get tainted with NoExecute after allocation and that effect is not tolerated, then all pods consuming the ResourceClaim get deleted to evict them. The scheduler will not let new pods reserve the claim while it has these tainted devices. Once all pods are evicted, the claim will get deallocated. The maximum number of tolerations is 16. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :return: The tolerations of this V1alpha3DeviceRequest. # noqa: E501 + :rtype: list[V1alpha3DeviceToleration] + """ + return self._tolerations + + @tolerations.setter + def tolerations(self, tolerations): + """Sets the tolerations of this V1alpha3DeviceRequest. + + If specified, the request's tolerations. Tolerations for NoSchedule are required to allocate a device which has a taint with that effect. The same applies to NoExecute. In addition, should any of the allocated devices get tainted with NoExecute after allocation and that effect is not tolerated, then all pods consuming the ResourceClaim get deleted to evict them. The scheduler will not let new pods reserve the claim while it has these tainted devices. Once all pods are evicted, the claim will get deallocated. The maximum number of tolerations is 16. This field can only be set when deviceClassName is set and no subrequests are specified in the firstAvailable list. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :param tolerations: The tolerations of this V1alpha3DeviceRequest. # noqa: E501 + :type: list[V1alpha3DeviceToleration] + """ + + self._tolerations = tolerations + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request_allocation_result.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request_allocation_result.py index 3ecebb694f80..582bbbd9e8dd 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request_allocation_result.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_request_allocation_result.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -37,7 +37,8 @@ class V1alpha3DeviceRequestAllocationResult(object): 'device': 'str', 'driver': 'str', 'pool': 'str', - 'request': 'str' + 'request': 'str', + 'tolerations': 'list[V1alpha3DeviceToleration]' } attribute_map = { @@ -45,10 +46,11 @@ class V1alpha3DeviceRequestAllocationResult(object): 'device': 'device', 'driver': 'driver', 'pool': 'pool', - 'request': 'request' + 'request': 'request', + 'tolerations': 'tolerations' } - def __init__(self, admin_access=None, device=None, driver=None, pool=None, request=None, local_vars_configuration=None): # noqa: E501 + def __init__(self, admin_access=None, device=None, driver=None, pool=None, request=None, tolerations=None, local_vars_configuration=None): # noqa: E501 """V1alpha3DeviceRequestAllocationResult - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() @@ -59,6 +61,7 @@ def __init__(self, admin_access=None, device=None, driver=None, pool=None, reque self._driver = None self._pool = None self._request = None + self._tolerations = None self.discriminator = None if admin_access is not None: @@ -67,6 +70,8 @@ def __init__(self, admin_access=None, device=None, driver=None, pool=None, reque self.driver = driver self.pool = pool self.request = request + if tolerations is not None: + self.tolerations = tolerations @property def admin_access(self): @@ -170,7 +175,7 @@ def pool(self, pool): def request(self): """Gets the request of this V1alpha3DeviceRequestAllocationResult. # noqa: E501 - Request is the name of the request in the claim which caused this device to be allocated. Multiple devices may have been allocated per request. # noqa: E501 + Request is the name of the request in the claim which caused this device to be allocated. If it references a subrequest in the firstAvailable list on a DeviceRequest, this field must include both the name of the main request and the subrequest using the format
      /. Multiple devices may have been allocated per request. # noqa: E501 :return: The request of this V1alpha3DeviceRequestAllocationResult. # noqa: E501 :rtype: str @@ -181,7 +186,7 @@ def request(self): def request(self, request): """Sets the request of this V1alpha3DeviceRequestAllocationResult. - Request is the name of the request in the claim which caused this device to be allocated. Multiple devices may have been allocated per request. # noqa: E501 + Request is the name of the request in the claim which caused this device to be allocated. If it references a subrequest in the firstAvailable list on a DeviceRequest, this field must include both the name of the main request and the subrequest using the format
      /. Multiple devices may have been allocated per request. # noqa: E501 :param request: The request of this V1alpha3DeviceRequestAllocationResult. # noqa: E501 :type: str @@ -191,6 +196,29 @@ def request(self, request): self._request = request + @property + def tolerations(self): + """Gets the tolerations of this V1alpha3DeviceRequestAllocationResult. # noqa: E501 + + A copy of all tolerations specified in the request at the time when the device got allocated. The maximum number of tolerations is 16. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :return: The tolerations of this V1alpha3DeviceRequestAllocationResult. # noqa: E501 + :rtype: list[V1alpha3DeviceToleration] + """ + return self._tolerations + + @tolerations.setter + def tolerations(self, tolerations): + """Sets the tolerations of this V1alpha3DeviceRequestAllocationResult. + + A copy of all tolerations specified in the request at the time when the device got allocated. The maximum number of tolerations is 16. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :param tolerations: The tolerations of this V1alpha3DeviceRequestAllocationResult. # noqa: E501 + :type: list[V1alpha3DeviceToleration] + """ + + self._tolerations = tolerations + def to_dict(self): """Returns the model properties as a dict""" result = {} diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_selector.py index 3fab067b3901..03db1285a5ed 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_selector.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_selector.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.32 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_sub_request.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_sub_request.py new file mode 100644 index 000000000000..9c8c1ced9473 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_sub_request.py @@ -0,0 +1,264 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3DeviceSubRequest(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'allocation_mode': 'str', + 'count': 'int', + 'device_class_name': 'str', + 'name': 'str', + 'selectors': 'list[V1alpha3DeviceSelector]', + 'tolerations': 'list[V1alpha3DeviceToleration]' + } + + attribute_map = { + 'allocation_mode': 'allocationMode', + 'count': 'count', + 'device_class_name': 'deviceClassName', + 'name': 'name', + 'selectors': 'selectors', + 'tolerations': 'tolerations' + } + + def __init__(self, allocation_mode=None, count=None, device_class_name=None, name=None, selectors=None, tolerations=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3DeviceSubRequest - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._allocation_mode = None + self._count = None + self._device_class_name = None + self._name = None + self._selectors = None + self._tolerations = None + self.discriminator = None + + if allocation_mode is not None: + self.allocation_mode = allocation_mode + if count is not None: + self.count = count + self.device_class_name = device_class_name + self.name = name + if selectors is not None: + self.selectors = selectors + if tolerations is not None: + self.tolerations = tolerations + + @property + def allocation_mode(self): + """Gets the allocation_mode of this V1alpha3DeviceSubRequest. # noqa: E501 + + AllocationMode and its related fields define how devices are allocated to satisfy this request. Supported values are: - ExactCount: This request is for a specific number of devices. This is the default. The exact number is provided in the count field. - All: This request is for all of the matching devices in a pool. Allocation will fail if some devices are already allocated, unless adminAccess is requested. If AllocationMode is not specified, the default mode is ExactCount. If the mode is ExactCount and count is not specified, the default count is one. Any other requests must specify this field. More modes may get added in the future. Clients must refuse to handle requests with unknown modes. # noqa: E501 + + :return: The allocation_mode of this V1alpha3DeviceSubRequest. # noqa: E501 + :rtype: str + """ + return self._allocation_mode + + @allocation_mode.setter + def allocation_mode(self, allocation_mode): + """Sets the allocation_mode of this V1alpha3DeviceSubRequest. + + AllocationMode and its related fields define how devices are allocated to satisfy this request. Supported values are: - ExactCount: This request is for a specific number of devices. This is the default. The exact number is provided in the count field. - All: This request is for all of the matching devices in a pool. Allocation will fail if some devices are already allocated, unless adminAccess is requested. If AllocationMode is not specified, the default mode is ExactCount. If the mode is ExactCount and count is not specified, the default count is one. Any other requests must specify this field. More modes may get added in the future. Clients must refuse to handle requests with unknown modes. # noqa: E501 + + :param allocation_mode: The allocation_mode of this V1alpha3DeviceSubRequest. # noqa: E501 + :type: str + """ + + self._allocation_mode = allocation_mode + + @property + def count(self): + """Gets the count of this V1alpha3DeviceSubRequest. # noqa: E501 + + Count is used only when the count mode is \"ExactCount\". Must be greater than zero. If AllocationMode is ExactCount and this field is not specified, the default is one. # noqa: E501 + + :return: The count of this V1alpha3DeviceSubRequest. # noqa: E501 + :rtype: int + """ + return self._count + + @count.setter + def count(self, count): + """Sets the count of this V1alpha3DeviceSubRequest. + + Count is used only when the count mode is \"ExactCount\". Must be greater than zero. If AllocationMode is ExactCount and this field is not specified, the default is one. # noqa: E501 + + :param count: The count of this V1alpha3DeviceSubRequest. # noqa: E501 + :type: int + """ + + self._count = count + + @property + def device_class_name(self): + """Gets the device_class_name of this V1alpha3DeviceSubRequest. # noqa: E501 + + DeviceClassName references a specific DeviceClass, which can define additional configuration and selectors to be inherited by this subrequest. A class is required. Which classes are available depends on the cluster. Administrators may use this to restrict which devices may get requested by only installing classes with selectors for permitted devices. If users are free to request anything without restrictions, then administrators can create an empty DeviceClass for users to reference. # noqa: E501 + + :return: The device_class_name of this V1alpha3DeviceSubRequest. # noqa: E501 + :rtype: str + """ + return self._device_class_name + + @device_class_name.setter + def device_class_name(self, device_class_name): + """Sets the device_class_name of this V1alpha3DeviceSubRequest. + + DeviceClassName references a specific DeviceClass, which can define additional configuration and selectors to be inherited by this subrequest. A class is required. Which classes are available depends on the cluster. Administrators may use this to restrict which devices may get requested by only installing classes with selectors for permitted devices. If users are free to request anything without restrictions, then administrators can create an empty DeviceClass for users to reference. # noqa: E501 + + :param device_class_name: The device_class_name of this V1alpha3DeviceSubRequest. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and device_class_name is None: # noqa: E501 + raise ValueError("Invalid value for `device_class_name`, must not be `None`") # noqa: E501 + + self._device_class_name = device_class_name + + @property + def name(self): + """Gets the name of this V1alpha3DeviceSubRequest. # noqa: E501 + + Name can be used to reference this subrequest in the list of constraints or the list of configurations for the claim. References must use the format
      /. Must be a DNS label. # noqa: E501 + + :return: The name of this V1alpha3DeviceSubRequest. # noqa: E501 + :rtype: str + """ + return self._name + + @name.setter + def name(self, name): + """Sets the name of this V1alpha3DeviceSubRequest. + + Name can be used to reference this subrequest in the list of constraints or the list of configurations for the claim. References must use the format
      /. Must be a DNS label. # noqa: E501 + + :param name: The name of this V1alpha3DeviceSubRequest. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 + raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 + + self._name = name + + @property + def selectors(self): + """Gets the selectors of this V1alpha3DeviceSubRequest. # noqa: E501 + + Selectors define criteria which must be satisfied by a specific device in order for that device to be considered for this request. All selectors must be satisfied for a device to be considered. # noqa: E501 + + :return: The selectors of this V1alpha3DeviceSubRequest. # noqa: E501 + :rtype: list[V1alpha3DeviceSelector] + """ + return self._selectors + + @selectors.setter + def selectors(self, selectors): + """Sets the selectors of this V1alpha3DeviceSubRequest. + + Selectors define criteria which must be satisfied by a specific device in order for that device to be considered for this request. All selectors must be satisfied for a device to be considered. # noqa: E501 + + :param selectors: The selectors of this V1alpha3DeviceSubRequest. # noqa: E501 + :type: list[V1alpha3DeviceSelector] + """ + + self._selectors = selectors + + @property + def tolerations(self): + """Gets the tolerations of this V1alpha3DeviceSubRequest. # noqa: E501 + + If specified, the request's tolerations. Tolerations for NoSchedule are required to allocate a device which has a taint with that effect. The same applies to NoExecute. In addition, should any of the allocated devices get tainted with NoExecute after allocation and that effect is not tolerated, then all pods consuming the ResourceClaim get deleted to evict them. The scheduler will not let new pods reserve the claim while it has these tainted devices. Once all pods are evicted, the claim will get deallocated. The maximum number of tolerations is 16. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :return: The tolerations of this V1alpha3DeviceSubRequest. # noqa: E501 + :rtype: list[V1alpha3DeviceToleration] + """ + return self._tolerations + + @tolerations.setter + def tolerations(self, tolerations): + """Sets the tolerations of this V1alpha3DeviceSubRequest. + + If specified, the request's tolerations. Tolerations for NoSchedule are required to allocate a device which has a taint with that effect. The same applies to NoExecute. In addition, should any of the allocated devices get tainted with NoExecute after allocation and that effect is not tolerated, then all pods consuming the ResourceClaim get deleted to evict them. The scheduler will not let new pods reserve the claim while it has these tainted devices. Once all pods are evicted, the claim will get deallocated. The maximum number of tolerations is 16. This is an alpha field and requires enabling the DRADeviceTaints feature gate. # noqa: E501 + + :param tolerations: The tolerations of this V1alpha3DeviceSubRequest. # noqa: E501 + :type: list[V1alpha3DeviceToleration] + """ + + self._tolerations = tolerations + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, V1alpha3DeviceSubRequest): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, V1alpha3DeviceSubRequest): + return True + + return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint.py new file mode 100644 index 000000000000..89ebd4dc4a53 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint.py @@ -0,0 +1,208 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3DeviceTaint(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'effect': 'str', + 'key': 'str', + 'time_added': 'datetime', + 'value': 'str' + } + + attribute_map = { + 'effect': 'effect', + 'key': 'key', + 'time_added': 'timeAdded', + 'value': 'value' + } + + def __init__(self, effect=None, key=None, time_added=None, value=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3DeviceTaint - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._effect = None + self._key = None + self._time_added = None + self._value = None + self.discriminator = None + + self.effect = effect + self.key = key + if time_added is not None: + self.time_added = time_added + if value is not None: + self.value = value + + @property + def effect(self): + """Gets the effect of this V1alpha3DeviceTaint. # noqa: E501 + + The effect of the taint on claims that do not tolerate the taint and through such claims on the pods using them. Valid effects are NoSchedule and NoExecute. PreferNoSchedule as used for nodes is not valid here. # noqa: E501 + + :return: The effect of this V1alpha3DeviceTaint. # noqa: E501 + :rtype: str + """ + return self._effect + + @effect.setter + def effect(self, effect): + """Sets the effect of this V1alpha3DeviceTaint. + + The effect of the taint on claims that do not tolerate the taint and through such claims on the pods using them. Valid effects are NoSchedule and NoExecute. PreferNoSchedule as used for nodes is not valid here. # noqa: E501 + + :param effect: The effect of this V1alpha3DeviceTaint. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and effect is None: # noqa: E501 + raise ValueError("Invalid value for `effect`, must not be `None`") # noqa: E501 + + self._effect = effect + + @property + def key(self): + """Gets the key of this V1alpha3DeviceTaint. # noqa: E501 + + The taint key to be applied to a device. Must be a label name. # noqa: E501 + + :return: The key of this V1alpha3DeviceTaint. # noqa: E501 + :rtype: str + """ + return self._key + + @key.setter + def key(self, key): + """Sets the key of this V1alpha3DeviceTaint. + + The taint key to be applied to a device. Must be a label name. # noqa: E501 + + :param key: The key of this V1alpha3DeviceTaint. # noqa: E501 + :type: str + """ + if self.local_vars_configuration.client_side_validation and key is None: # noqa: E501 + raise ValueError("Invalid value for `key`, must not be `None`") # noqa: E501 + + self._key = key + + @property + def time_added(self): + """Gets the time_added of this V1alpha3DeviceTaint. # noqa: E501 + + TimeAdded represents the time at which the taint was added. Added automatically during create or update if not set. # noqa: E501 + + :return: The time_added of this V1alpha3DeviceTaint. # noqa: E501 + :rtype: datetime + """ + return self._time_added + + @time_added.setter + def time_added(self, time_added): + """Sets the time_added of this V1alpha3DeviceTaint. + + TimeAdded represents the time at which the taint was added. Added automatically during create or update if not set. # noqa: E501 + + :param time_added: The time_added of this V1alpha3DeviceTaint. # noqa: E501 + :type: datetime + """ + + self._time_added = time_added + + @property + def value(self): + """Gets the value of this V1alpha3DeviceTaint. # noqa: E501 + + The taint value corresponding to the taint key. Must be a label value. # noqa: E501 + + :return: The value of this V1alpha3DeviceTaint. # noqa: E501 + :rtype: str + """ + return self._value + + @value.setter + def value(self, value): + """Sets the value of this V1alpha3DeviceTaint. + + The taint value corresponding to the taint key. Must be a label value. # noqa: E501 + + :param value: The value of this V1alpha3DeviceTaint. # noqa: E501 + :type: str + """ + + self._value = value + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, V1alpha3DeviceTaint): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, V1alpha3DeviceTaint): + return True + + return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule.py similarity index 71% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding.py rename to contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule.py index fc5b3854c353..343e44b28d84 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha1_validating_admission_policy_binding.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.31 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha1ValidatingAdmissionPolicyBinding(object): +class V1alpha3DeviceTaintRule(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -36,7 +36,7 @@ class V1alpha1ValidatingAdmissionPolicyBinding(object): 'api_version': 'str', 'kind': 'str', 'metadata': 'V1ObjectMeta', - 'spec': 'V1alpha1ValidatingAdmissionPolicyBindingSpec' + 'spec': 'V1alpha3DeviceTaintRuleSpec' } attribute_map = { @@ -47,7 +47,7 @@ class V1alpha1ValidatingAdmissionPolicyBinding(object): } def __init__(self, api_version=None, kind=None, metadata=None, spec=None, local_vars_configuration=None): # noqa: E501 - """V1alpha1ValidatingAdmissionPolicyBinding - a model defined in OpenAPI""" # noqa: E501 + """V1alpha3DeviceTaintRule - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -64,27 +64,26 @@ def __init__(self, api_version=None, kind=None, metadata=None, spec=None, local_ self.kind = kind if metadata is not None: self.metadata = metadata - if spec is not None: - self.spec = spec + self.spec = spec @property def api_version(self): - """Gets the api_version of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + """Gets the api_version of this V1alpha3DeviceTaintRule. # noqa: E501 APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :return: The api_version of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + :return: The api_version of this V1alpha3DeviceTaintRule. # noqa: E501 :rtype: str """ return self._api_version @api_version.setter def api_version(self, api_version): - """Sets the api_version of this V1alpha1ValidatingAdmissionPolicyBinding. + """Sets the api_version of this V1alpha3DeviceTaintRule. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :param api_version: The api_version of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + :param api_version: The api_version of this V1alpha3DeviceTaintRule. # noqa: E501 :type: str """ @@ -92,22 +91,22 @@ def api_version(self, api_version): @property def kind(self): - """Gets the kind of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + """Gets the kind of this V1alpha3DeviceTaintRule. # noqa: E501 Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :return: The kind of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + :return: The kind of this V1alpha3DeviceTaintRule. # noqa: E501 :rtype: str """ return self._kind @kind.setter def kind(self, kind): - """Sets the kind of this V1alpha1ValidatingAdmissionPolicyBinding. + """Sets the kind of this V1alpha3DeviceTaintRule. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :param kind: The kind of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + :param kind: The kind of this V1alpha3DeviceTaintRule. # noqa: E501 :type: str """ @@ -115,20 +114,20 @@ def kind(self, kind): @property def metadata(self): - """Gets the metadata of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + """Gets the metadata of this V1alpha3DeviceTaintRule. # noqa: E501 - :return: The metadata of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + :return: The metadata of this V1alpha3DeviceTaintRule. # noqa: E501 :rtype: V1ObjectMeta """ return self._metadata @metadata.setter def metadata(self, metadata): - """Sets the metadata of this V1alpha1ValidatingAdmissionPolicyBinding. + """Sets the metadata of this V1alpha3DeviceTaintRule. - :param metadata: The metadata of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + :param metadata: The metadata of this V1alpha3DeviceTaintRule. # noqa: E501 :type: V1ObjectMeta """ @@ -136,22 +135,24 @@ def metadata(self, metadata): @property def spec(self): - """Gets the spec of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 + """Gets the spec of this V1alpha3DeviceTaintRule. # noqa: E501 - :return: The spec of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 - :rtype: V1alpha1ValidatingAdmissionPolicyBindingSpec + :return: The spec of this V1alpha3DeviceTaintRule. # noqa: E501 + :rtype: V1alpha3DeviceTaintRuleSpec """ return self._spec @spec.setter def spec(self, spec): - """Sets the spec of this V1alpha1ValidatingAdmissionPolicyBinding. + """Sets the spec of this V1alpha3DeviceTaintRule. - :param spec: The spec of this V1alpha1ValidatingAdmissionPolicyBinding. # noqa: E501 - :type: V1alpha1ValidatingAdmissionPolicyBindingSpec + :param spec: The spec of this V1alpha3DeviceTaintRule. # noqa: E501 + :type: V1alpha3DeviceTaintRuleSpec """ + if self.local_vars_configuration.client_side_validation and spec is None: # noqa: E501 + raise ValueError("Invalid value for `spec`, must not be `None`") # noqa: E501 self._spec = spec @@ -189,14 +190,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyBinding): + if not isinstance(other, V1alpha3DeviceTaintRule): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha1ValidatingAdmissionPolicyBinding): + if not isinstance(other, V1alpha3DeviceTaintRule): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_slice_list.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule_list.py similarity index 75% rename from contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_slice_list.py rename to contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule_list.py index 05a784496fea..e015a27ec71a 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1alpha2_resource_slice_list.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule_list.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.30 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1alpha2ResourceSliceList(object): +class V1alpha3DeviceTaintRuleList(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -34,7 +34,7 @@ class V1alpha2ResourceSliceList(object): """ openapi_types = { 'api_version': 'str', - 'items': 'list[V1alpha2ResourceSlice]', + 'items': 'list[V1alpha3DeviceTaintRule]', 'kind': 'str', 'metadata': 'V1ListMeta' } @@ -47,7 +47,7 @@ class V1alpha2ResourceSliceList(object): } def __init__(self, api_version=None, items=None, kind=None, metadata=None, local_vars_configuration=None): # noqa: E501 - """V1alpha2ResourceSliceList - a model defined in OpenAPI""" # noqa: E501 + """V1alpha3DeviceTaintRuleList - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration @@ -68,22 +68,22 @@ def __init__(self, api_version=None, items=None, kind=None, metadata=None, local @property def api_version(self): - """Gets the api_version of this V1alpha2ResourceSliceList. # noqa: E501 + """Gets the api_version of this V1alpha3DeviceTaintRuleList. # noqa: E501 APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :return: The api_version of this V1alpha2ResourceSliceList. # noqa: E501 + :return: The api_version of this V1alpha3DeviceTaintRuleList. # noqa: E501 :rtype: str """ return self._api_version @api_version.setter def api_version(self, api_version): - """Sets the api_version of this V1alpha2ResourceSliceList. + """Sets the api_version of this V1alpha3DeviceTaintRuleList. APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources # noqa: E501 - :param api_version: The api_version of this V1alpha2ResourceSliceList. # noqa: E501 + :param api_version: The api_version of this V1alpha3DeviceTaintRuleList. # noqa: E501 :type: str """ @@ -91,23 +91,23 @@ def api_version(self, api_version): @property def items(self): - """Gets the items of this V1alpha2ResourceSliceList. # noqa: E501 + """Gets the items of this V1alpha3DeviceTaintRuleList. # noqa: E501 - Items is the list of node resource capacity objects. # noqa: E501 + Items is the list of DeviceTaintRules. # noqa: E501 - :return: The items of this V1alpha2ResourceSliceList. # noqa: E501 - :rtype: list[V1alpha2ResourceSlice] + :return: The items of this V1alpha3DeviceTaintRuleList. # noqa: E501 + :rtype: list[V1alpha3DeviceTaintRule] """ return self._items @items.setter def items(self, items): - """Sets the items of this V1alpha2ResourceSliceList. + """Sets the items of this V1alpha3DeviceTaintRuleList. - Items is the list of node resource capacity objects. # noqa: E501 + Items is the list of DeviceTaintRules. # noqa: E501 - :param items: The items of this V1alpha2ResourceSliceList. # noqa: E501 - :type: list[V1alpha2ResourceSlice] + :param items: The items of this V1alpha3DeviceTaintRuleList. # noqa: E501 + :type: list[V1alpha3DeviceTaintRule] """ if self.local_vars_configuration.client_side_validation and items is None: # noqa: E501 raise ValueError("Invalid value for `items`, must not be `None`") # noqa: E501 @@ -116,22 +116,22 @@ def items(self, items): @property def kind(self): - """Gets the kind of this V1alpha2ResourceSliceList. # noqa: E501 + """Gets the kind of this V1alpha3DeviceTaintRuleList. # noqa: E501 Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :return: The kind of this V1alpha2ResourceSliceList. # noqa: E501 + :return: The kind of this V1alpha3DeviceTaintRuleList. # noqa: E501 :rtype: str """ return self._kind @kind.setter def kind(self, kind): - """Sets the kind of this V1alpha2ResourceSliceList. + """Sets the kind of this V1alpha3DeviceTaintRuleList. Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds # noqa: E501 - :param kind: The kind of this V1alpha2ResourceSliceList. # noqa: E501 + :param kind: The kind of this V1alpha3DeviceTaintRuleList. # noqa: E501 :type: str """ @@ -139,20 +139,20 @@ def kind(self, kind): @property def metadata(self): - """Gets the metadata of this V1alpha2ResourceSliceList. # noqa: E501 + """Gets the metadata of this V1alpha3DeviceTaintRuleList. # noqa: E501 - :return: The metadata of this V1alpha2ResourceSliceList. # noqa: E501 + :return: The metadata of this V1alpha3DeviceTaintRuleList. # noqa: E501 :rtype: V1ListMeta """ return self._metadata @metadata.setter def metadata(self, metadata): - """Sets the metadata of this V1alpha2ResourceSliceList. + """Sets the metadata of this V1alpha3DeviceTaintRuleList. - :param metadata: The metadata of this V1alpha2ResourceSliceList. # noqa: E501 + :param metadata: The metadata of this V1alpha3DeviceTaintRuleList. # noqa: E501 :type: V1ListMeta """ @@ -192,14 +192,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1alpha2ResourceSliceList): + if not isinstance(other, V1alpha3DeviceTaintRuleList): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1alpha2ResourceSliceList): + if not isinstance(other, V1alpha3DeviceTaintRuleList): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1beta3_group_subject.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule_spec.py similarity index 55% rename from contrib/python/kubernetes/kubernetes/client/models/v1beta3_group_subject.py rename to contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule_spec.py index 8ef66f48ada6..20c573c78639 100644 --- a/contrib/python/kubernetes/kubernetes/client/models/v1beta3_group_subject.py +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_rule_spec.py @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 - The version of the OpenAPI document: release-1.31 + The version of the OpenAPI document: release-1.33 Generated by: https://openapi-generator.tech """ @@ -18,7 +18,7 @@ from kubernetes.client.configuration import Configuration -class V1beta3GroupSubject(object): +class V1alpha3DeviceTaintRuleSpec(object): """NOTE: This class is auto generated by OpenAPI Generator. Ref: https://openapi-generator.tech @@ -33,48 +33,72 @@ class V1beta3GroupSubject(object): and the value is json key in definition. """ openapi_types = { - 'name': 'str' + 'device_selector': 'V1alpha3DeviceTaintSelector', + 'taint': 'V1alpha3DeviceTaint' } attribute_map = { - 'name': 'name' + 'device_selector': 'deviceSelector', + 'taint': 'taint' } - def __init__(self, name=None, local_vars_configuration=None): # noqa: E501 - """V1beta3GroupSubject - a model defined in OpenAPI""" # noqa: E501 + def __init__(self, device_selector=None, taint=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3DeviceTaintRuleSpec - a model defined in OpenAPI""" # noqa: E501 if local_vars_configuration is None: local_vars_configuration = Configuration() self.local_vars_configuration = local_vars_configuration - self._name = None + self._device_selector = None + self._taint = None self.discriminator = None - self.name = name + if device_selector is not None: + self.device_selector = device_selector + self.taint = taint @property - def name(self): - """Gets the name of this V1beta3GroupSubject. # noqa: E501 + def device_selector(self): + """Gets the device_selector of this V1alpha3DeviceTaintRuleSpec. # noqa: E501 - name is the user group that matches, or \"*\" to match all user groups. See https://github.com/kubernetes/apiserver/blob/master/pkg/authentication/user/user.go for some well-known group names. Required. # noqa: E501 - :return: The name of this V1beta3GroupSubject. # noqa: E501 - :rtype: str + :return: The device_selector of this V1alpha3DeviceTaintRuleSpec. # noqa: E501 + :rtype: V1alpha3DeviceTaintSelector """ - return self._name + return self._device_selector - @name.setter - def name(self, name): - """Sets the name of this V1beta3GroupSubject. + @device_selector.setter + def device_selector(self, device_selector): + """Sets the device_selector of this V1alpha3DeviceTaintRuleSpec. - name is the user group that matches, or \"*\" to match all user groups. See https://github.com/kubernetes/apiserver/blob/master/pkg/authentication/user/user.go for some well-known group names. Required. # noqa: E501 - :param name: The name of this V1beta3GroupSubject. # noqa: E501 - :type: str + :param device_selector: The device_selector of this V1alpha3DeviceTaintRuleSpec. # noqa: E501 + :type: V1alpha3DeviceTaintSelector """ - if self.local_vars_configuration.client_side_validation and name is None: # noqa: E501 - raise ValueError("Invalid value for `name`, must not be `None`") # noqa: E501 - self._name = name + self._device_selector = device_selector + + @property + def taint(self): + """Gets the taint of this V1alpha3DeviceTaintRuleSpec. # noqa: E501 + + + :return: The taint of this V1alpha3DeviceTaintRuleSpec. # noqa: E501 + :rtype: V1alpha3DeviceTaint + """ + return self._taint + + @taint.setter + def taint(self, taint): + """Sets the taint of this V1alpha3DeviceTaintRuleSpec. + + + :param taint: The taint of this V1alpha3DeviceTaintRuleSpec. # noqa: E501 + :type: V1alpha3DeviceTaint + """ + if self.local_vars_configuration.client_side_validation and taint is None: # noqa: E501 + raise ValueError("Invalid value for `taint`, must not be `None`") # noqa: E501 + + self._taint = taint def to_dict(self): """Returns the model properties as a dict""" @@ -110,14 +134,14 @@ def __repr__(self): def __eq__(self, other): """Returns true if both objects are equal""" - if not isinstance(other, V1beta3GroupSubject): + if not isinstance(other, V1alpha3DeviceTaintRuleSpec): return False return self.to_dict() == other.to_dict() def __ne__(self, other): """Returns true if both objects are not equal""" - if not isinstance(other, V1beta3GroupSubject): + if not isinstance(other, V1alpha3DeviceTaintRuleSpec): return True return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_selector.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_selector.py new file mode 100644 index 000000000000..e5b30a4fd4d5 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_taint_selector.py @@ -0,0 +1,234 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3DeviceTaintSelector(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'device': 'str', + 'device_class_name': 'str', + 'driver': 'str', + 'pool': 'str', + 'selectors': 'list[V1alpha3DeviceSelector]' + } + + attribute_map = { + 'device': 'device', + 'device_class_name': 'deviceClassName', + 'driver': 'driver', + 'pool': 'pool', + 'selectors': 'selectors' + } + + def __init__(self, device=None, device_class_name=None, driver=None, pool=None, selectors=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3DeviceTaintSelector - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._device = None + self._device_class_name = None + self._driver = None + self._pool = None + self._selectors = None + self.discriminator = None + + if device is not None: + self.device = device + if device_class_name is not None: + self.device_class_name = device_class_name + if driver is not None: + self.driver = driver + if pool is not None: + self.pool = pool + if selectors is not None: + self.selectors = selectors + + @property + def device(self): + """Gets the device of this V1alpha3DeviceTaintSelector. # noqa: E501 + + If device is set, only devices with that name are selected. This field corresponds to slice.spec.devices[].name. Setting also driver and pool may be required to avoid ambiguity, but is not required. # noqa: E501 + + :return: The device of this V1alpha3DeviceTaintSelector. # noqa: E501 + :rtype: str + """ + return self._device + + @device.setter + def device(self, device): + """Sets the device of this V1alpha3DeviceTaintSelector. + + If device is set, only devices with that name are selected. This field corresponds to slice.spec.devices[].name. Setting also driver and pool may be required to avoid ambiguity, but is not required. # noqa: E501 + + :param device: The device of this V1alpha3DeviceTaintSelector. # noqa: E501 + :type: str + """ + + self._device = device + + @property + def device_class_name(self): + """Gets the device_class_name of this V1alpha3DeviceTaintSelector. # noqa: E501 + + If DeviceClassName is set, the selectors defined there must be satisfied by a device to be selected. This field corresponds to class.metadata.name. # noqa: E501 + + :return: The device_class_name of this V1alpha3DeviceTaintSelector. # noqa: E501 + :rtype: str + """ + return self._device_class_name + + @device_class_name.setter + def device_class_name(self, device_class_name): + """Sets the device_class_name of this V1alpha3DeviceTaintSelector. + + If DeviceClassName is set, the selectors defined there must be satisfied by a device to be selected. This field corresponds to class.metadata.name. # noqa: E501 + + :param device_class_name: The device_class_name of this V1alpha3DeviceTaintSelector. # noqa: E501 + :type: str + """ + + self._device_class_name = device_class_name + + @property + def driver(self): + """Gets the driver of this V1alpha3DeviceTaintSelector. # noqa: E501 + + If driver is set, only devices from that driver are selected. This fields corresponds to slice.spec.driver. # noqa: E501 + + :return: The driver of this V1alpha3DeviceTaintSelector. # noqa: E501 + :rtype: str + """ + return self._driver + + @driver.setter + def driver(self, driver): + """Sets the driver of this V1alpha3DeviceTaintSelector. + + If driver is set, only devices from that driver are selected. This fields corresponds to slice.spec.driver. # noqa: E501 + + :param driver: The driver of this V1alpha3DeviceTaintSelector. # noqa: E501 + :type: str + """ + + self._driver = driver + + @property + def pool(self): + """Gets the pool of this V1alpha3DeviceTaintSelector. # noqa: E501 + + If pool is set, only devices in that pool are selected. Also setting the driver name may be useful to avoid ambiguity when different drivers use the same pool name, but this is not required because selecting pools from different drivers may also be useful, for example when drivers with node-local devices use the node name as their pool name. # noqa: E501 + + :return: The pool of this V1alpha3DeviceTaintSelector. # noqa: E501 + :rtype: str + """ + return self._pool + + @pool.setter + def pool(self, pool): + """Sets the pool of this V1alpha3DeviceTaintSelector. + + If pool is set, only devices in that pool are selected. Also setting the driver name may be useful to avoid ambiguity when different drivers use the same pool name, but this is not required because selecting pools from different drivers may also be useful, for example when drivers with node-local devices use the node name as their pool name. # noqa: E501 + + :param pool: The pool of this V1alpha3DeviceTaintSelector. # noqa: E501 + :type: str + """ + + self._pool = pool + + @property + def selectors(self): + """Gets the selectors of this V1alpha3DeviceTaintSelector. # noqa: E501 + + Selectors contains the same selection criteria as a ResourceClaim. Currently, CEL expressions are supported. All of these selectors must be satisfied. # noqa: E501 + + :return: The selectors of this V1alpha3DeviceTaintSelector. # noqa: E501 + :rtype: list[V1alpha3DeviceSelector] + """ + return self._selectors + + @selectors.setter + def selectors(self, selectors): + """Sets the selectors of this V1alpha3DeviceTaintSelector. + + Selectors contains the same selection criteria as a ResourceClaim. Currently, CEL expressions are supported. All of these selectors must be satisfied. # noqa: E501 + + :param selectors: The selectors of this V1alpha3DeviceTaintSelector. # noqa: E501 + :type: list[V1alpha3DeviceSelector] + """ + + self._selectors = selectors + + def to_dict(self): + """Returns the model properties as a dict""" + result = {} + + for attr, _ in six.iteritems(self.openapi_types): + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model""" + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + if not isinstance(other, V1alpha3DeviceTaintSelector): + return False + + return self.to_dict() == other.to_dict() + + def __ne__(self, other): + """Returns true if both objects are not equal""" + if not isinstance(other, V1alpha3DeviceTaintSelector): + return True + + return self.to_dict() != other.to_dict() diff --git a/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_toleration.py b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_toleration.py new file mode 100644 index 000000000000..9d8803f8ca65 --- /dev/null +++ b/contrib/python/kubernetes/kubernetes/client/models/v1alpha3_device_toleration.py @@ -0,0 +1,234 @@ +# coding: utf-8 + +""" + Kubernetes + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 + + The version of the OpenAPI document: release-1.33 + Generated by: https://openapi-generator.tech +""" + + +import pprint +import re # noqa: F401 + +import six + +from kubernetes.client.configuration import Configuration + + +class V1alpha3DeviceToleration(object): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + """ + + """ + Attributes: + openapi_types (dict): The key is attribute name + and the value is attribute type. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + """ + openapi_types = { + 'effect': 'str', + 'key': 'str', + 'operator': 'str', + 'toleration_seconds': 'int', + 'value': 'str' + } + + attribute_map = { + 'effect': 'effect', + 'key': 'key', + 'operator': 'operator', + 'toleration_seconds': 'tolerationSeconds', + 'value': 'value' + } + + def __init__(self, effect=None, key=None, operator=None, toleration_seconds=None, value=None, local_vars_configuration=None): # noqa: E501 + """V1alpha3DeviceToleration - a model defined in OpenAPI""" # noqa: E501 + if local_vars_configuration is None: + local_vars_configuration = Configuration() + self.local_vars_configuration = local_vars_configuration + + self._effect = None + self._key = None + self._operator = None + self._toleration_seconds = None + self._value = None + self.discriminator = None + + if effect is not None: + self.effect = effect + if key is not None: + self.key = key + if operator is not None: + self.operator = operator + if toleration_seconds is not None: + self.toleration_seconds = toleration_seconds + if value is not None: + self.value = value + + @property + def effect(self): + """Gets the effect of this V1alpha3DeviceToleration. # noqa: E501 + + Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule and NoExecute. # noqa: E501 + + :return: The effect of this V1alpha3DeviceToleration. # noqa: E501 + :rtype: str + """ + return self._effect + + @effect.setter + def effect(self, effect): + """Sets the effect of this V1alpha3DeviceToleration. + + Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule and NoExecute. # noqa: E501 + + :param effect: The effect of this V1alpha3DeviceToleration. # noqa: E501 + :type: str + """ + + self._effect = effect + + @property + def key(self): + """Gets the key of this V1alpha3DeviceToleration. # noqa: E501 + + Key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. Must be a label name. # noqa: E501 + + :return: The key of this V1alpha3DeviceToleration. # noqa: E501 + :rtype: str + """ + return self._key + + @key.setter + def key(self, key): + """Sets the key of this V1alpha3DeviceToleration. + + Key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys. Must be a label name. # noqa: E501 + + :param key: The key of this V1alpha3DeviceToleration. # noqa: E501 + :type: str + """ + + self._key = key + + @property + def operator(self): + """Gets the operator of this V1alpha3DeviceToleration. # noqa: E501 + + Operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a ResourceClaim can tolerate all taints of a particular category. # noqa: E501 + + :return: The operator of this V1alpha3DeviceToleration. # noqa: E501 + :rtype: str + """ + return self._operator + + @operator.setter + def operator(self, operator): + """Sets the operator of this V1alpha3DeviceToleration. + + Operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a ResourceClaim can tolerate all taints of a particular category. # noqa: E501 + + :param operator: The operator of this V1alpha3DeviceToleration. # noqa: E501 + :type: str + """ + + self._operator = operator + + @property + def toleration_seconds(self): + """Gets the toleration_seconds of this V1alpha3DeviceToleration. # noqa: E501 + + TolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system. If larger than zero, the time when the pod needs to be evicted is calculated as